- Home /
WebGL FullScreen
Hi guys working on WebGL project, I have a transparent background (thanks ) on Unity and have a button that goes full screen. Yes I have a button on my canvas on unity and not using the button on the index because of the design documentation of my client. The button have this:
public void FullScreen()
{
Screen.fullScreen = !Screen.fullScreen;
}
on Firefox works perfect but on Chrome makes like a white rectangle on the right area. Like this ->
If you are asking my screen its all black. Maybe there another solution for go full screen that works ok on chrome? Let me know how can I approach this.
Thanks my friends! Bye :D
Answer by wahnishjorge25 · Apr 06, 2016 at 02:45 PM
https://bugzilla.mozilla.org/show_bug.cgi?id=1176157
Found this. Seems like bug on the browser and not from Unity.
Answer by JagaHe · May 26, 2017 at 05:11 AM
Try add 'position:absolute' to your canvas properties. It helped to me. Like this:
#canvas {
width: 100%;
height: 100%;
position: absolute;
}
Your answer
Follow this Question
Related Questions
WebGL build with SocketIO throws errors 1 Answer
Unity Webgl in Chrome out of memory error 0 Answers
WebGL, Facebook drag background image 0 Answers
Can't export to webGL 2 Answers
Chrome 56 WebGL error 1 Answer