Changeset 52900 in webkit


Ignore:
Timestamp:
Jan 6, 2010 9:30:26 PM (14 years ago)
Author:
eric@webkit.org
Message:

2009-10-18 Patrick Gansterer <paroga@paroga.com>

Reviewed by Dirk Schulze.

Improve DOM performance in large SVG files.
Check the dirty area before painting a path, which prevents unnecessary
clipping and changes to the GraphicsContext.
https://bugs.webkit.org/show_bug.cgi?id=30055

  • rendering/RenderPath.cpp: (WebCore::RenderPath::paint):
Location:
trunk/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebCore/ChangeLog

    r52899 r52900  
     12009-10-18 Patrick Gansterer <paroga@paroga.com>
     2
     3        Reviewed by Dirk Schulze.
     4
     5        Improve DOM performance in large SVG files.
     6        Check the dirty area before painting a path, which prevents unnecessary
     7        clipping and changes to the GraphicsContext.
     8        https://bugs.webkit.org/show_bug.cgi?id=30055
     9
     10        * rendering/RenderPath.cpp:
     11        (WebCore::RenderPath::paint):
     12
    1132010-01-06  Kent Tamura  <tkent@chromium.org>
    214
  • trunk/WebCore/rendering/RenderPath.cpp

    r52866 r52900  
    215215    if (paintInfo.context->paintingDisabled() || style()->visibility() == HIDDEN || m_path.isEmpty())
    216216        return;
    217            
     217
     218    FloatRect boundingBox = repaintRectInLocalCoordinates();
     219    if (!boundingBox.intersects(paintInfo.rect))
     220        return;
     221
    218222    paintInfo.context->save();
    219223    paintInfo.context->concatCTM(localToParentTransform());
     
    221225    SVGResourceFilter* filter = 0;
    222226
    223     FloatRect boundingBox = repaintRectInLocalCoordinates();
    224227    if (paintInfo.phase == PaintPhaseForeground) {
    225228        PaintInfo savedInfo(paintInfo);
Note: See TracChangeset for help on using the changeset viewer.