FULLSCREEN mode for mobile platform.

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By tncft4

Hi.
We are doing set the window height and window width in PC. Or fullscreen. how do we this for android.
Thanks…

:bust_in_silhouette: Reply From: Wakatta

Hmm think the screen is always filled on mobile, the most you can do is fiddle with aspect ratios

var size = Vector2(OS.window_size.x * 1080 / OS.window_size.y, 768)
var mode = SceneTree.STRETCH_MODE_2D
var aspect = SceneTree.STRETCH_ASPECT_EXPAND
get_tree().set_screen_stretch(mode, aspect, size)