Subpixel rendering: Directly composited image layers need pixelsnapping.
authorzalan@apple.com <zalan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 17 Mar 2016 00:07:58 +0000 (00:07 +0000)
committerzalan@apple.com <zalan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 17 Mar 2016 00:07:58 +0000 (00:07 +0000)
commit214f291cb9d9086c6fe0eaec8bdbc5b53c1dc8c5
treefad02e25612ffd30f65e9fbb94cb7d5fb811a716
parent965361f275c0335aae0cf916068284b87dcd9823
Subpixel rendering: Directly composited image layers need pixelsnapping.
https://bugs.webkit.org/show_bug.cgi?id=155558

Reviewed by Simon Fraser.

In order to match non-composited image size/position, we need to pixelsnap both the contents and the clipping
layer bounds for directly composited images.

Source/WebCore:

Test: fast/images/hidpi-directly-composited-image-on-subpixel-position.html

* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::resetContentsRect):
(WebCore::RenderLayerBacking::updateChildClippingStrategy):
(WebCore::RenderLayerBacking::updateImageContents):

LayoutTests:

* fast/images/hidpi-directly-composited-image-on-subpixel-position-expected.html: Added.
* fast/images/hidpi-directly-composited-image-on-subpixel-position.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@198309 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/fast/images/hidpi-directly-composited-image-on-subpixel-position-expected.html [new file with mode: 0644]
LayoutTests/fast/images/hidpi-directly-composited-image-on-subpixel-position.html [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/rendering/RenderLayerBacking.cpp