Auto merge of #25519 - szeged:mmatyas__webgl_fns_uniforms, r=jdm

Add support for WebGL2 unsigned uniform operations

This adds support for the WebGL2 `uniform[1234]ui` and `uniform[1234]uiv` operations.

See: https://www.khronos.org/registry/webgl/specs/latest/2.0/#3.7.8

<!-- Please describe your changes on the following line: -->

cc @jdm @zakorgy @imiklos

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] There are tests for these changes

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
This commit is contained in:
bors-servo 2020-01-15 10:45:07 -05:00 committed by GitHub
commit f9174a4717
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 643 additions and 134 deletions

View file

@ -1,26 +1,32 @@
[methods-2.html]
[WebGL test #32: Property either does not exist or is not a function: vertexAttribI4ui]
[WebGL test #33: Property either does not exist or is not a function: getIndexedParameter]
expected: FAIL
[WebGL test #30: Property either does not exist or is not a function: vertexAttribI4i]
[WebGL test #34: Property either does not exist or is not a function: createVertexArray]
expected: FAIL
[WebGL test #28: Property either does not exist or is not a function: uniformMatrix3x4fv]
[WebGL test #36: Property either does not exist or is not a function: isVertexArray]
expected: FAIL
[WebGL test #33: Property either does not exist or is not a function: vertexAttribI4uiv]
[WebGL test #18: Property either does not exist or is not a function: uniformMatrix2x4fv]
expected: FAIL
[WebGL test #45: Property either does not exist or is not a function: bindVertexArray]
[WebGL test #25: Property either does not exist or is not a function: vertexAttribI4uiv]
expected: FAIL
[WebGL test #30: Property either does not exist or is not a function: clearBufferuiv]
expected: FAIL
[WebGL test #26: Property either does not exist or is not a function: vertexAttribIPointer]
expected: FAIL
[WebGL test #2: Property either does not exist or is not a function: framebufferTextureLayer]
expected: FAIL
[WebGL test #15: Property either does not exist or is not a function: getFragDataLocation]
[WebGL test #19: Property either does not exist or is not a function: uniformMatrix4x2fv]
expected: FAIL
[WebGL test #43: Property either does not exist or is not a function: deleteVertexArray]
[WebGL test #15: Property either does not exist or is not a function: getFragDataLocation]
expected: FAIL
[WebGL test #4: Property either does not exist or is not a function: invalidateFramebuffer]
@ -32,40 +38,34 @@
[WebGL test #10: Property either does not exist or is not a function: texStorage3D]
expected: FAIL
[WebGL test #21: Property either does not exist or is not a function: uniform2uiv]
expected: FAIL
[WebGL test #1: Property either does not exist or is not a function: blitFramebuffer]
expected: FAIL
[WebGL test #42: Property either does not exist or is not a function: createVertexArray]
[WebGL test #29: Property either does not exist or is not a function: clearBufferiv]
expected: FAIL
[WebGL test #11: Property either does not exist or is not a function: texSubImage3D]
[WebGL test #17: Property either does not exist or is not a function: uniformMatrix3x2fv]
expected: FAIL
[WebGL test #41: Property either does not exist or is not a function: getIndexedParameter]
expected: FAIL
[WebGL test #40: Property either does not exist or is not a function: clearBufferfi]
expected: FAIL
[WebGL test #25: Property either does not exist or is not a function: uniformMatrix3x2fv]
[WebGL test #37: Property either does not exist or is not a function: bindVertexArray]
expected: FAIL
[WebGL test #3: Property either does not exist or is not a function: getInternalformatParameter]
expected: FAIL
[WebGL test #24: Property either does not exist or is not a function: vertexAttribI4ui]
expected: FAIL
[WebGL test #32: Property either does not exist or is not a function: clearBufferfi]
expected: FAIL
[WebGL test #16: Property either does not exist or is not a function: uniformMatrix2x3fv]
expected: FAIL
[WebGL test #13: Property either does not exist or is not a function: compressedTexImage3D]
expected: FAIL
[WebGL test #27: Property either does not exist or is not a function: uniformMatrix4x2fv]
expected: FAIL
[WebGL test #34: Property either does not exist or is not a function: vertexAttribIPointer]
expected: FAIL
[WebGL test #16: Property either does not exist or is not a function: uniform1ui]
[WebGL test #22: Property either does not exist or is not a function: vertexAttribI4i]
expected: FAIL
[WebGL test #12: Property either does not exist or is not a function: copyTexSubImage3D]
@ -74,66 +74,42 @@
[WebGL test #8: Property either does not exist or is not a function: texImage3D]
expected: FAIL
[WebGL test #18: Property either does not exist or is not a function: uniform3ui]
expected: FAIL
[WebGL test #0: Property either does not exist or is not a function: isContextLost]
expected: FAIL
[WebGL test #36: Property either does not exist or is not a function: drawBuffers]
[WebGL test #31: Property either does not exist or is not a function: clearBufferfv]
expected: FAIL
[WebGL test #19: Property either does not exist or is not a function: uniform4ui]
[WebGL test #28: Property either does not exist or is not a function: drawBuffers]
expected: FAIL
[WebGL test #24: Property either does not exist or is not a function: uniformMatrix2x3fv]
[WebGL test #23: Property either does not exist or is not a function: vertexAttribI4iv]
expected: FAIL
[WebGL test #21: Property either does not exist or is not a function: uniformMatrix4x3fv]
expected: FAIL
[WebGL test #11: Property either does not exist or is not a function: texSubImage3D]
expected: FAIL
[WebGL test #9: Property either does not exist or is not a function: texStorage2D]
expected: FAIL
[WebGL test #29: Property either does not exist or is not a function: uniformMatrix4x3fv]
[WebGL test #27: Property either does not exist or is not a function: drawRangeElements]
expected: FAIL
[WebGL test #17: Property either does not exist or is not a function: uniform2ui]
expected: FAIL
[WebGL test #44: Property either does not exist or is not a function: isVertexArray]
expected: FAIL
[WebGL test #31: Property either does not exist or is not a function: vertexAttribI4iv]
[WebGL test #20: Property either does not exist or is not a function: uniformMatrix3x4fv]
expected: FAIL
[WebGL test #6: Property either does not exist or is not a function: readBuffer]
expected: FAIL
[WebGL test #38: Property either does not exist or is not a function: clearBufferuiv]
expected: FAIL
[WebGL test #23: Property either does not exist or is not a function: uniform4uiv]
expected: FAIL
[WebGL test #39: Property either does not exist or is not a function: clearBufferfv]
expected: FAIL
[WebGL test #35: Property either does not exist or is not a function: drawRangeElements]
expected: FAIL
[WebGL test #22: Property either does not exist or is not a function: uniform3uiv]
[WebGL test #35: Property either does not exist or is not a function: deleteVertexArray]
expected: FAIL
[WebGL test #5: Property either does not exist or is not a function: invalidateSubFramebuffer]
expected: FAIL
[WebGL test #26: Property either does not exist or is not a function: uniformMatrix2x4fv]
expected: FAIL
[WebGL test #14: Property either does not exist or is not a function: compressedTexSubImage3D]
expected: FAIL
[WebGL test #37: Property either does not exist or is not a function: clearBufferiv]
expected: FAIL
[WebGL test #20: Property either does not exist or is not a function: uniform1uiv]
expected: FAIL

View file

@ -1,2 +0,0 @@
[unary-minus-operator-in-dynamic-loop.html]
expected: ERROR

View file

@ -81,3 +81,258 @@
[WebGL test #148: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform1iv with srcOffset + srcLength out-of-bounds]
expected: FAIL
[WebGL test #296: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform2fv with srcOffset out-of-bounds]
expected: FAIL
[WebGL test #752: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform4fv with srcOffset out-of-bounds]
expected: FAIL
[WebGL test #364: value put in (16,15) matches value pulled out (0,16)]
expected: FAIL
[WebGL test #1058: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniformMatrix3fv with srcOffset + srcLength out-of-bounds]
expected: FAIL
[WebGL test #959: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniformMatrix2fv with srcOffset = 3 / srcLength = 0]
expected: FAIL
[WebGL test #820: value put in (16,15,14,13) matches value pulled out (0,0,0,16)]
expected: FAIL
[WebGL test #351: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniform2iv with srcOffset = 1 / srcLength = 0]
expected: FAIL
[WebGL test #604: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform3iv with array length minus srcOffset not multiple of ivec3]
expected: FAIL
[WebGL test #603: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform3iv with 0 data]
expected: FAIL
[WebGL test #828: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform4iv with srcOffset out-of-bounds]
expected: FAIL
[WebGL test #753: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform4fv with srcLength out-of-bounds]
expected: FAIL
[WebGL test #1135: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniformMatrix4fv with 0 data]
expected: FAIL
[WebGL test #1132: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniformMatrix4fv with srcOffset out-of-bounds]
expected: FAIL
[WebGL test #972: value put in (16,15,14,13) matches value pulled out (0,0,0,16)]
expected: FAIL
[WebGL test #1133: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniformMatrix4fv with srcLength out-of-bounds]
expected: FAIL
[WebGL test #601: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform3iv with srcLength out-of-bounds]
expected: FAIL
[WebGL test #754: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform4fv with srcOffset + srcLength out-of-bounds]
expected: FAIL
[WebGL test #830: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform4iv with srcOffset + srcLength out-of-bounds]
expected: FAIL
[WebGL test #797: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniform4iv with srcOffset = 3]
expected: FAIL
[WebGL test #528: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform3fv with array length minus srcOffset not multiple of vec3]
expected: FAIL
[WebGL test #807: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniform4iv with srcOffset = 3 / srcLength = 0]
expected: FAIL
[WebGL test #298: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform2fv with srcOffset + srcLength out-of-bounds]
expected: FAIL
[WebGL test #1137: successfullyParsed should be true (of type boolean). Was undefined (of type undefined).]
expected: FAIL
[WebGL test #1111: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniformMatrix4fv with srcOffset = 2 / srcLength = 0]
expected: FAIL
[WebGL test #1045: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniformMatrix3fv with srcOffset = 3 / srcLength = 9]
expected: FAIL
[WebGL test #375: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform2iv with 0 data]
expected: FAIL
[WebGL test #294: value put in (99,99) matches value pulled out (13,0)]
expected: FAIL
[WebGL test #525: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform3fv with srcLength out-of-bounds]
expected: FAIL
[WebGL test #275: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniform2fv with srcOffset = 1 / srcLength = 0]
expected: FAIL
[WebGL test #526: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform3fv with srcOffset + srcLength out-of-bounds]
expected: FAIL
[WebGL test #370: value put in (99,99) matches value pulled out (13,0)]
expected: FAIL
[WebGL test #747: value put in (12,11,10,9) matches value pulled out (15,14,13,12)]
expected: FAIL
[WebGL test #519: value put in (13,12,11) matches value pulled out (14,13,12)]
expected: FAIL
[WebGL test #1056: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniformMatrix3fv with srcOffset out-of-bounds]
expected: FAIL
[WebGL test #522: value put in (99,99,99) matches value pulled out (11,0,0)]
expected: FAIL
[WebGL test #731: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniform4fv with srcOffset = 3 / srcLength = 0]
expected: FAIL
[WebGL test #516: value put in (16,15,14) matches value pulled out (0,16,15)]
expected: FAIL
[WebGL test #288: value put in (16,15) matches value pulled out (0,16)]
expected: FAIL
[WebGL test #527: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform3fv with 0 data]
expected: FAIL
[WebGL test #569: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniform3iv with srcOffset = 1]
expected: FAIL
[WebGL test #374: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform2iv with srcOffset + srcLength out-of-bounds]
expected: FAIL
[WebGL test #592: value put in (16,15,14) matches value pulled out (0,16,15)]
expected: FAIL
[WebGL test #602: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform3iv with srcOffset + srcLength out-of-bounds]
expected: FAIL
[WebGL test #524: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform3fv with srcOffset out-of-bounds]
expected: FAIL
[WebGL test #600: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform3iv with srcOffset out-of-bounds]
expected: FAIL
[WebGL test #981: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniformMatrix2fv with srcLength out-of-bounds]
expected: FAIL
[WebGL test #721: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniform4fv with srcOffset = 3]
expected: FAIL
[WebGL test #299: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform2fv with 0 data]
expected: FAIL
[WebGL test #1101: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniformMatrix4fv with srcOffset = 2]
expected: FAIL
[WebGL test #826: value put in (99,99,99,99) matches value pulled out (11,10,9,0)]
expected: FAIL
[WebGL test #300: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform2fv with array length minus srcOffset not multiple of vec2]
expected: FAIL
[WebGL test #750: value put in (99,99,99,99) matches value pulled out (11,10,9,0)]
expected: FAIL
[WebGL test #1121: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniformMatrix4fv with srcOffset = 2 / srcLength = 16]
expected: FAIL
[WebGL test #367: value put in (14,13) matches value pulled out (15,14)]
expected: FAIL
[WebGL test #595: value put in (13,12,11) matches value pulled out (14,13,12)]
expected: FAIL
[WebGL test #579: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniform3iv with srcOffset = 1 / srcLength = 0]
expected: FAIL
[WebGL test #297: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform2fv with srcLength out-of-bounds]
expected: FAIL
[WebGL test #291: value put in (14,13) matches value pulled out (15,14)]
expected: FAIL
[WebGL test #978: value put in (99,99,99,99) matches value pulled out (11,10,9,0)]
expected: FAIL
[WebGL test #984: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniformMatrix2fv with array length minus srcOffset not multiple of mat2]
expected: FAIL
[WebGL test #980: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniformMatrix2fv with srcOffset out-of-bounds]
expected: FAIL
[WebGL test #829: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform4iv with srcLength out-of-bounds]
expected: FAIL
[WebGL test #1057: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniformMatrix3fv with srcLength out-of-bounds]
expected: FAIL
[WebGL test #823: value put in (12,11,10,9) matches value pulled out (15,14,13,12)]
expected: FAIL
[WebGL test #1035: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniformMatrix3fv with srcOffset = 3 / srcLength = 0]
expected: FAIL
[WebGL test #755: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform4fv with 0 data]
expected: FAIL
[WebGL test #832: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform4iv with array length minus srcOffset not multiple of ivec4]
expected: FAIL
[WebGL test #831: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform4iv with 0 data]
expected: FAIL
[WebGL test #744: value put in (16,15,14,13) matches value pulled out (0,0,0,16)]
expected: FAIL
[WebGL test #1025: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniformMatrix3fv with srcOffset = 3]
expected: FAIL
[WebGL test #341: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniform2iv with srcOffset = 1]
expected: FAIL
[WebGL test #503: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniform3fv with srcOffset = 1 / srcLength = 0]
expected: FAIL
[WebGL test #265: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniform2fv with srcOffset = 1]
expected: FAIL
[WebGL test #493: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniform3fv with srcOffset = 1]
expected: FAIL
[WebGL test #598: value put in (99,99,99) matches value pulled out (11,0,0)]
expected: FAIL
[WebGL test #982: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniformMatrix2fv with srcOffset + srcLength out-of-bounds]
expected: FAIL
[WebGL test #983: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniformMatrix2fv with 0 data]
expected: FAIL
[WebGL test #949: getError expected: NO_ERROR. Was INVALID_VALUE : can set an array of uniforms with gl.uniformMatrix2fv with srcOffset = 3]
expected: FAIL
[WebGL test #756: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform4fv with array length minus srcOffset not multiple of vec4]
expected: FAIL
[WebGL test #1059: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniformMatrix3fv with 0 data]
expected: FAIL
[WebGL test #373: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform2iv with srcLength out-of-bounds]
expected: FAIL
[WebGL test #376: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform2iv with array length minus srcOffset not multiple of ivec2]
expected: FAIL
[WebGL test #975: value put in (12,11,10,9) matches value pulled out (15,14,13,12)]
expected: FAIL
[WebGL test #372: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniform2iv with srcOffset out-of-bounds]
expected: FAIL
[WebGL test #1134: getError expected: INVALID_VALUE. Was NO_ERROR : gl.uniformMatrix4fv with srcOffset + srcLength out-of-bounds]
expected: FAIL