Closed
Bug 1009734
Opened 11 years ago
Closed 11 years ago
Firefox is issuing incorrect errors for WebGL
Categories
(Core :: Graphics: CanvasWebGL, defect)
Tracking
()
RESOLVED
FIXED
mozilla40
| Tracking | Status | |
|---|---|---|
| firefox40 | --- | fixed |
People
(Reporter: mozilla2, Assigned: jgilbert)
Details
Attachments
(2 files)
|
672 bytes,
text/html
|
Details | |
|
3.12 KB,
patch
|
u480271
:
review+
|
Details | Diff | Splinter Review |
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:29.0) Gecko/20100101 Firefox/29.0 (Beta/Release)
Build ID: 20140506152807
Steps to reproduce:
1) Open the Web Console
2_ Run the attached file or go to
http://greggman.com/downloads/examples/bogus-webgl-errors.html
Actual results:
There are incorrect errors about WebGL in the console.
Expected results:
There should be no errors in the console
The specific issue is Firefox is checking if a texture is renderable at bindTexture time. This is incorrect behavior. A texture can not be checked for being valid until someone tries to render with it. It is perfectly legal WebGL to bind an invalid texture.
There are similar incorrect checks for binding framebuffers and renderbuffers (and buffers?)
| Assignee | ||
Updated•11 years ago
|
Component: Untriaged → Canvas: WebGL
Product: Firefox → Core
| Reporter | ||
Comment 1•11 years ago
|
||
Any chance this bug can be fixed? It's really annoying to get BS warnings in the console.
A typical use case is writing a function that auto sets filtering / mips for NPOT vs POT textures. To make it callable from anywhere it binds the texture because it can't assume it was already bound. So
gl.bindTexture(..., tex);
gl.texImage2D(..., img);
setFilteringAndMipsForTexture(tex, img.width, img.height)
function setFilteringAndMipsForTexture(tex, width, height) {
gl.bindTexture(..., tex); // generates incorrect warning in Firefox
| Assignee | ||
Comment 2•11 years ago
|
||
(In reply to Gregg Tavares from comment #1)
> Any chance this bug can be fixed? It's really annoying to get BS warnings in
> the console.
>
> A typical use case is writing a function that auto sets filtering / mips for
> NPOT vs POT textures. To make it callable from anywhere it binds the texture
> because it can't assume it was already bound. So
>
> gl.bindTexture(..., tex);
> gl.texImage2D(..., img);
> setFilteringAndMipsForTexture(tex, img.width, img.height)
>
> function setFilteringAndMipsForTexture(tex, width, height) {
> gl.bindTexture(..., tex); // generates incorrect warning in Firefox
Yeah, this should be fairly easy to fix.
Flags: needinfo?(jgilbert)
| Assignee | ||
Updated•11 years ago
|
Assignee: nobody → jgilbert
Flags: needinfo?(jgilbert)
OS: Mac OS X → All
Hardware: x86 → All
| Assignee | ||
Comment 3•11 years ago
|
||
Neuter yet another myopic optimization.
Attachment #8588855 -
Flags: review?(dglastonbury)
| Assignee | ||
Updated•11 years ago
|
Status: UNCONFIRMED → NEW
Ever confirmed: true
Comment on attachment 8588855 [details] [diff] [review]
0001-Wait-until-draw-time-to-check-texture-completeness.patch
Review of attachment 8588855 [details] [diff] [review]:
-----------------------------------------------------------------
So we just need to take away code?
Attachment #8588855 -
Flags: review?(dglastonbury) → review+
| Assignee | ||
Comment 5•11 years ago
|
||
| Assignee | ||
Comment 6•11 years ago
|
||
Comment 7•11 years ago
|
||
Status: NEW → RESOLVED
Closed: 11 years ago
status-firefox40:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla40
You need to log in
before you can comment on or make changes to this bug.
Description
•