Closed Bug 598890 Opened 14 years ago Closed 13 years ago

-moz-crisp-edges can result in a ghost line being wrapped around.

Categories

(Core :: Graphics: Canvas2D, defect)

defect
Not set
trivial

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: grantgalitz, Unassigned)

References

()

Details

Attachments

(3 files)

User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:2.0b7pre) Gecko/20100922 Firefox/4.0b7pre Build Identifier: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:2.0b7pre) Gecko/20100922 Firefox/4.0b7pre When -moz-crisp-edges is used on the canvas element, a line maybe appearr as the first or last single-pixel row (not scaled or resized, but actual one-pixel height) in which that row seems to have been wrapped from the opposite side of the canvas. If this ghost line is the last line, it appears to contain pixels that should really be in the first row. vice versa. Does not occur with normal filters, only nearest-neighbor by -moz-crisp-edges. Also, this is a bug of whchI've seen in FF3.6 on Mac Intel as well. Reproducible: Always Steps to Reproduce: 1.Open a rom file 2.Wait for the rom file to load and start looking at the top and last lines of the canvas. 3.A ghost line will appear, and it will shift its location when the canvas has been resized by dragging the bottom right corner of the container. Actual Results: A wrapped / ghost line of pixels appear on the canvas upon close inspection when certain roms provide the right contrast to easily discern the ghost lines. Expected Results: There should be no ghost line of any sort on the top or botom row of pixels. Some gameboy and gameboy color rom images do not work properly yet. You may have to try multiple roms before a rom image plays.
Seems that there's a flawed nearest-neighbor filter.
It's a little tricky to reproduce (you have to resize the gameboy element from the bottom-right corner; play around with it until you get the repeating), but I can definitely reproduce it. We probably put our canvas, or the images inside it, in repeat mode?
Status: UNCONFIRMED → NEW
Component: Graphics → Canvas: 2D
Ever confirmed: true
QA Contact: thebes → canvas.2d
I should note that this site sends the webpages as application/xhtml+xml to browsers that support that mime type, while others, like IE8, get a recompiled webpage as html. There are differences between the two types being sent. Though this should have no bearing.
Now the ghost line is on the top. You'll see that what should be part of the bottom tiling is now the first row of pixels for this instance. This is a problem with how the canvas is rescaled when nearest-neighbor is in use (I've only seen this on Macs as of now).
Attachment #478690 - Attachment description: A screen shot of Super Mario Bros. Deluxe running with -moz-crisp-edges set, the bottom pixel line is bugged from NN scaling → A screen shot of Super Mario Bros. Deluxe running with -moz-crisp-edges set, the TOP pixel line is bugged from NN scaling
Should be changed to WILL result in a ghost line being wrapped around. Sucks that the scaling is pretty much ruined by this small bug.
Tested Ubuntu 10.03 There's no ghost-line on Ubuntu, but it does appear Ubuntu is not setting the size right and making the line where the ghost line would have been as a transparent line, as if the height was rounded off.
I meant Ubuntu 10.04, lol
Severity: trivial → major
OS: Mac OS X → All
Hardware: x86 → All
https://bugzilla.mozilla.org/show_bug.cgi?id=490997 seems to be related to this bug (Slightly different problem, probably caused by the same bug).
Severity: major → trivial
Black vertical line on the right side of the canvas should not even exist! The emulator on facebook is the same one used in the other screenshots, it's just being loaded in as an iframe.
In the newer nightly builds, there isn't a ghost line being wrapped around, but some weird black or white artifact line being drawn now instead.
any update on this (Will it even be looked into before the FF4 release)? It really has been a boog since 3.6 at least.
Can you retest this please now that bug 468496 is fixed? If it still happens, then it may be related to bug 450140
Ah, it was fixed a few months ago, it seems someone ninja-fixed it. :D
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: