Title: [110149] trunk/Source
Revision
110149
Author
fisch...@chromium.org
Date
2012-03-07 22:55:36 -0800 (Wed, 07 Mar 2012)

Log Message

[Chromium] Allow CCLayerTreeHost::context() to be called even with the threaded compositor enabled.
https://bugs.webkit.org/show_bug.cgi?id=80565

Reviewed by James Robinson.

This gets triggered by the video HW decode+render path when threaded compositor is enabled
(https://chromiumcodereview.appspot.com/9639005/)

No new tests.

* platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
(WebCore::CCLayerTreeHost::context):

Modified Paths

Diff

Modified: trunk/Source/Platform/chromium/public/WebLayerTreeView.h (110148 => 110149)


--- trunk/Source/Platform/chromium/public/WebLayerTreeView.h	2012-03-08 06:48:35 UTC (rev 110148)
+++ trunk/Source/Platform/chromium/public/WebLayerTreeView.h	2012-03-08 06:55:36 UTC (rev 110149)
@@ -155,14 +155,13 @@
     // This can have a significant performance impact and should be used with care.
     WEBKIT_EXPORT void finishAllRendering();
 
-
-    // Debugging / dangerous ---------------------------------------------
-
     // Returns the context being used for rendering this view. In threaded compositing mode, it is
-    // not safe to use this context at all on the main thread.
-    // FIXME: Remove this API as soon as possible, it's very bug-prone in threaded mode.
+    // not safe to use this context for anything on the main thread, other than passing the pointer to
+    // the compositor thread.
     WEBKIT_EXPORT WebGraphicsContext3D* context();
 
+    // Debugging / dangerous ---------------------------------------------
+
     // Simulates a lost context. For testing only.
     WEBKIT_EXPORT void loseCompositorContext(int numTimes);
 

Modified: trunk/Source/WebCore/ChangeLog (110148 => 110149)


--- trunk/Source/WebCore/ChangeLog	2012-03-08 06:48:35 UTC (rev 110148)
+++ trunk/Source/WebCore/ChangeLog	2012-03-08 06:55:36 UTC (rev 110149)
@@ -1,3 +1,18 @@
+2012-03-07  Ami Fischman  <fisch...@chromium.org>
+
+        [Chromium] Allow CCLayerTreeHost::context() to be called even with the threaded compositor enabled.
+        https://bugs.webkit.org/show_bug.cgi?id=80565
+
+        Reviewed by James Robinson.
+
+        This gets triggered by the video HW decode+render path when threaded compositor is enabled
+        (https://chromiumcodereview.appspot.com/9639005/)
+
+        No new tests.
+
+        * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
+        (WebCore::CCLayerTreeHost::context):
+
 2012-03-07  Mike Lawther  <mikelawt...@chromium.org>
 
         CSS3 calc: mixed absolute/percentages work for width, height, margin and padding

Modified: trunk/Source/WebCore/platform/graphics/chromium/cc/CCLayerTreeHost.cpp (110148 => 110149)


--- trunk/Source/WebCore/platform/graphics/chromium/cc/CCLayerTreeHost.cpp	2012-03-08 06:48:35 UTC (rev 110148)
+++ trunk/Source/WebCore/platform/graphics/chromium/cc/CCLayerTreeHost.cpp	2012-03-08 06:55:36 UTC (rev 110149)
@@ -249,7 +249,6 @@
 // Temporary hack until WebViewImpl context creation gets simplified
 GraphicsContext3D* CCLayerTreeHost::context()
 {
-    ASSERT(!CCProxy::hasImplThread());
     return m_proxy->context();
 }
 

Modified: trunk/Source/WebCore/platform/graphics/chromium/cc/CCLayerTreeHost.h (110148 => 110149)


--- trunk/Source/WebCore/platform/graphics/chromium/cc/CCLayerTreeHost.h	2012-03-08 06:48:35 UTC (rev 110148)
+++ trunk/Source/WebCore/platform/graphics/chromium/cc/CCLayerTreeHost.h	2012-03-08 06:55:36 UTC (rev 110149)
@@ -153,6 +153,8 @@
     // Only used when compositing on the main thread.
     void composite();
 
+    // NOTE: The returned value can only be used to make GL calls or make the
+    // context current on the thread the compositor is running on!
     GraphicsContext3D* context();
 
     // Composites and attempts to read back the result into the provided
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to