W3C home > Mailing lists > Public > www-style@w3.org > October 2011

Re: [css-shaders] CSS shaders for custom filters (ACTION-3072)

From: Gregg Tavares (wrk) <gman@google.com>
Date: Tue, 4 Oct 2011 11:22:14 -0700
Message-ID: <CAKZ+BNrFHmiR-csFzfhxX+4vAmvPE4soZcD1Vt3dZ9RdDXHEVQ@mail.gmail.com>
To: Dean Jackson <dino@apple.com>
Cc: www-style@w3.org
On Mon, Oct 3, 2011 at 8:12 PM, Dean Jackson <dino@apple.com> wrote:

>
> On 04/10/2011, at 7:16 AM, Gregg Tavares (wrk) wrote:
>
> > What about mouse input?
> >
> > It seems like for this proposal to actually work as other CSS works
> > you'd need to run mouse and touch events through the vertex shader so
> > that you get the mouse coordinates translated through the shader.
> >
> > Yes? No?
>
> When I first read this I thought you were asking for the current pointer
> coordinate to be provided as a default input to the shader pipeline. That's
> an interesting idea and might avoid scripting in some cases (you could
> always do it with custom parameters in the proposal Vincent sent). We'd need
> to decide which coordinates though - screen, page, element.
>
> But that's not what you're asking, I think :)
>

Maybe this will make it clearer.

This page (only works in Safari currently)
http://greggman.com/downloads/examples/interactive-3d-css-element.html

Is transforming an iframe. Note that the iframe is completely interactive.
You can click on the links, you can type in the search box, etc...

CSS shaders would allow me to morph that iframe into a torus. (see mockup
screenshot here:
http://greggman.com/downloads/examples/interactive-css-shader-element-mockup.png
)

In order for that iframe to stay completely interactive the browser will
need to transform mouse events through the vertex shader so that the page is
still usable.




>
> Since a vertex shader could potentially transform the element to a
> different position, you're wondering how this affects the typical CSS
> selection (like :hover). This isn't really specific to the shader-based
> proposal - a displacement map could move an element, or a filter could make
> it transparent. Unless someone can tell me otherwise, I believe our current
> resolution is that we do selection in relation to the unfiltered input.
>
> There was a related discussion at the last CSS f2f meeting about improving
> the way pointer-events work. Zynga have suggested they need a way to make
> transparent pixels invisible to clicks. We're still working on this (I have
> an ACTION item I need to do).
>
> Dean
>
>
Received on Tuesday, 4 October 2011 18:22:39 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:45 GMT