Gecko:Image Snapping and Rendering: Difference between revisions

Jump to navigation Jump to search
Line 30: Line 30:
# When the anchor point, mapped back to image space via the initial rect, lies on an image pixel boundary, the device-space-to-image-space transform should map a device pixel boundary to that image pixel boundary. (RATIONALE: A CSS background-position:right/bottom image should actually be drawn with the rightmost/bottommost set of pixels at the appropriate edge of the element, no matter what scaling is in effect, so we need to be told which edges should line up and make sure they do.)
# When the anchor point, mapped back to image space via the initial rect, lies on an image pixel boundary, the device-space-to-image-space transform should map a device pixel boundary to that image pixel boundary. (RATIONALE: A CSS background-position:right/bottom image should actually be drawn with the rightmost/bottommost set of pixels at the appropriate edge of the element, no matter what scaling is in effect, so we need to be told which edges should line up and make sure they do.)
# When the scale factors are 1, the translation from device space to image space must be integer multiples of pixels. (RATIONALE: Avoid filtering if possible.)
# When the scale factors are 1, the translation from device space to image space must be integer multiples of pixels. (RATIONALE: Avoid filtering if possible.)
# The device fill rectangle, mapped back to image space, must intersect the subimage rectangle.
# The device fill rectangle, mapped back to image space, must intersect the subimage rectangle. (RATIONALE: If they don't intersect then it's not clear what should be rendered.)
(RATIONALE: If they don't intersect then it's not clear what should be rendered.)


Requirements 5 and 6 imply the following additional requirement:
Requirements 5 and 6 imply the following additional requirement:
1,295

edits

Navigation menu