W3C home > Mailing lists > Public > www-style@w3.org > December 2013

Re: [css-images] element() image use cases

From: Alan Gresley <alan@css-class.com>
Date: Wed, 25 Dec 2013 17:10:04 +1100
Message-ID: <52BA76BC.7080509@css-class.com>
To: "Tab Atkins Jr." <jackalmage@gmail.com>, Rik Cabanier <cabanier@gmail.com>
CC: Dirk Schulze <dschulze@adobe.com>, www-style list <www-style@w3.org>
On 14/11/2013 2:59 PM, Tab Atkins Jr. wrote:
> On Wed, Nov 13, 2013 at 7:41 PM, Rik Cabanier <cabanier@gmail.com> wrote:
>> Example 2 could also be done with the CSS filter image function [1].
> How?
> ~TJ

Rik is correct. It can be done using <image> function.


I can not test it personally since I don't have a Mac (only Safari 
5.1.17 on Windows).

Instead of having opacity buried within a value with parenthesis, like 
as follows,

   background-image: filter(foo.jpg, opacity(0.5));

it would be much more powerful to have the filter as an independent 
background property so the filter value can be animated.

   background-image: url(foo.jpg);
   background-filter: opacity(50%);


Alan Gresley
Received on Wednesday, 25 December 2013 06:10:36 UTC

This archive was generated by hypermail 2.4.0 : Friday, 25 March 2022 10:08:38 UTC