RESOLVED FIXED 28454
<canvas> createImageData doesn't handle negative values properly
https://bugs.webkit.org/show_bug.cgi?id=28454
Summary <canvas> createImageData doesn't handle negative values properly
George Wright
Reported 2009-08-19 08:11:52 PDT
According to http://www.whatwg.org/specs/web-apps/current-work/#dom-context-2d-createimagedata, createImageData should create an ImageData object with width and height equal to the absolute magnitude of the values passed to createImageData. WebKit currently does not do this.
Attachments
Handle negatives properly (2.25 KB, patch)
2009-08-19 08:42 PDT, George Wright
no flags
Include layout tests (4.71 KB, patch)
2009-08-19 09:42 PDT, George Wright
eric: review-
George Wright
Comment 1 2009-08-19 08:42:10 PDT
Created attachment 35122 [details] Handle negatives properly Proposed fix for this bug.
George Wright
Comment 2 2009-08-19 09:42:42 PDT
Created attachment 35125 [details] Include layout tests Woops, old patch didn't include the layout tests for some reason.
Darin Adler
Comment 3 2009-08-19 10:15:22 PDT
Comment on attachment 35125 [details] Include layout tests Seems that this test should be a dumpAsText cross-platform test, the way many of the tests in fast/canvas are, such as canvas-alphaImageData-behavior.html for example. That would be more valuable than one with platform-specific results. r=me as is, but please consider making that change
Eric Seidel (no email)
Comment 4 2009-08-21 15:00:45 PDT
Comment on attachment 35125 [details] Include layout tests Since George isn't a committer and won't be able to commit this when landing, marking this r- per Darin's above comments. I agree, this would be nicer as a dumpAsText test.
Andreas Kling
Comment 5 2010-07-11 06:29:56 PDT
Note You need to log in before you can comment on or make changes to this bug.