Closed Bug 1420122 Opened 7 years ago Closed 3 years ago

WebGL warning: drawElements: Active texture 0 for target 0x0de1 is 'incomplete', and will be rendered as RGBA(0,0,0,1), as per the GLES 2.0.24 $3.8.2: The dimensions of `level_base` are not all positive.

Categories

(Core :: Graphics: CanvasWebGL, defect, P3)

57 Branch
defect

Tracking

()

RESOLVED FIXED

People

(Reporter: kanemason, Unassigned, NeedInfo)

Details

(Whiteboard: [gfx-noted])

Attachments

(2 files)

Attached image BlackAnim.PNG
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/62.0.3202.94 Safari/537.36

Steps to reproduce:

Was playing a game, see attachment.


Actual results:

Game makes use of PNG animations, on occasion the animations play out as completely black and the following can be seen in the console:

WebGL warning: drawElements: Active texture 0 for target 0x0de1 is 'incomplete', and will be rendered as RGBA(0,0,0,1), as per the GLES 2.0.24 $3.8.2: The dimensions of `level_base` are not all positive.

Had a similar issue in FireFox 56.0 which seemed to have resolved itself, but looks like its reappeared. 

Doesn't happen at all in other browsers.


Expected results:

Animations should play out as normal.
I have some further information to add. It appears the issue is actually because the png is getting corrupted when downloading or pulling it from cache. If I open the network tab and save those particular png sequences they are clearly cut off. Also all the corrupted files are EXACTLY the same size at 1.25mb, their actual size is larger, which indicates something is truncating them. The following error is visible in the console

"Image corrupt or truncated."
More updates! So it seems the failure is happening on URL.createObjectUrl(imageData). Hope that narrows it down
Component: Untriaged → Canvas: WebGL
Product: Firefox → Core
Yikes, does this look like an ImageLib issue, Andrew?
Flags: needinfo?(aosmond)
Whiteboard: [gfx-noted]
I wonder if bug 1420223 and/or bug 1421176 are related. It seems like decoding images from blobs is buggy. The latter hasn't landed / made its way into a nightly to test yet though.
Could you please provide your about:support, retry on the latest nightly and provide the full output log from Firefox? (And the console log as well, assuming you reproduce using the practice play -- it does seem to record actual play stats/info.) I have not been able to reproduce using the following steps:

1) Go to https://vegas.betway.com/lobby/en/#/home
2) Hover over the "Phantom of the Opera" game.
3) Click on the "Practice Play" button.
4) Wait for game to load and then keep clicking on "Spin". Observed multiple different types of wins causing animations, but nothing bad seemed to happen.

It is entirely possible that bug 1420223 and/or bug 1421176 solved the issue if the game makes use of blobs for the images. They are both now in the latest nightly builds. Please ensure your "Build ID" is >= 20171201100115 in about:support prior to testing.

I'm somewhat skeptical that this is an image issue, given the screenshot suggests it is a more general drawing problem -- the black boxes span what I believe to be multiple image resources, rather than simply one of the slot reel entries misrendering. But it is possible a decode failure somehow cascades other errors. And I did not encounter the decode errors on their own either.

Hopefully creating an account and gambling real money is not necessary to reproduce :).
Flags: needinfo?(aosmond) → needinfo?(kanemason)
Here are two projects on GitHub that appear to be affected by this bug:

https://github.com/mpetroff/pannellum/issues/505
https://github.com/googlevr/vrview/issues/287

Both projects report that intermittently the WebGL warning is not logged, but the images are rendered with wildly incorrect colors.
I'm facing the same problem (https://github.com/aframevr/aframe/) with a-frame on Firefox 60.0.1 (64-bit). The warning I get is:
WebGL warning: drawArrays: Active texture 0 for target 0x0de1 is 'incomplete', and will be rendered as RGBA(0,0,0,1), as per the GLES 2.0.24 $3.8.2: The dimensions of `level_base` are not all positive.

This is generally due to calling texImage(image), where image hasn't finished loading yet.
These days, there's a console warning when this happens: WebGL warning: tex(Sub)Image[23]D: Resource has no data (yet?). Uploading zeros.

Status: UNCONFIRMED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: