Changeset 83242 in webkit


Ignore:
Timestamp:
Apr 7, 2011 8:09:15 PM (13 years ago)
Author:
commit-queue@webkit.org
Message:

2011-04-07 John Bauman <jbauman@chromium.org>

Reviewed by Kenneth Russell.

clearIfComposited call is really slow
https://bugs.webkit.org/show_bug.cgi?id=57999

Move getContextAttributes call after the if, so it isn't called nearly as often.

No new tests.

  • html/canvas/WebGLRenderingContext.cpp: (WebCore::WebGLRenderingContext::clearIfComposited):
Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r83241 r83242  
     12011-04-07  John Bauman  <jbauman@chromium.org>
     2
     3        Reviewed by Kenneth Russell.
     4
     5        clearIfComposited call is really slow
     6        https://bugs.webkit.org/show_bug.cgi?id=57999
     7
     8        Move getContextAttributes call after the if, so it isn't called nearly as often.
     9
     10        No new tests.
     11
     12        * html/canvas/WebGLRenderingContext.cpp:
     13        (WebCore::WebGLRenderingContext::clearIfComposited):
     14
    1152011-04-07  Luke Macpherson   <macpherson@chromium.org>
    216
  • trunk/Source/WebCore/html/canvas/WebGLRenderingContext.cpp

    r81899 r83242  
    503503        return false;
    504504
    505     RefPtr<WebGLContextAttributes> contextAttributes = getContextAttributes();
    506 
    507505    if (!m_context->layerComposited() || m_layerCleared
    508506        || m_attributes.preserveDrawingBuffer || m_framebufferBinding)
    509507        return false;
     508
     509    RefPtr<WebGLContextAttributes> contextAttributes = getContextAttributes();
    510510
    511511    // Determine if it's possible to combine the clear the user asked for and this clear.
Note: See TracChangeset for help on using the changeset viewer.