Sizing of <video poster=svg>

(Sorry for the cross-posting...)

Spec material:
http://www.w3.org/TR/CSS21/visudet.html#inline-replaced-width
http://www.whatwg.org/specs/web-apps/current-work/multipage/video.html#concept-video-intrinsic-width
http://www.w3.org/TR/SVGTiny12/coords.html#IntrinsicSizing


Consider the following SVG image:

   <svg xmlns="http://www.w3.org/2000/svg" viewBox="-1 -1 2 2">
    <circle r="1"/>
   </svg>

It has an intrinsic ratio but no intrinsic dimensions.

Now reference that image in <video poster>. What should the size of the video element be?

<video>s are by default 300x150.

Inline replaced elements with an intrinsic ratio but no intrinsic size will determine the width from the containing block and the height from the ratio.

Video poster images are temporary in their nature -- the video element will resize to the actual video's dimensions when those are known. Therefore, IMHO, it makes more sense to keep the 300x150 size in the case above. Unless there comes around a video format that doesn't have intrinsic dimensions... What do people think?


On a related note, if the same image is referenced from <iframe src>, Opera currently uses 300x150. <img>, <embed> and <object> use the rules specified in CSS.

-- 
Simon Pieters
Opera Software

Received on Friday, 20 March 2009 14:26:27 UTC