Goals
- Make 3d environment for Personal Project
- Special lecture; UGUI
Unity Graphic User Interface(UGUI)
Canvas
- Render Mode - Screen Space - Overlay
- Target Display (Moniter)
- Render Mode - Screen Space - Camera
- Render Camera
should not set the main camera
- Sorting Layer
- Order in Layer
- Render Mode - WorldSpace
Canvas Scaler
- UI ScaleMode
- Constant Pixel Size(not preferred): the size of UI objects were modified with the devices.
- Scale with Screen Size: set the default resolution, which will allow automatic expandation of ui size of view. Caution At the planning step of team project, the canvas scale should be tuned in team member.
- To match the UI size via match mode, there are 3 options; match width or height, expand, shrink.
- Pivot : The center of UI object, rotation and position value is calculated from pivot position.
- Anchor : The reference position of UI obj. it will effect the expandation when the canvas size is modified.
Content Size Fitter
When the developer adopt group layout, the blank space will be felt uncomportable. The Content Size Fitter makes width(horizontal) and height(vertical) automatically.
Most of chatting system will be applied with scrollable history. To implement that in Unity, the Scroll View
were invoked.
Raw Image
With this feature, the minimap or the scene recorded by camera could be used in UI.
To toggle out the page via gameObject.SetActive method, the button is not proper choice. Because the buttons use fixed value of Setactive value, the toggle is adopted in these cases. In the On value changed, we can see the GameObject.SetActive requires no input. Shown in the toggle, its name, the action consist automatically switching the state.