[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Public WebGL] How to set a canvas backing store to display units?
On Wed, Jun 13, 2012 at 10:47 AM, Ian Hickson <email@example.com>
On Tue, 12 Jun 2012, Gregg Tavares (çÃ~TÂ) wrote:canvas.width and canvas.height are defined to be in CSS units, not device units.
> canvas.width = convertCSSUnitsToDeviceUnits(widthInCSSUnits);
> canvas.height =convertCSSUnitsToDeviceUnits(widthInCSSUnits);
this is problematic for webgl because webgl has other things like framebuffers and copyTexImage2d which need to have consistent behavior with the canvas for equal widths and heights.
Ian Hickson Â Â Â Â Â Â Â U+1047E Â Â Â Â Â Â Â Â)\._.,--....,'``. Â ÂfL
http://ln.hixie.ch/ Â Â Â U+263A Â Â Â Â Â Â Â Â/, Â _.. \ Â _\ Â;`._ ,.
Things that are impossible just take longer. Â `._.-(,_..'--(,_..'`-.;.'