Search Unity

Am I to understand that webgl can not default to fullscreen?

Discussion in 'Web' started by gsus725, Jul 29, 2017.

  1. gsus725

    gsus725

    Joined:
    Aug 23, 2010
    Posts:
    250
    If you go to http://diep.io you'll see their game by default takes up the entire window, if you press F11 it becomes essentially fullscreen. Can unity not do this same thing in webgl? From what I've read you can't be fullscreen except by user input. I don't want the game to be all tiny by default.

    Subquestion: Is it true that on a webgl build it'll say "unity" at the bottom left on the free version and you can't get rid of it?
     
  2. TheRoccoB

    TheRoccoB

    Joined:
    Jun 29, 2017
    Posts:
    54
    Hi there. You actually have pretty good control over how the WebGL content renders. You achieve this by updating the webgl templates as described here: https://docs.unity3d.com/Manual/webgl-templates.html

    I'm working on a nice exporter / template that will be responsive to the size of the enclosing element. You can see a demo of this at preview.simmerindustries.com.

    I'm planning to open source the exporter / responsive WebGL template and also make it part of the unity asset store. Probably in the next month or two.