WebGL 2 Transform Feedback Broken (generic bind point blocking non-TF use)
Categories
(Core :: Graphics: CanvasWebGL, defect, P1)
Tracking
()
Tracking | Status | |
---|---|---|
firefox69 | --- | verified |
People
(Reporter: tareksherif, Assigned: jgilbert)
References
Details
(Whiteboard: [good first verify])
Attachments
(2 files, 2 obsolete files)
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:66.0) Gecko/20100101 Firefox/66.0
Steps to reproduce:
Go to this page: https://tsherif.github.io/webgl2bugs/firefox/transform-feedback-unbind.html
Actual results:
Point doesn't animate
Expected results:
Point should animate.
The problem seems to be that when a buffer is bound to TRANSFORM_FEEDBACK_BUFFER it gets bound to the current transform feedback object as well as the default one. The TRANSFORM_FEEDBACK_BUFFER on the default transform feedback object then has to be explicitly unbound. See comments in the source code for details: https://github.com/tsherif/webgl2bugs/blob/master/firefox/transform-feedback-unbind.html
Broken on both Windows 10 and Ubuntu 16.04. Works in Chrome on both.
Updated•5 years ago
|
Comment 1•5 years ago
|
||
ni?jgilbert to confirm we're misimplementing semantics here
Assignee | ||
Comment 2•5 years ago
|
||
(In reply to tareksherif from comment #0)
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:66.0) Gecko/20100101 Firefox/66.0
Steps to reproduce:
Go to this page: https://tsherif.github.io/webgl2bugs/firefox/transform-feedback-unbind.html
Actual results:
Point doesn't animate
Expected results:
Point should animate.
The problem seems to be that when a buffer is bound to TRANSFORM_FEEDBACK_BUFFER it gets bound to the current transform feedback object as well as the default one. The TRANSFORM_FEEDBACK_BUFFER on the default transform feedback object then has to be explicitly unbound. See comments in the source code for details: https://github.com/tsherif/webgl2bugs/blob/master/firefox/transform-feedback-unbind.html
Broken on both Windows 10 and Ubuntu 16.04. Works in Chrome on both.
The TF Buffer object is probably still bound to the TRANSFORM_FEEDBACK_BUFFER non-indexed bind point, which Firefox still treats as "bound for transform feedback".
A workaround is to call bindBuffer(TRANSFORM_FEEDBACK_BUFFER, null) after bindBufferBase/Range(TRANSFORM_FEEDBACK_BUFFER, ...).
Assignee | ||
Updated•5 years ago
|
Assignee | ||
Updated•5 years ago
|
Assignee | ||
Comment 3•5 years ago
|
||
- Remove WebGLBuffer::SetSlot
- Make most bindBuffer calls lazy.
- Replace nsTArray with std::vector in WebGLVertexArray.
Assignee | ||
Updated•5 years ago
|
Assignee | ||
Comment 5•5 years ago
|
||
This lets us dodge an "unexpected GL error" assert due to differences in handling
between GLES3 and GL410 and below. (macOS)
Assignee | ||
Comment 6•5 years ago
|
||
This lets us dodge an "unexpected GL error" assert due to differences in handling
between GLES3 and GL410 and below. (macOS)
Assignee | ||
Updated•5 years ago
|
Assignee | ||
Updated•5 years ago
|
Assignee | ||
Comment 7•5 years ago
|
||
BindBufferBase/Range will fail (on some drivers) if the buffer name has never been bound.
(GenBuffers makes a name, but BindBuffer initializes that name as a real buffer object)
Updated•5 years ago
|
Updated•5 years ago
|
Pushed by jgilbert@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/0c28fedb2c6a Refactor (non-)transform-feedback binding/use checks. r=lsalzman https://hg.mozilla.org/integration/autoland/rev/979f1395a70c Add GLBuffer prebind workaround. r=lsalzman
Comment 9•5 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/0c28fedb2c6a
https://hg.mozilla.org/mozilla-central/rev/979f1395a70c
Updated•5 years ago
|
Updated•5 years ago
|
Comment 10•5 years ago
|
||
Following the STR from the description, I reproduced this issue using Fx 68.0a1(2018-04-03) on Ubuntu 18.04 LTS and on Windows 10 using the same Fx version. I can confirm that this issue is fixed using Fx 69.0b13 on the same environments.
Description
•