Re: Filter Templates

On Feb 24, 2011, at 3:06 PM, Rik Cabanier wrote:

> 
> 
> On Thu, Feb 24, 2011 at 2:54 PM, Robert O'Callahan <robert@ocallahan.org> wrote:
> On Fri, Feb 25, 2011 at 10:25 AM, Dean Jackson <dino@apple.com> wrote:
> 
> On Feb 24, 2011, at 12:43 PM, Rik Cabanier wrote:
> 
>> 
>> the CSS could look like:
>>    filter: url(dropshadow.pbk) param1 param2;
>> For transitions or animations, the parameters would be allowed to change.
>> 
>> Rik
> 
>  
> If we're going to refer to external resources that define complex filters, why not just build on top of SVG filters?
> 
>  
> Is it possible to implement hardware acceleration for SVG filters? I'm not an expert on the subject but it seems that some of the filters would be very hard to write as a shaders.

That's a hard question to answer. What hardware? SVG filters could be a long combination of simple effects, requiring multiple rendering passes (ie. too big for a single shader). Some combinations simply might not work on existing hardware.

But that's really not specific to SVG. I'm pretty sure one could write a PixelBender shader that can't be accelerated on today's mobile GPUs. Same with Rob's feGL element.

The (admittedly long) list of effects I gave were all things I believe could be accelerated on the majority of today's hardware. Again, if you did something like filter: sepia hueRotate(45deg) motionBlur(10, 10, 20) mosaic(5, 5) you're probably going to have difficulty.

Dean

Received on Thursday, 24 February 2011 23:14:15 UTC