[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 16/06/2012 06:38, James Robinson wrote:
Canvas 2d is (mostly) a vector API, so you can write canvas 2d code that does not care how many pixels are in the backing store and it will Just Work.

That is definitely not true for OpenGL or WebGL - in general it is not possible to write code that works correctly that does not care about how many pixels are actually in the backing store.  I think this is the fundamental difference between 2d canvas and WebGL and not something we can gloss over with an option or attribute.
This is only true if by "don't care" you mean don't bother to query. A correctly written application that queries the "window size"
can work perfectly and draw beautiful images regardless of what size window it is drawing in.

Regards

    -Mark