Re: [css-images] image-rendering: pixelated, scaling up/down?

On 09/23/2014 11:31 AM, Daniel Holbert wrote:
> On 04/02/2013 06:41 AM, Simon Sapin wrote:
>> The spec for the 'pixelated' value of the 'image-rendering' property has
>> different text for "When scaling the image up" and "When scaling down".
>> How is that defined?
> [...]
>> * What if one dimension is scaled up and the other down? For example a
>> 100x100 PNG with `width: 200px; height: 50px`.
> [...]
>> Perhaps "When scaling the image up in at least one dimension" is enough.
> 
> I'm curious about this as well. (Looks like this spec text still makes a
> binary distinction between "scaling up" vs "scaling down", which doesn't
> actually cover the space of possibilities, as Simon says above.)
> 
> Could this be clarified in the spec?
> 
> For reference, it looks like Blink's implementation does what Simon
> suggested -- it pixelates when *at least one* dimension is being scaled up:
> http://src.chromium.org/viewvc/blink/trunk/Source/core/rendering/ImageQualityController.cpp?r1=176839&r2=176957&pathrev=176957
> http://src.chromium.org/viewvc/blink/trunk/Source/core/rendering/RenderHTMLCanvas.cpp?r1=176839&r2=176957&pathrev=176957

Spec quote/link, for reference:
 # When scaling the image up, [...]
 # When scaling down, [...]
http://dev.w3.org/csswg/css-images/#valuedef-pixelated

[I'm also updating the email-subject to drop the "-4", to match the
requested "Feedback" format from the current ED.]

Received on Tuesday, 23 September 2014 18:45:31 UTC