Tasharen Entertainment Forum
Support => NGUI 3 Support => Topic started by: Disastercake on March 28, 2014, 10:27:27 AM
-
I'm having difficulty finding anchor settings and GUI placements that work well across multiple screen ratios and resolutions. It feels like there is only a small window of resolutions that will work well for a given placement of the GUI.
Examples in small resolutions: GUI elements will either go off screen or begin to overlap each other
Examples in high resolutions: GUI elements become too small and too spaced apart.
I think the easiest solution would be to set up the GUI positions and sizes to just work like a big rasterized image; they could expand in size or decrease in size, but would always remain in their exact place relative to the screen view. The downside I can see to this is GUI elements beginning to get blurry if they are not high enough resolution, but that could be easily remedied by increasing the texture sizes. I could have swore I had done this in the past (over 1 year ago) with NGUI, but can't seem to find a solution to that now.
Is there a way to do this? Or are there better practices than this to get desirable GUI placements across multiple resolutions?
-
Fixed Size UIRoot.
-
Thanks, Arenmook! Does this also mean you think this is the best practice for setting up GUI on the PC for multiple resolutions? If not, do you have any suggestions?
-
There are a few approaches regarding difference in resolutions. Fixed Size UIRoot is by far the easiest. It will keep your UI looking exactly the same size proportionally to the height of the screen. Anchors are useful if you have a modular UI where certain things need to be in specific locations and you expect the aspect ratio to vary (as it realistically likely will). So placing a minimap in the top right corner would require anchoring it to top-right.
If crispness is desired, you will also need to have multiple atlases -- SD, HD, UHD, etc -- but that's getting advanced.