- From: Cameron McCormack <cam@mcc.id.au>
- Date: Mon, 09 Apr 2012 12:22:28 +1000
- To: Kenneth Russell <kbr@google.com>
- CC: Glenn Maynard <glenn@zewt.org>, Boris Zbarsky <bzbarsky@mit.edu>, public_webgl@khronos.org, "public-script-coord@w3.org" <public-script-coord@w3.org>
Kenneth Russell:
> Sorry about that. It looks like I did drop that set of changes on the
> floor by accident. Let's resolve this issue now.
>
> Has there been a decision on the best path forward here? The
> requirements in the WebGL spec are relatively small; it must be
> possible to pass a user object to getContext("webgl", /* attrs */) and
> it must be possible to define the attributes and their types returned
> from getContextAttributes. Aside from that the existence of the
> WebGLContextAttributes interface is not important.
Another problem is that a callback interface can't be used as the return
type of getContextAttributes(). (It seems Web IDL doesn't explicitly
disallow this, but it should.)
Am I right in thinking that assigning to the properties of the object
returned from getContextAttributes() shouldn't affect the context? In
that case, I think we can just change WebGLContextAttributes to a
dictionary, and that lets us put the defaults on the dictionary too to
avoid mentioning them in prose:
dictionary WebGLContextAttributes {
boolean alpha = true;
boolean depth = true;
boolean stencil = false;
boolean antialias = true;
boolean premultipliedAlpha = true;
boolean preserveDrawingBuffer = false;
};
getContextAttributes() will then return a new JS object with those six
properties set on it.
Received on Monday, 9 April 2012 02:23:09 UTC