haikuwebkit/LayoutTests/svg/custom/image-rescale-clip.html

19 lines
703 B
HTML
Raw Permalink Normal View History

2010-12-02 W. James MacLean <wjmaclean@chromium.org> Reviewed by James Robinson. Scaled Resized images are blurred when sent to Skia https://bugs.webkit.org/show_bug.cgi?id=42370 * platform/chromium-linux/svg/custom/image-rescale-clip-expected.checksum: Added. * platform/chromium-linux/svg/custom/image-rescale-clip-expected.png: Added. * platform/chromium-linux/svg/custom/image-rescale-clip-expected.txt: Added. * platform/chromium-linux/svg/custom/image-rescale-expected.checksum: Added. * platform/chromium-linux/svg/custom/image-rescale-expected.png: Added. * platform/chromium-linux/svg/custom/image-rescale-expected.txt: Added. * platform/chromium-linux/svg/custom/image-rescale-scroll-expected.checksum: Added. * platform/chromium-linux/svg/custom/image-rescale-scroll-expected.png: Added. * platform/chromium-linux/svg/custom/image-rescale-scroll-expected.txt: Added. * platform/chromium/test_expectations.txt: * platform/mac-leopard/svg/custom/image-rescale-expected.checksum: Added. * platform/mac-leopard/svg/custom/image-rescale-expected.png: Added. * platform/mac-leopard/svg/custom/image-rescale-expected.txt: Added. * platform/mac/svg/custom/image-rescale-clip-expected.checksum: Added. * platform/mac/svg/custom/image-rescale-clip-expected.png: Added. * platform/mac/svg/custom/image-rescale-clip-expected.txt: Added. * platform/mac/svg/custom/image-rescale-expected.checksum: Added. * platform/mac/svg/custom/image-rescale-expected.png: Added. * platform/mac/svg/custom/image-rescale-expected.txt: Added. * platform/mac/svg/custom/image-rescale-scroll-expected.checksum: Added. * platform/mac/svg/custom/image-rescale-scroll-expected.png: Added. * platform/mac/svg/custom/image-rescale-scroll-expected.txt: Added. * svg/custom/image-rescale-clip.html: Added. * svg/custom/image-rescale-scroll.html: Added. * svg/custom/image-rescale.svg: Added. * svg/custom/resources/image-rescale.jpg: Added. 2010-12-02 W. James MacLean <wjmaclean@chromium.org> Reviewed by James Robinson. Scaled Resized images are blurred when sent to Skia https://bugs.webkit.org/show_bug.cgi?id=42370 This patch modifies ImageSkia.cpp to fix the calculation of resampled bitmap sizes so as to include the transform matrix of the canvas. Includes new tests to catch a scrolling regression and a clipping regression. Tests: svg/custom/image-rescale-clip.html svg/custom/image-rescale-scroll.html svg/custom/image-rescale.svg * platform/graphics/skia/ImageSkia.cpp: (WebCore::computeResamplingMode): (WebCore::drawResampledBitmap): Canonical link: https://commits.webkit.org/63602@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@73169 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2010-12-02 19:23:55 +00:00
<html>
<!--
This test checks for the regression bug that causes white, horizontal blank bars
-->
<body style="overflow:hidden;">
<!-- It is important for the image to be loaded with only a small amount showing,
as ImageSkia will only do a partial load in this case, which is required to
trigger the regression. -->
<div style="position: absolute; clip:rect(0px,150px,15px,0px);">
<img id = "pic" src="resources/image-rescale.jpg" width="160" height="105" style="position: relative; top: 5px; left: 5px;">
<!-- Rescaled to 1/2 normal size, required to trigger the regression. -->
</div><br />
<div>
<p>This test verifies correct paint of clipped, scaled images.</p>
</div>
</body>
</html>