Re: [css3-images] Animatability of object-fit, object-position, image-resolution, and image-orientation

On Mar 29, 2012, at 11:11 AM, fantasai <fantasai.lists@inkedblade.net> wrote:

> On 03/29/2012 07:54 AM, Brad Kemper wrote:
>> On Mar 28, 2012, at 11:16 PM, fantasai<fantasai.lists@inkedblade.net>  wrote:
>> 
>>> Seem to have forgotten to update the spec with the Animatability field.
>>> Suggested values:
>>> 
>>>  object-fit:        no
>>>  object-position:   yes
>>>  image-resolution:  no
>>>  image-orientation: no
>>> 
>>> Good/objection?
>>> 
>>> ~fantasai
>> 
>> It seems kind of arbitrary to not allow animating of image-resolution, since it takes a number and unit for its value. Seems like it should be easy to do.
> 
> Should be easy, but the point of image-resolution is to correct the resolution
> of the image, not to define its size.

But it does define the size. The resolution is inexorably tied to size. Given what you say below, about it not changing the actual look of the image (for a pixelated effect), then affecting the size in the absence of explicit 'width' and 'height' is ALL it does, no?

> If we want to scale things, we should
> have a feature that's designed to do that specifically, imo.

We already have it.  'Width' and/or 'height', or 'resolution' with 'width:auto' and 'height:auto', do exactly that while affecting layout. 'transform: scale()' does it without affecting layout. I don't know what else is needed.

>> As for use cases, it could be used to animate the image size when you don't
>> know what the actual width/height dimensions are (and want it to affect layout).
> 
> This seems like a use case for transforms that affect layout, not for
> animating image-resolution.

I don't understand why you would want something separate to do the same thing. We don't prevent people from animating 'width' and 'height'. Animating 'resolution' would have the exact same effect when 'width' and 'height' are left at 'auto' (which is pretty common when you don't know the image dimensions ahead of time).

>> It could also be used as a special effect to smoothly animate from, say,
>> 0.25dpi to 1dppx at a fixed size.
> 
> It doesn't change the resolution of the at a given size, it sets the
> intrinsic resolution which is *only used* to calculate the intrinsic
> size.
> 
>> Or in a background at fixed background-size to sort of blur the image on
>> hover, by reducing its resolution as you increase the opacity of some
>> text in front of the background.
> 
> Like I said, you can't use image-resolution to decrease the resolution
> while maintaining the same size...

I see that now. 'Tis a shame though. It would be cool to set the 'width' and 'height' to an exact px measure and then animate from a pixelated very low resolution.

Received on Friday, 30 March 2012 04:10:18 UTC