[whatwg] VIDEO tag height/width best fit
bijumaillist at gmail.com
Sun Aug 3 21:19:48 PDT 2008
I apologize if I did not understood
I see a situation where we want to specify the height and width of the
BOX in which a video need to be displayed. And while writing HTML code
we dont know the height/width of the video. But when playing we want
the video to be displayed with maximum size which can fit in the BOX
without loosing the aspect ratio.
After reading the <video> tag specification I dont see a way to
We should have one more attribute to tell how to "fit" the image/video
== "fit" attribute values ===
* center - if it is small keep at center
* stretch - stretch/skew height and width to fit
* stretch-height - stretch/skew height only to fit,
adjust width to maintain aspect ratio.
* stretch-width - stretch/skew width only to fit,
adjust height to maintain aspect ratio.
* stretch-best - stretch/skew height or width to maximum
so that other will fit in
and maintain aspect ratio.
May be we can also have a "tile" option
This problem also exist for <img> tag.
More information about the whatwg