Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for WebGL2 GetIndexedParameter #25930

Merged
merged 1 commit into from Mar 10, 2020

Conversation

@mmatyas
Copy link
Contributor

mmatyas commented Mar 9, 2020

Adds support for the GetIndexedParameter WebGL2 call.

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

Depends on #25915.

cc @jdm @zakorgy


  • ./mach build -d does not report any errors
  • ./mach test-tidy does not report any errors
  • There are tests for these changes
@highfive
Copy link

highfive commented Mar 9, 2020

Heads up! This PR modifies the following files:

  • @asajeffrey: components/script/dom/webidls/WebGL2RenderingContext.webidl, components/script/dom/webgl2renderingcontext.rs, components/script/dom/webglprogram.rs
  • @KiChjang: components/script/dom/webidls/WebGL2RenderingContext.webidl, components/script/dom/webgl2renderingcontext.rs, components/script/dom/webglprogram.rs
@highfive
Copy link

highfive commented Mar 9, 2020

warning Warning warning

  • These commits modify unsafe code. Please review it carefully!
@mmatyas mmatyas force-pushed the mmatyas:webgl_fns_indexed_unibuf branch from 50fbfc1 to 52fd6f8 Mar 9, 2020
@mmatyas
Copy link
Contributor Author

mmatyas commented Mar 9, 2020

Rebased and fixed the tidy.

@@ -26,3 +26,6 @@
[WebGL test #29: getError expected: NO_ERROR. Was INVALID_OPERATION : linking transform feedback shader should not set an error]
expected: FAIL

[WebGL test #11: gl.getIndexedParameter(gl.TRANSFORM_FEEDBACK_BUFFER_BINDING, 0) should be null. Was [object WebGLBuffer\].]

This comment has been minimized.

@jdm

jdm Mar 9, 2020

Member

The new failures in this test and a couple previous ones suggest that our new implementation doesn't quite match the specification.

@@ -1,5 +1,17 @@
[object-deletion-behaviour-2.html]
expected: ERROR
[WebGL test #12: gl.isBuffer(bufferBaseTransformFeedback) should be false. Was true.]

This comment has been minimized.

@jdm

jdm Mar 9, 2020

Member

Judging by

pub fn is_deleted(&self) -> bool {
, this new failure appears to be caused by the attachment count having a different value after these changes.

@jdm jdm assigned jdm and unassigned paulrouget Mar 10, 2020
Adds support for the `GetIndexedParameter` WebGL2 call.

See: https://www.khronos.org/registry/webgl/specs/latest/2.0/#3.7.2
@mmatyas mmatyas force-pushed the mmatyas:webgl_fns_indexed_unibuf branch from 52fd6f8 to 215dd0a Mar 10, 2020
@mmatyas
Copy link
Contributor Author

mmatyas commented Mar 10, 2020

You're right, I've forgot to decrement the counters in DeleteBuffer. Fixed and updated the tests, the rest of the fails are now related to the transform feedback implementation.

@jdm
Copy link
Member

jdm commented Mar 10, 2020

@bors-servo
Copy link
Contributor

bors-servo commented Mar 10, 2020

📌 Commit 215dd0a has been approved by jdm

@bors-servo
Copy link
Contributor

bors-servo commented Mar 10, 2020

Testing commit 215dd0a with merge 12a188a...

bors-servo added a commit that referenced this pull request Mar 10, 2020
Add support for WebGL2 GetIndexedParameter

Adds support for the `GetIndexedParameter` WebGL2 call.

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

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

Depends on #25915.

cc @jdm @zakorgy

---
<!-- 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. -->
@bors-servo
Copy link
Contributor

bors-servo commented Mar 10, 2020

💔 Test failed - status-taskcluster

@jdm
Copy link
Member

jdm commented Mar 10, 2020

@bors-servo
Copy link
Contributor

bors-servo commented Mar 10, 2020

Testing commit 215dd0a with merge 30fafdc...

@bors-servo
Copy link
Contributor

bors-servo commented Mar 10, 2020

☀️ Test successful - status-taskcluster
Approved by: jdm
Pushing 30fafdc to master...

@bors-servo bors-servo merged commit 30fafdc into servo:master Mar 10, 2020
2 checks passed
2 checks passed
Community-TC (pull_request) TaskGroup: success
Details
homu Test successful
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

5 participants
You can’t perform that action at this time.