From 3e411b1367f00e585d7d6e42ab5f68d1b5e54fe7 Mon Sep 17 00:00:00 2001
From: Rik Cabanier offset is the byte offset into the WebGLBuffer's data store; generates an The ETC2 and EAC texture formats defined in OpenGL ES 3.0 are not available in WebGL 2.0.
+
+ Renders the given element to the currently bound WebGLTexture. The width and height of the texture are derived from the CSS width and height of the element at the time of rendering. Add links to whatwg. TBD: define state of rendering + security. These will be more links to whatwg If no WebGLBuffer is bound to the The combination of internalformat, format, and type must be listed in the following table: Renders the given element to the currently bound WebGLTexture. The width and height of the texture are derived from the CSS width and height of the element at the time of rendering. Add links to whatwg. The width and height of the texture are derived from the CSS borderbox of the element at the time of rendering. Add links to whatwg. TBD: define state of rendering + security. These will be more links to whatwg If no WebGLBuffer is bound to the If this function is called with an If a WebGLBuffer is bound to the The combination of internalformat, format, and type must be listed in the following table:
+ If pixel store parameter constraints are not met,
+ generates an Renders the given element to the currently bound WebGLTexture. The texture is resized to TBD: define state of rendering + security. These will be more links to whatwg If this function is called with an If a WebGLBuffer is bound to the See texElementImage2D for the interpretation of the internalformat, format and type arguments, and notes on the
+ If pixel store parameter constraints are not met,
+ generates an Renders the given element to the currently bound WebGLTexture.Texture objects
INVALID_VALUE error if it's less than 0.PIXEL_PACK_BUFFER target, generates an
+ INVALID_OPERATION error.
+
+
+ Internal Format Format Type
+ RGB RGB UNSIGNED_BYTE
+ RGBA RGBA UNSIGNED_BYTE
+ RGB16F RGB HALF_FLOAT
FLOAT
+ RGB32F RGB FLOAT
+ RGBA16F RGBA HALF_FLOAT
FLOAT
+ RGBA32F RGBA FLOAT Programs and Shaders
diff --git a/specs/latest/2.0/webgl2.idl b/specs/latest/2.0/webgl2.idl
index c810cbf62..f9d6d961c 100644
--- a/specs/latest/2.0/webgl2.idl
+++ b/specs/latest/2.0/webgl2.idl
@@ -558,6 +558,9 @@ interface mixin WebGL2RenderingContextOverloads
optional unsigned long long srcOffset = 0,
optional GLuint srcLengthOverride = 0);
+ undefined texElementImage2D(GLenum target, GLint level, GLint internalformat, GLenum format, GLenum type,
+ Element element);
+
undefined uniform1fv(WebGLUniformLocation? location, Float32List data, optional unsigned long long srcOffset = 0,
optional GLuint srcLength = 0);
undefined uniform2fv(WebGLUniformLocation? location, Float32List data, optional unsigned long long srcOffset = 0,
From c16ae72dc7bca17797c7d0a79ed6807d04fa6480 Mon Sep 17 00:00:00 2001
From: Rik Cabanier Texture objects
PIXEL_PACK_BUFFER target, generates an
- INVALID_OPERATION error.HTMLElement that is not a direct descendant of the canvas of the current context, generates an INVALID_OPERATION error.PIXEL_UNPACK_BUFFER target, generates an INVALID_OPERATION error.
+
@@ -2231,6 +2231,27 @@ Internal Format Format Type Texture objects
RGBA16F RGBA HALF_FLOAT
FLOATRGBA32F RGBA FLOAT INVALID_OPERATION error.
+ width and height>. Add links to whatwg.HTMLElement that is not a direct descendant of the canvas of the current context, generates an INVALID_OPERATION error.PIXEL_UNPACK_BUFFER target, generates an INVALID_OPERATION error.UNPACK_PREMULTIPLY_ALPHA_WEBGL pixel storage parameter. INVALID_OPERATION error.
+ Texture objects
Texture objects
Renders the given element to the currently bound WebGLTexture.
+The width and height of the texture are set by the passed in width and height.
+TBD: define state of rendering + security. These will be more links to whatwg
+If this function is called with an HTMLElement that is not a direct descendant of the canvas of the current context, generates an INVALID_OPERATION error.
If a WebGLBuffer is bound to the PIXEL_UNPACK_BUFFER target, generates an INVALID_OPERATION error.
The combination of internalformat, format, and type must be listed in the following table:
+| Internal Format | Format | Type |
|---|---|---|
| RGB | RGB | UNSIGNED_BYTE |
| RGBA | RGBA | UNSIGNED_BYTE |
| RGB16F | RGB | HALF_FLOAT FLOAT |
| RGB32F | RGB | FLOAT |
| RGBA16F | RGBA | HALF_FLOAT FLOAT |
| RGBA32F | RGBA | FLOAT |
+ If pixel store parameter constraints are not met,
+ generates an INVALID_OPERATION error.
+
Renders the given element to the currently bound WebGLTexture.
+sx, sy, swidth and sheight define a rectangular slice of the element's borderbox. This slice determines the size of the generated texture.
+TBD: define state of rendering + security. These will be more links to whatwg
+If this function is called with an HTMLElement that is not a direct descendant of the canvas of the current context, generates an INVALID_OPERATION error.
If a WebGLBuffer is bound to the PIXEL_UNPACK_BUFFER target, generates an INVALID_OPERATION error.
The combination of internalformat, format, and type must be listed in the following table:
+| Internal Format | Format | Type |
|---|---|---|
| RGB | RGB | UNSIGNED_BYTE |
| RGBA | RGBA | UNSIGNED_BYTE |
| RGB16F | RGB | HALF_FLOAT FLOAT |
| RGB32F | RGB | FLOAT |
| RGBA16F | RGBA | HALF_FLOAT FLOAT |
| RGBA32F | RGBA | FLOAT |
+ If pixel store parameter constraints are not met,
+ generates an INVALID_OPERATION error.
+
Renders the given element to the currently bound WebGLTexture.
+sx, sy, swidth and sheight define a rectangular slice of the element's when its size is set to the width and height. This slice determines the size of the generated texture.
+TBD: define state of rendering + security. These will be more links to whatwg
+If this function is called with an HTMLElement that is not a direct descendant of the canvas of the current context, generates an INVALID_OPERATION error.
If a WebGLBuffer is bound to the PIXEL_UNPACK_BUFFER target, generates an INVALID_OPERATION error.
The combination of internalformat, format, and type must be listed in the following table:
+| Internal Format | Format | Type |
|---|---|---|
| RGB | RGB | UNSIGNED_BYTE |
| RGBA | RGBA | UNSIGNED_BYTE |
| RGB16F | RGB | HALF_FLOAT FLOAT |
| RGB32F | RGB | FLOAT |
| RGBA16F | RGBA | HALF_FLOAT FLOAT |
| RGBA32F | RGBA | FLOAT |
+ If pixel store parameter constraints are not met,
+ generates an INVALID_OPERATION error.
+
typedef long long GLint64;
typedef unsigned long long GLuint64;
+
+dictionary WebGLCopyElementImageConfig {
+ GLfloat sx = 0;
+ GLfloat sy = 0;
+ GLfloat swidth;
+ GLfloat sheight;
+ GLsizei width;
+ GLsizei height;
+};
@@ -935,6 +944,9 @@ Renders the given element to the currently bound WebGLTexture.
-The width and height of the texture are derived from the CSS borderbox of the element at the time of rendering. Add links to whatwg.
-TBD: define state of rendering + security. These will be more links to whatwg
-If this function is called with an HTMLElement that is not a direct descendant of the canvas of the current context, generates an INVALID_OPERATION error.
If a WebGLBuffer is bound to the PIXEL_UNPACK_BUFFER target, generates an INVALID_OPERATION error.
The combination of internalformat, format, and type must be listed in the following table:
-| Internal Format | Format | Type |
|---|---|---|
| RGB | RGB | UNSIGNED_BYTE |
| RGBA | RGBA | UNSIGNED_BYTE |
| RGB16F | RGB | HALF_FLOAT FLOAT |
| RGB32F | RGB | FLOAT |
| RGBA16F | RGBA | HALF_FLOAT FLOAT |
| RGBA32F | RGBA | FLOAT |
- If pixel store parameter constraints are not met,
- generates an INVALID_OPERATION error.
-
Renders the given element to the currently bound WebGLTexture.
-The width and height of the texture are set by the passed in width and height.
-TBD: define state of rendering + security. These will be more links to whatwg
-If this function is called with an HTMLElement that is not a direct descendant of the canvas of the current context, generates an INVALID_OPERATION error.
If a WebGLBuffer is bound to the PIXEL_UNPACK_BUFFER target, generates an INVALID_OPERATION error.
The combination of internalformat, format, and type must be listed in the following table:
-| Internal Format | Format | Type |
|---|---|---|
| RGB | RGB | UNSIGNED_BYTE |
| RGBA | RGBA | UNSIGNED_BYTE |
| RGB16F | RGB | HALF_FLOAT FLOAT |
| RGB32F | RGB | FLOAT |
| RGBA16F | RGBA | HALF_FLOAT FLOAT |
| RGBA32F | RGBA | FLOAT |
- If pixel store parameter constraints are not met,
- generates an INVALID_OPERATION error.
-
Renders the given element to the currently bound WebGLTexture.
-sx, sy, swidth and sheight define a rectangular slice of the element's borderbox. This slice determines the size of the generated texture.
-TBD: define state of rendering + security. These will be more links to whatwg
-If this function is called with an HTMLElement that is not a direct descendant of the canvas of the current context, generates an INVALID_OPERATION error.
If a WebGLBuffer is bound to the PIXEL_UNPACK_BUFFER target, generates an INVALID_OPERATION error.
The combination of internalformat, format, and type must be listed in the following table:
-| Internal Format | Format | Type |
|---|---|---|
| RGB | RGB | UNSIGNED_BYTE |
| RGBA | RGBA | UNSIGNED_BYTE |
| RGB16F | RGB | HALF_FLOAT FLOAT |
| RGB32F | RGB | FLOAT |
| RGBA16F | RGBA | HALF_FLOAT FLOAT |
| RGBA32F | RGBA | FLOAT |
- If pixel store parameter constraints are not met,
- generates an INVALID_OPERATION error.
-
Renders the given element to the currently bound WebGLTexture.
-sx, sy, swidth and sheight define a rectangular slice of the element's when its size is set to the width and height. This slice determines the size of the generated texture.
-TBD: define state of rendering + security. These will be more links to whatwg
-If this function is called with an HTMLElement that is not a direct descendant of the canvas of the current context, generates an INVALID_OPERATION error.
If a WebGLBuffer is bound to the PIXEL_UNPACK_BUFFER target, generates an INVALID_OPERATION error.
The combination of internalformat, format, and type must be listed in the following table:
-| Internal Format | Format | Type |
|---|---|---|
| RGB | RGB | UNSIGNED_BYTE |
| RGBA | RGBA | UNSIGNED_BYTE |
| RGB16F | RGB | HALF_FLOAT FLOAT |
| RGB32F | RGB | FLOAT |
| RGBA16F | RGBA | HALF_FLOAT FLOAT |
| RGBA32F | RGBA | FLOAT |
| Internal Format | Implied Source Type |
|---|---|
| RGBA8 | UNSIGNED_BYTE |
| SRGB8_ALPHA8 | UNSIGNED_BYTE |
| RGBA16F | HALF_FLOAT |
| RGBA32F | FLOAT |
- If pixel store parameter constraints are not met,
- generates an INVALID_OPERATION error.
-
Renders the given element to the currently bound WebGLTexture.
-The texture is resized to width and height>. Add links to whatwg.
TBD: define state of rendering + security. These will be more links to whatwg
-If this function is called with an HTMLElement that is not a direct descendant of the canvas of the current context, generates an INVALID_OPERATION error.
If a WebGLBuffer is bound to the PIXEL_UNPACK_BUFFER target, generates an INVALID_OPERATION error.
See texElementImage2D for the interpretation of the internalformat, format and type arguments, and notes on the UNPACK_PREMULTIPLY_ALPHA_WEBGL pixel storage parameter.
If internalformat is not listed in the table above, generates an INVALID_ENUM error.
If any supplied numeric member of config is negative, or if the computed source rectangle width, source rectangle height, texture width, or texture height is not positive, generates an INVALID_VALUE error.
If pixel store parameter constraints are not met,
generates an INVALID_OPERATION error.
@@ -2329,7 +2253,6 @@
If target is not TEXTURE_2D, generates an INVALID_ENUM error.
If no WebGLTexture is bound to target, generates an INVALID_OPERATION error.
If a WebGLBuffer is bound to the PIXEL_UNPACK_BUFFER target, generates an INVALID_OPERATION error.
config.sx and config.sy are in CSS pixels and default to 0. config.swidth and config.sheight are in CSS pixels and default to the source's natural width minus config.sx and natural height minus config.sy, respectively. Together, these members define the source rectangle of the element image snapshot to render.
config.width and config.height are in texels and define the generated texture size. If omitted, each dimension defaults to the source rectangle size scaled by the inverse of the canvas-grid-to-CSS scaling factor used to produce the element image snapshot.
If config.sx, config.sy, config.swidth, and config.sheight are all supplied, they define the source rectangle of the element image snapshot to render, in CSS pixels. If none of them are supplied, the source rectangle has sx and sy of 0, swidth equal to the source's natural width, and sheight equal to the source's natural height. If only some of them are supplied, generates an INVALID_VALUE error.
If config.width and config.height are both supplied, they define the generated texture size, in texels. If neither member is supplied, the texture width and height default to the source rectangle size scaled by the inverse of the canvas-grid-to-CSS scaling factor used to produce the element image snapshot. If only one of them is supplied, generates an INVALID_VALUE error.
The internalformat argument must be one of the values in the following table. Each value has an implied source format of RGBA and the listed implied source type:
| Internal Format | Implied Source Type |
|---|
If internalformat is not listed in the table above, generates an INVALID_ENUM error.
If any supplied numeric member of config is negative, or if the computed source rectangle width, source rectangle height, texture width, or texture height is not positive, generates an INVALID_VALUE error.
- If pixel store parameter constraints are not met,
- generates an INVALID_OPERATION error.
-