Bug 1313541 - ReadPixels webidl. - r=qdot draft
authorJeff Gilbert (:jgilbert) <jgilbert@mozilla.com>
Mon, 10 Oct 2016 15:34:04 -0700
changeset 430638 e9d649beb708cab833b498aa601146d79c4e4c41
parent 430637 a4c57f3c6d16b7ac759e878b6cf16a399248c94f
child 430639 4959796ab4f5f3820542fbf2dd81d34474a0ac73
push id33862
push userbmo:jgilbert@mozilla.com
push dateFri, 28 Oct 2016 02:14:30 +0000
reviewersqdot
bugs1313541
milestone52.0a1
Bug 1313541 - ReadPixels webidl. - r=qdot MozReview-Commit-ID: Ihq0JNEzLye
dom/webidl/WebGL2RenderingContext.webidl
--- a/dom/webidl/WebGL2RenderingContext.webidl
+++ b/dom/webidl/WebGL2RenderingContext.webidl
@@ -315,23 +315,22 @@ interface WebGL2RenderingContext : WebGL
     /* WebGL-specific enums */
     const GLenum MAX_CLIENT_WAIT_TIMEOUT_WEBGL                 = 0x9247;
 
     /* Buffer objects */
     void copyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset,
                            GLintptr writeOffset, GLsizeiptr size);
     void getBufferSubData(GLenum target, GLintptr offset, ArrayBufferView dstData);
 
-    [Throws] /* Throws on readback in a write-only context. */
+    [Throws] // Throws on readback in a write-only context.
     void readPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format,
                     GLenum type, GLintptr offset);
-    /* Include our WebGL 1 function override(s) */
-    [Throws]
+    [Throws] // Throws on readback in a write-only context.
     void readPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format,
-                    GLenum type, ArrayBufferView pixels);
+                    GLenum type, ArrayBufferView dstData, optional GLuint dstOffset = 0);
 
     /* Framebuffer objects */
     void blitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0,
                          GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
     void framebufferTextureLayer(GLenum target, GLenum attachment, WebGLTexture? texture, GLint level, GLint layer);
 
     [Throws]
     void invalidateFramebuffer(GLenum target, sequence<GLenum> attachments);