BabylonJS is running WebGL 1.0 instead of 2.0

Hello guys,

I’ve noticed that few of our users’ devices BabylonJS is using WebGL1.0 instead of WebGL2.0 even though the browser suppose to support it. (latest Chrome)
Is it something that should be supported by the device as well? if so, those devices are considered low end (even though they are relatively new)

User agents that run WebGL 1.0:

Mozilla/5.0 (Linux; Android 8.1.0; LML212VL Build/OPM1.171019.019; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/74.0.3729.136 Mobile Safari/537.36 Instagram 91.0.0.18.118 Android (27/8.1.0; 320dpi; 720x1196; LGE/lge; LML212VL; cv1; cv1; en_US; 152367494)
Mozilla/5.0 (Linux; Android 8.1.0; LM-X210(G)) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.90 Mobile Safari/537.36
Babylon.js v4.0.0 - WebGL1
Mozilla/5.0 (Linux; Android 8.1.0; LM-X210(G) Build/OPM1.171019.026; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/73.0.3683.90 Mobile Safari/537.36 Instagram 91.0.0.18.118 Android (27/8.1.0; 320dpi; 720x1196; LGE/lge; LM-X210(G); cv1; cv1; en_US; 152367494)
Mozilla/5.0 (Linux; Android 8.1.0; LML212VL Build/OPM1.171019.019; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/73.0.3683.90 Mobile Safari/537.36 Instagram 91.0.0.18.118 Android (27/8.1.0; 320dpi; 720x1196; LGE/lge; LML212VL; cv1; cv1; en_US; 152367494)
Mozilla/5.0 (Linux; Android 7.1.1; Moto E (4) Build/NDQS26.69-64-11-5; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/74.0.3729.112 Mobile Safari/537.36 Instagram 91.0.0.18.118 Android (25/7.1.1; 320dpi; 720x1184; motorola; Moto E (4); perry_f; qcom; en_US; 152367494)
Mozilla/5.0 (Linux; Android 8.0.0; moto g(6) play Build/OCPS27.91-150-4; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/73.0.3683.90 Mobile Safari/537.36 Instagram 90.0.0.18.110 Android (26/8.0.0; 320dpi; 720x1344; motorola; moto g(6) play; jeter; qcom; en_US; 151414275)
Mozilla/5.0 (Linux; Android 8.0.0; moto e5 cruise Build/OCPS27.91-157-2; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/73.0.3683.90 Mobile Safari/537.36 Instagram 90.0.0.18.110 Android (26/8.0.0; 320dpi; 720x1184; motorola; moto e5 cruise; james; qcom; en_US; 151414275)

As you might notice all of the above are LG \ Motorola devices, haven’t seen this problem occur on different devices.

Any ideas?

The issue is that not all systems running WebGL 1.0 are capable of running WebGL 2.0 yet, and many will not be capable.

The fact is that he WebGL 2.0 specification has recently been released, and implementations of the new API are still becoming available. There are also that many bugs still exist with most browsers, and are only reported by users to hopefully be fixed in the standard for the future.

So it is unknown when WebGL 2.0 will be fully adopted by the babylon.js framework. The babylon.js team is keeping a close watch on the development of WebGL 2.0, and will make use of the WebGL features when they are compatible, stable, and tested across multiple browsers.

Galen

Can you make sure that that browsers really support webgl2? They can run chrome and still do not support it as it fully depend on the gfx driver

I see, do you know any easy way of checking it? cause those users aren’t tech oriented and I don’t have any access to their devices.

@kutomer
https://webglreport.com/?v=2
is one way

Cool, Thanks.

BTW, that might be a long shot, but the reason I’m asking it is - those users experience a weird issue with our app, the scene is working but without lighting, so everything is completely black.
They can interact with the scene but can’t see the interactions, this only happens to users with the userAgens provided in my first message. (so device provider is always Motorola or LG and always using WebGL 1.0)

Any ideas?

@kutomer
hard to tell, could be driver issue, (there are a lot for Samsung S8/9 on android 7 for WebGL 2.0, all pbr there is black, forced WebGL 1.0 to fix).
But its hard to tell without extra data, need to check device directly.

1 Like

This may be due to a wrong driver

Can you try to initiate your engine like that:

var engine = new BABYLON.Engine(canvas, true, {disableWebGL2Support: true, useHighPrecisionFloats: false});

if this does not work, you can also try:

engine.disableVertexArrayObjects = true;
engine.disableUniformBuffers= true;
1 Like