Re: [css3-images] [css3-background] Image/media fragments and cropping

On Tue, Nov 13, 2012 at 1:50 PM, Philippe Verdy <verdy_p@wanadoo.fr> wrote:
> I can give some examples where the <url> will definitely not be compatible
> with the MF spec :
>
>  * the case of the "javascript:" URI scheme, which could be used to
> encapsulate also a script that will select a media server, request a media,
> perform some authorizations, instruct it with rendering options including
> linear transforms, and then instruct it it play the media and return the
> MediaAccess object created by this script.

As far as I know, javascript URLs aren't evaluated in CSS, for
security reasons (and probably won't ever be, because we collectively
Do Not Like javascript urls).  This isn't specified anywhere (it
should be), but shrug.

>  * the case where the <url> will be that of on HTML page (including the HTML
> page that could be returned by a media server instead of the image, e.g. a
> "404 Not found" page, or a 5xx server error page) : the content returned
> will not match the expected media type, but there will still be a
> MediaAccess object returned which allows rendering it with a client-side
> renderer (not necessarily impelmented by CSS itself, but searched by CSS
> engines within a list of preregistered content-type renderers : a web
> browser for example may register itself as if it was a media server, it will
> build a virtual "image" usable as a CSS background, and it will be able to
> reply to methods offered by the MediaAccess API (including transforms and
> cropping).

There's no problem here - if any browser ever wanted to be able to
render HTML pages as images, it's free to do so, and media fragments
would be compatible with this.

~TJ

Received on Tuesday, 13 November 2012 22:08:32 UTC