Closed Bug 1209384 Opened 4 years ago Closed 4 years ago

WebGL 2 - GetQuery returns wrong query.

Categories

(Core :: Canvas: WebGL, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla44
Tracking Status
firefox44 --- fixed

People

(Reporter: kamidphish, Assigned: kamidphish)

References

()

Details

Attachments

(1 file)

gl.getQuery(gl.ANY_SAMPLES_PASSED_CONSERVATIVE, gl.CURRENT_QUERY) returns a WebGLQuery object when gl.getQuery(gl.ANY_SAMPLES_PASSED, gl.CURRENT_QUERY) is active, instead of returning null.
Comment on attachment 8667091 [details] [diff] [review]
Check active query has same type as target. r=jgilbert

Review of attachment 8667091 [details] [diff] [review]:
-----------------------------------------------------------------

::: dom/canvas/WebGL2ContextQueries.cpp
@@ +278,2 @@
>      nsRefPtr<WebGLQuery> tmp = targetSlot.get();
> +    if (tmp != nullptr && tmp->mType != target) {

`tmp` not `tmp != nullptr`.
Attachment #8667091 - Flags: review?(jgilbert) → review+
https://hg.mozilla.org/mozilla-central/rev/f1d0db4ba745
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla44
You need to log in before you can comment on or make changes to this bug.