Changeset 124487 in webkit


Ignore:
Timestamp:
Aug 2, 2012 12:53:52 PM (12 years ago)
Author:
commit-queue@webkit.org
Message:

[BlackBerry] Rounding error of destination rect of checkerboard
https://bugs.webkit.org/show_bug.cgi?id=93012

Patch by Leo Yang <leoyang@rim.com> on 2012-08-02
Reviewed by Rob Buis.

Reviewed internally by Jakob Petsovits.

Intersect with the destination rectangle to eliminate the rounding error.

  • Api/BackingStore.cpp:

(BlackBerry::WebKit::BackingStorePrivate::blitContents):

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

Legend:

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

    r124199 r124487  
    14081408            IntRectList checkeredRects = checkeredRegion.rects();
    14091409            for (size_t i = 0; i < checkeredRects.size(); ++i) {
    1410                 Platform::IntRect dstRect = transformation.mapRect(Platform::IntRect(
     1410                Platform::IntRect clippedDstRect = transformation.mapRect(Platform::IntRect(
    14111411                    Platform::IntPoint(checkeredRects.at(i).x() - origin.x(), checkeredRects.at(i).y() - origin.y()),
    14121412                                       checkeredRects.at(i).size()));
     1413                // To eliminate 1 pixel inflation due to transformation rounding.
     1414                clippedDstRect.intersect(dstRect);
    14131415#if DEBUG_CHECKERBOARD
    14141416                blitCheckered = true;
    14151417#endif
     1418
    14161419                fillWindow(BlackBerry::Platform::Graphics::CheckerboardPattern,
    1417                     dstRect, checkeredRects.at(i).location(), transformation.a());
     1420                    clippedDstRect, checkeredRects.at(i).location(), transformation.a());
    14181421            }
    14191422        }
  • trunk/Source/WebKit/blackberry/ChangeLog

    r124470 r124487  
     12012-08-02  Leo Yang  <leoyang@rim.com>
     2
     3        [BlackBerry] Rounding error of destination rect of checkerboard
     4        https://bugs.webkit.org/show_bug.cgi?id=93012
     5
     6        Reviewed by Rob Buis.
     7
     8        Reviewed internally by Jakob Petsovits.
     9
     10        Intersect with the destination rectangle to eliminate the rounding error.
     11
     12        * Api/BackingStore.cpp:
     13        (BlackBerry::WebKit::BackingStorePrivate::blitContents):
     14
    1152012-08-01  Antonio Gomes  <agomes@rim.com>
    216
Note: See TracChangeset for help on using the changeset viewer.