summaryrefslogtreecommitdiffstats
path: root/content
diff options
context:
space:
mode:
authorsievers@chromium.org <sievers@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-02-14 23:09:07 +0000
committersievers@chromium.org <sievers@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-02-14 23:09:07 +0000
commitead52b5044d4aa196a3c81b5582c5b39ec79008e (patch)
treee3e77e77affd8ded838158196e02ae19e7967c39 /content
parentcdda87a3a763c7b9c807832877c12adda0507aa1 (diff)
downloadchromium_src-ead52b5044d4aa196a3c81b5582c5b39ec79008e.zip
chromium_src-ead52b5044d4aa196a3c81b5582c5b39ec79008e.tar.gz
chromium_src-ead52b5044d4aa196a3c81b5582c5b39ec79008e.tar.bz2
Revert 179298
> Use 256x256 textures on N10 > > Using 512x512 means that small layers take up disproportionately large > amounts of space. Moreover, the rationale for this original change has > disappeared in the move to impl-side painting and async texture uploads. > Since the intent is to move to this path wholesale, it is safe to remove this > code completely. > (notry since try failures looked ok) > > R=epenner,piman > > BUG=172655 > NOTRY=True > > Review URL: https://chromiumcodereview.appspot.com/12095028 NOTRY=True TBR=nduca@chromium.org Review URL: https://chromiumcodereview.appspot.com/12253023 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182567 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content')
-rw-r--r--content/gpu/gpu_info_collector_android.cc13
1 files changed, 13 insertions, 0 deletions
diff --git a/content/gpu/gpu_info_collector_android.cc b/content/gpu/gpu_info_collector_android.cc
index 233f8ca..a38826b 100644
--- a/content/gpu/gpu_info_collector_android.cc
+++ b/content/gpu/gpu_info_collector_android.cc
@@ -12,6 +12,7 @@
#include "base/string_split.h"
#include "base/string_util.h"
#include "content/public/common/content_switches.h"
+#include "ui/gfx/android/device_display_info.h"
namespace {
@@ -87,8 +88,20 @@ bool CollectBasicGraphicsInfo(content::GPUInfo* gpu_info) {
switches::kEnableVirtualGLContexts);
}
+ gfx::DeviceDisplayInfo info;
int default_tile_size = 256;
+ // For very high resolution displays (eg. Nexus 10), set the default
+ // tile size to be 512. This should be removed in favour of a generic
+ // hueristic that works across all platforms and devices, once that
+ // exists: http://crbug.com/159524. This switches to 512 for screens
+ // containing 40 or more 256x256 tiles, such that 1080p devices do
+ // not use 512x512 tiles (eg. 1920x1280 requires 37.5 tiles)
+ int numTiles = (info.GetDisplayWidth() *
+ info.GetDisplayHeight()) / (256 * 256);
+ if (numTiles >= 40)
+ default_tile_size = 512;
+
// IMG: Fast async texture uploads only work with non-power-of-two,
// but still multiple-of-eight sizes.
// http://crbug.com/168099