KhronosGroup/WebGL — pull request #631 by Oletus (2014-07-23 12:24:11+00:00)
Title: WebGL 2: Add querying of 64-bit values to getParameter etc.

GetInteger64v is subsumed into getParameter, GetInteger64i_v is subsumed
into getIndexedParameter, and GetBufferParameteri64v is subsumed into
getBufferParameter. This maintains the consistency of the API, at the
cost of losing the ability to precisely represent all possible 64-bit
return values. The 52-bit precision provided by ECMAScript numbers will
still enable processing individual buffers with exact size up to the
petabyte scale.

If full 64-bit precision of buffer sizes would be desired instead, the
whole API would need to be overhauled to properly support it, so that
sizes with 64-bit precision could be passed into the API as well as
queried from it.

In case the maximum size values returned by the native GL are not
exactly representable as ECMAScript numbers, it is suggested that the
WebGL implementation rounds them down to values that are, such as the
nearest lower power of two, or simply to 2^53.

This commit sets the type of all returned 64-bit values to signed GLint64
or GLsizeiptr to be consistent with native GL.

64-bit values TRANSFORM_FEEDBACK_BUFFER_OFFSET,
TRANSFORM_FEEDBACK_BUFFER_SIZE, UNIFORM_BUFFER_OFFSET, and
UNIFORM_BUFFER_SIZE are removed from the values returned by getParameter,
since they are only returned by the indexed get functions in GLES 3.0,
and so should only be returned by getIndexedParameter in WebGL.