CodePudding user response:
Adaptive didn't work, you have a good look at itCodePudding user response:
You this is adaptive maintain unchanged, with scaling widthCodePudding user response:
Pulling anchor every UI elements to fit the size of the UICodePudding user response:
Should be adapted is highCodePudding user response:
Weight configuration, try to 0.5CodePudding user response:
Using System. The Collections;using System.Collections.Generic;
Using UnityEngine;
Public class FullScreen: MonoBehaviour {
Private void Awake ()
{
//access to set the current screen resolution
Resolution [] resolutions=Screen. Resolutions;
//set the current resolution
Screen. SetResolution (resolutions [resolutions. The Length - 1]. Width, resolutions [resolutions. The Length - 1]. Height, true);
Screen. The fullScreen=true;//set to full screen
}
}
This script put objects
CodePudding user response:
Recently met, don't know and you are consistent, I'm doing a Windows Screen program, desktop set 3840 * 1920 resolution, but the procedure to obtain Screen. The resolutions, Screen. CurrentResolution chose a 1080 * 1920, because the factory make machines have a display controller set wrong, because do not understand the hardware principle, thus set up with the following code:Int screenWidth=GetSystemMetrics (SM_CXSCREEN);
Int screenHeight=GetSystemMetrics (SM_CYSCREEN);
Screen. SetResolution (screenWidth screenHeight, true);
CodePudding user response:
You are packaged sets the size of the screen, but also is the different display hardware will not be the same: android, ios mobile phones, ios tablet, and to be able to touch screen computer,