Index: cc/output/ca_layer_overlay.cc |
diff --git a/cc/output/ca_layer_overlay.cc b/cc/output/ca_layer_overlay.cc |
index 8117a682d844534237aba51151e47a6930fb0d63..8d4deb12ab2a90e3c8416500cd3e06a3d6fada6f 100644 |
--- a/cc/output/ca_layer_overlay.cc |
+++ b/cc/output/ca_layer_overlay.cc |
@@ -16,6 +16,8 @@ |
namespace cc { |
namespace { |
+ |
+bool g_allow_rpdq_quad_conversion = false; |
// This enum is used for histogram states and should only have new values added |
// to the end before COUNT. |
@@ -120,7 +122,11 @@ |
ca_layer_overlay->render_pass_id = quad->render_pass_id; |
ca_layer_overlay->contents_rect = gfx::RectF(0, 0, 1, 1); |
- return CA_LAYER_SUCCESS; |
+ // TODO(erikchen): Enable this when RenderPassDrawQuad promotion to CALayer |
+ // is fully functional. https://crbug.com/581526. |
+ if (g_allow_rpdq_quad_conversion) |
+ return CA_LAYER_SUCCESS; |
+ return CA_LAYER_FAILED_RENDER_PASS; |
} |
CALayerResult FromStreamVideoQuad(ResourceProvider* resource_provider, |
@@ -336,4 +342,8 @@ |
return true; |
} |
+void EnableRenderPassDrawQuadForTesting() { |
+ g_allow_rpdq_quad_conversion = true; |
+} |
+ |
} // namespace cc |