Auto merge of #26336 - szeged:mmatyas__webgl_fns_getparam4, r=jdm

Add support for WebGL2 MIN_PROGRAM_TEXEL_OFFSET

Improves the support of the WebGL2 `MIN_PROGRAM_TEXEL_OFFSET` property (ie. stores it as a signed integer) and adds support for querying it using GetParameter.

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

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

cc @jdm @zakorgy

Depends on #26333 because they touch the same test files.

---
<!-- 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-05-01 13:30:05 -04:00 committed by GitHub
commit d08c4fff15
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 14 additions and 8 deletions

View file

@ -1046,6 +1046,9 @@ impl WebGL2RenderingContextMethods for WebGL2RenderingContext {
constants::MAX_UNIFORM_BLOCK_SIZE => {
return DoubleValue(self.base.limits().max_uniform_block_size as f64)
},
constants::MIN_PROGRAM_TEXEL_OFFSET => {
return Int32Value(self.base.limits().min_program_texel_offset)
},
_ => {},
}