0 votes

What happens when the project runs under different resolutions (lesser or larger) than the one specified in the project settings?

in Engine by (172 points)

1 Answer

+1 vote

Depends on how you set up the preferences and i.e. your scaling.
This section of the docs pretty much covers it:

For example "Stretch Mode" and "Stretch Aspect" are some settings covered there.

On desktop operating systems you'll be able to manually resize the window to check the results of your settings. On mobile devices, the window will (usually) be always scaled to the full screen size & resolution. (But the kind of scaling will be defined by i.e. the settings mentioned above.)

(2D) Coordinates will usually also be relative to your initially defined screen resolution. Although they'll vary with the screen aspect ratio (portrait, landscape, 16:9, 4:3). You can limit the screen rotation of mobile devices in the projects preferences (i.e. to portrait).

2D GUI & on screen controls can & usually should be built up "responsive" using Anchor and Margin values.

Some controls have additional Attributes for controlling how they behave when rescaled. I.e. TextureRect can be controlled quite good via ┬┤expand┬┤ and stretch_mode. So you can i.e. select the best method to scale an image for a menu background.

by (3,252 points)
Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to webmaster@godotengine.org with your username.