[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Public WebGL] HI-DPI displays and WebGL issues




On 13/06/2012 14:41, Gregg Tavares (社用) wrote:

Because this should just work right now 

var canvas = document.getElementById("canvas");
canvas.width = 640;
canvas.height = 480;
var gl = canvas.getContext("2d", {antiAlias: false});
gl.viewport(0, 0, 640, 480);
What this really argues for is the units for canvas.{width,height} and viewport should be the same.

Elsewhere in the thread, you've mentioned concerns about exceeding MAX_TEXTURE_SIZE or MAX_RENDERBUFFER_SIZE but I would expect those to be increased on systems with high-DPI displays.

Regards

    -Mark