Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Voting for the Unity Awards are OPEN! We’re looking to celebrate creators across games, industry, film, and many more categories. Cast your vote now for all categories
    Dismiss Notice
  3. Dismiss Notice

How to know WebGL version used in the player?

Discussion in 'WebGL' started by jsr2k1, Oct 23, 2018.

  1. jsr2k1

    jsr2k1

    Joined:
    Aug 11, 2010
    Posts:
    115
    Hello,

    I am developing a WebGL app and I need to know if the WebGL version used in the player is 1.0 or 2.0 in order to enable|disable the Reflection Probes.

    Is there any way to know this information?

    Thanks in advance,

    Joel
     
  2. Marco-Trivellato

    Marco-Trivellato

    Unity Technologies

    Joined:
    Jul 9, 2013
    Posts:
    1,654
    try SystemInfo.graphicsDeviceType, it will return either "OpenGLES3" (WebGL2.0) or "OpenGLES2" (WebGL1.0).
     
    Johannski likes this.
  3. jsr2k1

    jsr2k1

    Joined:
    Aug 11, 2010
    Posts:
    115
    Thank you!