Summary: | [Qt] REGRESSION(r54811) fast/canvas/drawImage-with-negative-source-destination.html fails | ||||||
---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Csaba Osztrogonác <ossy> | ||||
Component: | New Bugs | Assignee: | qi <qi.2.zhang> | ||||
Status: | CLOSED FIXED | ||||||
Severity: | Normal | CC: | ariya.hidayat, commit-queue, cshu, hausmann, kent.hansen, laszlo.gombos, noam | ||||
Priority: | P3 | Keywords: | Qt | ||||
Version: | 528+ (Nightly build) | ||||||
Hardware: | PC | ||||||
OS: | All | ||||||
Bug Depends on: | |||||||
Bug Blocks: | 35784 | ||||||
Attachments: |
|
Description
Csaba Osztrogonác
2010-02-16 15:45:53 PST
fast/canvas/drawImage-with-negative-source-destination.html skipped until fix by http://trac.webkit.org/changeset/54842 . Created attachment 51450 [details]
support negative width and height
At HTML5 spec 4.8.10.1.11 Images, about context.drawImage:
The source rectangle is the rectangle whose corners are the four points (sx, sy), (sx+sw, sy), (sx+sw, sy+sh), (sx,sy+sh).
The destination rectangle is the rectangle whose corners are the four points (dx, dy), (dx+dw, dy), (dx+dw,dy+dh), (dx, dy+dh).
In this case, the sw(width) or sh(height) could be negative. Based on the spec, as long as sx+sw > 0 or sy+sh, it is still legal.
In Qt, QPainter don't support a negative width or height.
Bascially, to support negative width or height, we need to reset the (sx,sy) to make width or heigh to positive.
Comment on attachment 51450 [details]
support negative width and height
Looks good, r+.
Comment on attachment 51450 [details] support negative width and height Clearing flags on attachment: 51450 Committed r56619: <http://trac.webkit.org/changeset/56619> All reviewed patches have been landed. Closing bug. |