Add a LayoutTest for canvas.drawImage using an APNG image |
||
Issue description<canvas>.drawImage() should draw the initial frame (or poster frame) of an animated image, per the spec. Add a test case using an animated PNG image (APNG). There is a similar test for a GIF, but not for WEBP. Write the test that covers them all.
,
Mar 4 2017
Created a GIF image using the above idea of width: 315px, height: 236px, and 74 frames in total, where only frame 0 has color. I converted the GIF to APNG, and WEBP animated (these test resources attached).
,
Mar 4 2017
,
Mar 11 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/427dfb952160b6402103f5db70a0e3dc6c5c500d commit 427dfb952160b6402103f5db70a0e3dc6c5c500d Author: noel <noel@chromium.org> Date: Sat Mar 11 03:40:37 2017 Add canvas.drawImage test for animated image types canvas.drawImage() for animated images should draw the initial frame (or poster frame) of the animated image, per spec. Add a layout test that covers GIF, APNG, and WEBP animated images, ensure the test can also be run manually in any browser [1]. [1] Manual testing: the test uses <canvas> to read the image pixels, so serve the test page from a local web server (Chrome's same origin policy prevents the pixel read otherwise). If you have python handy, a script can be used: #!/bin/bash - # Simple python server: run in the local directory you want to serve # then load http://localhost:8888 in your browser. python -m SimpleHTTPServer 8888 BUG= 698487 Review-Url: https://codereview.chromium.org/2728193004 Cr-Commit-Position: refs/heads/master@{#456273} [add] https://crrev.com/427dfb952160b6402103f5db70a0e3dc6c5c500d/third_party/WebKit/LayoutTests/fast/canvas/canvas-drawImage-animated-images-expected.txt [add] https://crrev.com/427dfb952160b6402103f5db70a0e3dc6c5c500d/third_party/WebKit/LayoutTests/fast/canvas/canvas-drawImage-animated-images.html [add] https://crrev.com/427dfb952160b6402103f5db70a0e3dc6c5c500d/third_party/WebKit/LayoutTests/images/resources/count-down-color-test.gif [add] https://crrev.com/427dfb952160b6402103f5db70a0e3dc6c5c500d/third_party/WebKit/LayoutTests/images/resources/count-down-color-test.png [add] https://crrev.com/427dfb952160b6402103f5db70a0e3dc6c5c500d/third_party/WebKit/LayoutTests/images/resources/count-down-color-test.webp
,
Mar 13 2017
|
||
►
Sign in to add a comment |
||
Comment 1 by noel@chromium.org
, Mar 4 2017176 KB
176 KB View Download