Jump to content

How can I avoid automatic glsl conversion with webgl 2.0?


BMWPilote
 Share

Recommended Posts

I ask this weird question because on IPad, if we check the experimental  webgl 2.0 option, we will get errors like "#version es 300,  unsupported shader version". It really sucks but if we can just use the legacy glsl version, maybe it can just work. 

The problem is that if Babylon detects that the browser supports WebGL2.0, then it automatically convert the glsl syntaxes (except if we set the options disableWebGL2Support when creating Engine), .

How can I force using Legacy Shader Syntaxes even with WebGL 2.0 on?

Link to comment
Share on other sites

We can not currently use the webgl 1 syntax in a webgl 2 engine.

This is mostly due to unavailable syntax required for webgl 2 features like shadowsampler 3dtexture and so on.

The webgl spec also enforces the suppoet of es300 in webgl2 so i would advise to force the version to webgl1 on those platform through the engineOption disableWebgl2Support.

 

Link to comment
Share on other sites

16 hours ago, Sebavan said:

We can not currently use the webgl 1 syntax in a webgl 2 engine.

This is mostly due to unavailable syntax required for webgl 2 features like shadowsampler 3dtexture and so on.

The webgl spec also enforces the suppoet of es300 in webgl2 so i would advise to force the version to webgl1 on those platform through the engineOption disableWebgl2Support.

 

OK this seems to be the best option. Merci, Sebastian.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...