[whatwg] Treat <video> like an image

Jonas Sicking jonas at sicking.cc
Mon Aug 11 21:58:40 PDT 2008


João Eiras wrote:
> Hi !
> 
> Not a long time ago, we saw an Opera build which had <video> support. What
> was really really cool about it was that <video> was pretty much supported
> like any other image format so we could apply filtering and other complex
> stuff from svg like in this example.
> http://people.opera.com/howcome/2007/video/svg/video-filter.svg
> 
> This gives us an entire range of possibilities with <video>, just like
> with <svg>, or <img>
> 
> I think that video should be supported like any other image:
>   - supporting transparencies (if the video codec allows)
>   - embedding video files with <video> or <object> element
>   - embedding video files with url() in css where images can be used, like
> background-image
>   - embedding video files with url() in css content rules
> 
> If course, this could raise some issues like:
>   - performance - the UA should provide a way for the use to toggle video
> on and off, or could make decisions based on the platform's overall
> performance. Also, with rendering engines progressively migrating to
> architectures that support hardware acceleration, blending a background
> video with foreground content could be a trivial lightweight operation,
> although the same cannot be said for software renderers.
>   - fallback in css not possible - if a UA does not support video, then it
> would ignore the content embedded in the stylesheet. Such behavior is also
> fully supported for other content types, like unrecognized image formats
> and the likes. However, the problem of adding fallback content with CSS
> not being trivial, is a problem with css itself, and out of scope of the
> <video> specification
>   - accessibility, usability - by providing new means for authors to add
> more video and possibly other annoying animations in webpages, users could
> easily be annoyed with excess of animated content. This is more or less
> the same problem of performance, so the UA should give the user the option
> to disable video, preferably in site specific preferences, if supported.

I think I agree. But I don't see anything in any current specs that 
contradicts what you are saying. In other words, are you requesting any 
changes to any specific specs, or are you just asking UA developers to 
implement the feature set to full extent that specs allow?

Note that the CSS spec says nothing about what format a url() can point 
to, thus there is no spec-wise reason pointing to a video file wouldn't 
work.

And there is no documented limitation on which elements css transparency 
applies, thus applying it to a <video> element should work just fine, 
and already does in the implementation in recent firefox nightlies.

/ Jonas



More information about the whatwg mailing list