Re: [whatwg] Size of SVG-Img-Canvas

2012-01-31 Thread Ian Hickson
On Thu, 17 Nov 2011, Gavin Kistner wrote: Imagine an SVG file displayed in an img: img id=i src=my.svg ... The SVG file can have an explicit size (height and width attributes, in a variety of CSS units), or it can have no size (defaulting to 100%). Whether or not the SVG file has

[whatwg] Size of SVG-Img-Canvas

2011-11-17 Thread Gavin Kistner
Imagine an SVG file displayed in an img: img id=i src=my.svg ... The SVG file can have an explicit size (height and width attributes, in a variety of CSS units), or it can have no size (defaulting to 100%). Whether or not the SVG file has explicit units, it may have an intrinsic aspect ratio

Re: [whatwg] Size of SVG-Img-Canvas

2011-11-17 Thread Gavin Kistner
Imagine an SVG file displayed in an img: img id=i src=my.svg ... The SVG file can have an explicit size (height and width attributes, in a variety of CSS units), or it can have no size (defaulting to 100%). Whether or not the SVG file has explicit units, it may have an intrinsic aspect ratio

Re: [whatwg] Size of SVG-Img-Canvas

2011-11-17 Thread Tab Atkins Jr.
On Thu, Nov 17, 2011 at 2:56 PM, Gavin Kistner gkist...@nvidia.com wrote: Imagine an SVG file displayed in an img: img id=i src=my.svg ... The SVG file can have an explicit size (height and width attributes, in a variety of CSS units), or it can have no size (defaulting to 100%). Whether

Re: [whatwg] Size of SVG-Img-Canvas

2011-11-17 Thread Boris Zbarsky
On 11/18/11 11:56 AM, Gavin Kistner wrote: In each of the eight combinations of (img heightwidth/CSS heightwidth/SVG heightwidth) being present or not, what are the intrinsic dimensions of the image drawn to the canvas? The spec defines this, no? It's cited in

Re: [whatwg] Size of SVG-Img-Canvas

2011-11-17 Thread Boris Zbarsky
On 11/18/11 12:14 PM, Gavin Kistner wrote: Add one followup: what if you draw the image to the canvas at a 'large' resolution, drawImage(img,0,0,200,200)? Presumably this shouldn't change what source pixels are used for `drawImage`. You're still assuming there are source pixels. There

Re: [whatwg] Size of SVG-Img-Canvas

2011-11-17 Thread Boris Zbarsky
On 11/18/11 12:21 PM, Tab Atkins Jr. wrote: The correct behavior would be to lean on the sizing algorithm at http://dev.w3.org/csswg/css3-images/#default-sizing. All that needs to be done is to define the default object size, That's exactly what the HTML5 spec does right now. -Boris

Re: [whatwg] Size of SVG-Img-Canvas

2011-11-17 Thread Boris Zbarsky
On 11/18/11 12:26 PM, Boris Zbarsky wrote: On 11/18/11 12:14 PM, Gavin Kistner wrote: However, I've added this test to my URL above and we see that Chrome has perfectly anti-aliashed circles in all cases, where Firefox is visibly upscaling a lower-resolution bitmap. I consider this a Gecko

Re: [whatwg] Size of SVG-Img-Canvas

2011-11-17 Thread Gavin Kistner
From: Boris Zbarsky On 11/18/11 12:14 PM, Gavin Kistner wrote: Add one followup: what if you draw the image to the canvas at a 'large' resolution, drawImage(img,0,0,200,200)? Presumably this shouldn't change what source pixels are used for `drawImage`. You're still assuming there are source