Index: cc/base/switches.cc |
diff --git a/cc/base/switches.cc b/cc/base/switches.cc |
index d34821e0fac6bf348af5fd66c7d282d33b484a1e..8505d8c21dff8d633b8cdc4907a184c16f973b2f 100644 |
--- a/cc/base/switches.cc |
+++ b/cc/base/switches.cc |
@@ -93,6 +93,30 @@ const char kUIShowSurfaceDamageRects[] = "ui-show-surface-damage-rects"; |
const char kShowScreenSpaceRects[] = "show-screenspace-rects"; |
const char kUIShowScreenSpaceRects[] = "ui-show-screenspace-rects"; |
+// Don't allow compressed textures for tiles. |
+const char kDisableTileCompression[] = "disable-tile-compression"; |
+ |
+// Compress textures used for tiles if the gpu supports it. |
+const char kEnableTileCompression[] = "enable-tile-compression"; |
+ |
+// Only compress non-urgent tiles, where the urgent level can be any of the |
+// different bins found in ManagedTileBin. Defaults to -1 which means all bins. |
+const char kTileCompressionThreshold[] = "tile-compression-threshold"; |
+ |
+// Set the preferred tile compression method. |
+const char kTileCompressionMethod[] = "tile-compression-method"; |
+ |
+bool IsTileCompressionEnabled() { |
+ const CommandLine& command_line = *CommandLine::ForCurrentProcess(); |
+ |
+ if (command_line.HasSwitch(switches::kDisableTileCompression)) |
+ return false; |
+ else if (command_line.HasSwitch(switches::kEnableTileCompression)) |
+ return true; |
+ |
+ return false; |
+} |
+ |
// Show rects in the HUD around the screen-space transformed bounds of every |
// layer's replica, when they have one. |
const char kShowReplicaScreenSpaceRects[] = "show-replica-screenspace-rects"; |