Changeset 118626 in webkit


Ignore:
Timestamp:
May 27, 2012, 7:41:43 AM (13 years ago)
Author:
commit-queue@webkit.org
Message:

[BlackBerry] BackingStore accesses tiles even though it's not active
https://bugs.webkit.org/show_bug.cgi?id=87563

Patch by Arvid Nilsson <anilsson@rim.com> on 2012-04-18
Reviewed by Antonio Gomes.

There are many scenarios that can call render and cause tile access,
and they used to be rerouted to the direct rendering code when the
backing store was not active. This was thanks to an implicit check for
isActive() by virtue of calling shouldDirectRenderingToWindow() from
render().

If we're using OpenGL for compositing the backing store contents
however, direct rendering is always disabled and we jump right into the
tile based rendering code.

Fixed by adding an explicit check for isActive() in render(), now that
the implicit check in shouldDirectRenderingToWindow() is conditional on
having raster usage.

Since PR136381/bug83131, when OpenGL compositing is used, and the
backing store is not active, it is not in charge of drawing the root
layer. Instead, we switch off the paintingGoesToWindow flag on the root
RenderLayer so no invalidates will reach the ChromeClient or the
BackingStore any more. Instead, invalidations will cause the root
accelerated compositing layer to be repainted. Any BackingStore render
calls while in this state are pointless, and can safely do an early
return.

Reviewed internally by Jakob Petsovits.

PR #150403

  • Api/BackingStore.cpp:

(BlackBerry::WebKit::BackingStorePrivate::render):

Location:
trunk/Source/WebKit/blackberry
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit/blackberry/Api/BackingStore.cpp

    r117223 r118626  
    10111011    if (shouldDirectRenderingToWindow())
    10121012        return renderDirectToWindow(rect);
     1013
     1014    // If direct rendering is off, even though we're not active, someone else
     1015    // has to render the root layer. There are no tiles available for us to
     1016    // draw to.
     1017    if (!isActive())
     1018        return false;
    10131019
    10141020    TileRectList tileRectList = mapFromTransformedContentsToTiles(rect);
  • trunk/Source/WebKit/blackberry/ChangeLog

    r118625 r118626  
     12012-05-27  Arvid Nilsson  <anilsson@rim.com>
     2
     3        2012-04-18  Arvid Nilsson  <anilsson@rim.com>
     4
     5        [BlackBerry] BackingStore accesses tiles even though it's not active
     6        https://bugs.webkit.org/show_bug.cgi?id=87563
     7
     8        Reviewed by Antonio Gomes.
     9
     10        There are many scenarios that can call render and cause tile access,
     11        and they used to be rerouted to the direct rendering code when the
     12        backing store was not active. This was thanks to an implicit check for
     13        isActive() by virtue of calling shouldDirectRenderingToWindow() from
     14        render().
     15
     16        If we're using OpenGL for compositing the backing store contents
     17        however, direct rendering is always disabled and we jump right into the
     18        tile based rendering code.
     19
     20        Fixed by adding an explicit check for isActive() in render(), now that
     21        the implicit check in shouldDirectRenderingToWindow() is conditional on
     22        having raster usage.
     23
     24        Since PR136381/bug83131, when OpenGL compositing is used, and the
     25        backing store is not active, it is not in charge of drawing the root
     26        layer. Instead, we switch off the paintingGoesToWindow flag on the root
     27        RenderLayer so no invalidates will reach the ChromeClient or the
     28        BackingStore any more. Instead, invalidations will cause the root
     29        accelerated compositing layer to be repainted. Any BackingStore render
     30        calls while in this state are pointless, and can safely do an early
     31        return.
     32
     33        Reviewed internally by Jakob Petsovits.
     34
     35        PR #150403
     36
     37        * Api/BackingStore.cpp:
     38        (BlackBerry::WebKit::BackingStorePrivate::render):
     39
    1402012-05-27  Arvid Nilsson  <anilsson@rim.com>
    241
Note: See TracChangeset for help on using the changeset viewer.