| GL ES 2.0 | GLWeb20Context |
|---|---|
| Core GL ES 2.0 | |
| ActiveTexture (GLenum texture) | |
| AttachShader (GLuint program, GLuint shader) | |
| BindAttribLocation (GLuint program, GLuint index, const char *name) | |
| BindBuffer (GLenum target, GLuint buffer) | |
| BindTexture (GLenum target, GLuint texture) | |
| BlendColor (GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha) | |
| BlendEquation (GLenum mode) | |
| BlendEquationSeparate (GLenum modeRGB, GLenum modeAlpha) | |
| BlendFunc (GLenum sfactor, GLenum dfactor) | |
| BlendFuncSeparate (GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha) | |
| BufferData (GLenum target, GLsizeiptr size, const void *data, GLenum usage) | bufferData (uint target, Array data, uint elementType, uint usage) |
| BufferSubData (GLenum target, GLintptr offset, GLsizeiptr size, const void *data) | bufferSubData (uint target, uint offset, Array data, uint elementType) |
| Clear (GLbitfield mask) | |
| ClearColor (GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha) | |
| ClearDepthf (GLclampf depth) | clearDepth (float depth); |
| ClearStencil (GLint s) | |
| ColorMask (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha) | |
| CompressedTexImage2D (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const void *data) CompressedTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *data) |
Directly loading compressed images is not supported. |
| CopyTexImage2D (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border) CopyTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height) |
TODO |
| GLuint CreateProgram (void) | |
| GLuint CreateShader (GLenum type) | |
| CullFace (GLenum mode) | |
| DeleteBuffers (GLsizei n, const GLuint *buffers) | deleteBuffers (Array buffers) |
| DeleteTextures (GLsizei n, const GLuint *textures) | deleteTextures (Array textures) |
| DeleteProgram (GLuint program) | |
| DeleteShader (GLuint shader) | |
| DetachShader (GLuint program, GLuint shader) | |
| DepthFunc (GLenum func) | |
| DepthMask (GLboolean flag) | |
| DepthRangef (GLclampf zNear, GLclampf zFar) | |
| Disable (GLenum cap) | |
| DisableVertexAttribArray (GLuint index) | |
| DrawArrays (GLenum mode, GLint first, GLsizei count) | |
| DrawElements (GLenum mode, GLsizei count, GLenum type, const void *indices) | drawElements (uint mode, uint count, Array indices) -- will always be treated as UNSIGNED_SHORT |
| Enable (GLenum cap) | |
| EnableVertexAttribArray (GLuint index) | |
| Finish (void) | NONE |
| Flush (void) | NONE |
| FrontFace (GLenum mode) | |
| GetActiveAttrib (GLuint program, GLuint index, GLsizei bufsize, GLsizei *length, GLint *size, GLenum *type, char *name) | Object getActiveAttrib (uint program, uint index) Result object will be of the form { type: ..., size: ..., name: ... }, or null. |
| GetActiveUniform (GLuint program, GLuint index, GLsizei bufsize, GLsizei *length, GLint *size, GLenum *type, char *name) | Object getActiveUniform (uint program, uint index) Result object will be of the form { type: ..., size: ..., name: ... }, or null. |
| GetAttachedShaders (GLuint program, GLsizei maxcount, GLsizei *count, GLuint *shaders) | Array getAttachedShaders (uint program) |
| int GetAttribLocation (GLuint program, const char *name) | int getAttribLocation (uint program, string name) |
| GetBufferParameteriv (GLenum target, GLenum pname, GLint *params) | Object getBufferParameter (uint target, uint pname) Result will be either a single value or an array of values, depending on pname. |
| GenBuffers (GLsizei n, GLuint *buffers) | Array genBuffers (uint n) |
| GenTextures (GLsizei n, GLuint *textures) | Array genTextures (uint n) |
| enum GetError (void) | |
| GetBooleanv (GLenum pname, GLboolean *params) GetFloatv (GLenum pname, GLfloat *params) GetIntegerv (GLenum pname, GLint *params) const GLubyte * GetString (GLenum name) |
Object getParameter(uint pname) The result object will be a boolean, float, integer, or string; or an array of the first three, as appropriate for pname. |
| GetPointerv (GLenum pname, void **params) | Not supported. |
| GetProgramiv (GLuint program, GLenum pname, GLint *params) | Object getProgramParameter (uint program, uint pname) |
| GetProgramInfoLog (GLuint program, GLsizei bufsize, GLsizei *length, char *infolog) | string getProgramInfoLog (uint program) |
| GetTexParameteriv (GLenum target, GLenum pname, GLint *params) GetTexParameterfv (GLenum target, GLenum pname, GLfloat *params) |
Object getTexParameter(uint target, uint pname) |
| GetUniformfv (GLuint program, GLint location, GLfloat *params) | TODO Object getUniform(uint program, uint location) |
| GetUniformLocation (GLuint program, const char *name) | |
| GetVertexAttribfv (GLuint index, GLenum pname, GLfloat *params) GetVertexAttribiv (GLuint index, GLenum pname, GLint *params) | Object getVertexAttrib(uint index, uint pname) |
| GetVertexAttribPointerv (GLuint index, GLenum pname, void **pointer) | Not supported. |
| Hint (GLenum target, GLenum mode) | |
| boolean IsBuffer (GLuint buffer) | |
| boolean IsEnabled (GLenum cap) | |
| boolean IsProgram (GLuint program) | |
| boolean IsShader (GLuint shader) | |
| boolean IsTexture (GLuint texture) | |
| LineWidth (GLfloat width) | |
| LinkProgram (GLuint program) | |
| PixelStorei (GLenum pname, GLint param) | Not supported. (Is it needed?) |
| PointSize (GLfloat size) | |
| PolygonOffset (GLfloat factor, GLfloat units) | |
| ReadPixels (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, void *pixels) | TODO -- this is similar to 2d's getImageData. |
| SampleCoverage (GLclampf value, GLboolean invert) | |
| Scissor (GLint x, GLint y, GLsizei width, GLsizei height) | |
| StencilFunc (GLenum func, GLint ref, GLuint mask) | |
| StencilFuncSeparate (GLenum face, GLenum func, GLint ref, GLuint mask) | |
| StencilMask (GLuint mask) | |
| StencilMaskSeparate (GLenum face, GLuint mask) | |
| StencilOp (GLenum fail, GLenum zfail, GLenum zpass) | |
| StencilOpSeparate (GLenum face, GLenum fail, GLenum zfail, GLenum zpass) | |
| TexImage2D (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const void *pixels) | texImage2D (uint target, int level, uint internalformat, uint width, uint height, int border, uint format, uint type, Array pixels); |
| TexParameteri (GLenum target, GLenum pname, GLint param) TexParameterf (GLenum target, GLenum pname, GLfloat param) TexParameteriv (GLenum target, GLenum pname, const GLint *params) TexParameterfv (GLenum target, GLenum pname, const GLfloat *params) |
texParameter (uint target, uint pname, Object param) param is either a single value or an array of values. |
| TexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const void *pixels) | TODO |
| Uniform1i (GLint location, GLint x) Uniform2i (GLint location, GLint x, GLint y) Uniform3i (GLint location, GLint x, GLint y, GLint z) Uniform4i (GLint location, GLint x, GLint y, GLint z, GLint w) Uniform1iv (GLint location, GLsizei count, const GLint *v) Uniform2iv (GLint location, GLsizei count, const GLint *v) Uniform3iv (GLint location, GLsizei count, const GLint *v) Uniform4iv (GLint location, GLsizei count, const GLint *v) Uniform1f (GLint location, GLfloat x) Uniform2f (GLint location, GLfloat x, GLfloat y) Uniform3f (GLint location, GLfloat x, GLfloat y, GLfloat z) Uniform4f (GLint location, GLfloat x, GLfloat y, GLfloat z, GLfloat w) Uniform1fv (GLint location, GLsizei count, const GLfloat *v) Uniform2fv (GLint location, GLsizei count, const GLfloat *v) Uniform3fv (GLint location, GLsizei count, const GLfloat *v) Uniform4fv (GLint location, GLsizei count, const GLfloat *v) UniformMatrix2fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value) UniformMatrix3fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value) UniformMatrix4fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value) |
uniformi (uint location, ...) uniformi (uint location, uint uniformSize, uint uniformCount, ...) uniformf (uint location, ...) uniformf (uint location, uint uniformSize, uint uniformCount, ...) uniformMatrix (uint location, Array matrix) uniformMatrix (uint location, uint uniformSize, uint uniformCount, Array matrix) ... is either an an array or 1..4 arguments. For matrices, the matrix must be 4, 9, or 16 elements. For the form without an explicit uniformSize and uniformCount, the count is 1 and uniformSize is the length of the array (or number of arguments for the non-matrix variant). For the full form, the array must be uniformSize*uniformCount elements in length. For matrices, the explicit or implicit uniformSize must be 4, 9, or 16. Desired API, but there are problems; unimplemented for now: uniform (uint location, a, [b, [c, [d]]]) uniform (uint location, [...]) The uniform at the given location will be examined, and the arguments will be converted to the appropriate type. If the uniform is an array or a matrix, only the array form is valid. |
| UseProgram (GLuint program) | |
| ValidateProgram (GLuint program) | |
| VertexAttrib1f (GLuint indx, GLfloat x) VertexAttrib2f (GLuint indx, GLfloat x, GLfloat y) VertexAttrib3f (GLuint indx, GLfloat x, GLfloat y, GLfloat z) VertexAttrib4f (GLuint indx, GLfloat x, GLfloat y, GLfloat z, GLfloat w) VertexAttrib1fv (GLuint indx, const GLfloat *values) VertexAttrib2fv (GLuint indx, const GLfloat *values) VertexAttrib3fv (GLuint indx, const GLfloat *values) VertexAttrib4fv (GLuint indx, const GLfloat *values) |
vertexAttrib (uint index, ...) ... is either 1..4 arguments, or an array of 1..4 elements |
| VertexAttribPointer (GLuint indx, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const void *ptr) | vertexAttribPointer (uint index, Object bufferObject) vertexAttribPointer (uint index, uint size, uint elementType, Array data) |
| Viewport (GLint x, GLint y, GLsizei width, GLsizei height) | |
| OES_framebuffer_object | |
| TODO | |
| OES_mapbuffer | |
| NOT SUPPORTED | |
| OES_texture_3D | |
| TODO | |
| OES_shader_source | |
| CompileShader (GLuint shader) | |
| GetShaderiv (GLuint shader, GLenum pname, GLint *params) Object getShaderParameter (uint shader, uint pname) |
|
| GetShaderInfoLog (GLuint shader, GLsizei bufsize, GLsizei *length, char *infolog) | string getShaderInfoLog (uint shader) |
| GetShaderSource (GLuint shader, GLsizei bufsize, GLsizei *length, char *source) | string getShaderSource (uint shader) |
| ReleaseShaderCompilerOES (void) | NONE |
| ShaderSource (GLuint shader, GLsizei count, const char **string, const GLint *length) | shaderSource (uint shader, string source) |
| OES_shader_binary | |
| NOT SUPPORTED | |
| texImage2DHTML (uint target, DOMImageElement image) texImage2DHTML (uint target, int level, DOMImageElement image) |
| texSubImage2DHTML (uint target, DOMImageElement image, int xoff, int yoff, int width, int height) texSubImage2DHTML (uint target, int level, DOMImageElement image, int xoff, int yoff, int width, int height) |
Last updated: 2 Mar 2009