should Construct start phasing out webGL 1?

0 favourites
  • 10 posts
From the Asset Store
Casino? money? who knows? but the target is the same!
  • With WebGPU coming soon and some discussions about limitations by webGL 1 compatability (for example https://www.construct.net/en/blogs/skymen-13/flexbox-weird-characters-1590) I started thinking that maybe the time is ripe for construct to start phasing out webGl 1 and start to implement features unique to webGL 2.

    Some data:

    • webGL 1 96.27% adoption
    • webGL 2 89.58% adoption
    • difference 6.69%

    (source: caniuse.com)

    So my question is how much do we gain by allowing webGL 2 features and how much do we lose by phasing out support for webGL 1.

    I personally don't have an answer to that questions, as I don't have enough insight into the limitations opposed by webGL 1 support and how constructs renderer works.

    Secondly with webGPU renderer coming for Construct as well at some point, how much would that implementation be held back by also needing to support webGL 1?

  • In terms of the core features, WebGL 1 works virtually identically to WebGL 2, basically doesn't need any maintenance, and dropping it would mean the 5-10% of people who still only get WebGL 1 will get either a blank screen, or drop to software rendering which will ruin performance. So dropping WebGL 1 would be a tiny amount of upside to a huge amount of downside. I think it's the kind of thing you can only consider when usage drops to <1%. That will probably still take years.

  • alright, thank you for the reply!

  • The one caveat I have with this is there are some webgl2, glsl version 300 features that would be use useful (specifically derivatives, fwidth).

    They would be useful for a pixel crisp effect and depth map to a normal map effect.

    Of course, the issue is that other shaders would need to be changed to support version 300 (internal shaders, etc.)

    A project check box for glsl version 300 support would be welcome.

  • Even if we supported that, you still have the question of what happens for the 5-10% of people who don't get WebGL 2. What should be rendered instead? Or should it fail?

    I think some of that can be done in WebGL 1 anyway. Perhaps we could enable the OES_standard_derivatives extension, which should let you do it in WebGL 1 code with better compatibility - I reckon most WebGL 1 devices probably support that extension too, although actual support numbers are hard to come by, especially since webglstats shut down.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • At least for our game, we would be ok with putting out an alert that webgl2 is required.

    It would be welcome at least as an experiment (e.g. C3 beta) to try out using OES_standard_derivatives extension.

    That being said, how would we set C3 projects to get only a webgl1 context and not a webgl2 context?

  • A lot of browsers have an option to disable webgl2 so you can utilize that for easy testing on your system.

    To make the export use just webgl1 you can edit the runtime after exporting. Just look for .getContext(“webgl2”) and remove the 2.

  • R0J0hound - thanks for the comments, I'm hoping for something built into the C3 Editor to make this simple for the general C3 community.

  • My apologies then, I’m not really being helpful with the request.

    I just work around stuff.

  • R0J0hound no worries, I appreciate the comments anyway. I hope that Ashley looks at implementing something to support the derivative functions somehow.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)