- Mastering UI Development with Unity
- Ashley Godbold
- 197字
- 2021-08-27 18:43:12
Constant Physical Size
When a Canvas has the UI Scale Mode set to Constant Physical Size, every item in the UI will maintain its original physical size, regardless of the size of the screen. Physical size is referencing the size it would appear to the user if they were to take out a ruler and measure it on their screen. Much like Constant Pixel Size, items on Canvases with this UI Scale Mode will not scale. If you had a UI item that you wanted to always be a specific width and height, you'd put it on a Canvas that has this UI Scale Mode. For example, if you wanted a button to always be 2 inches wide and 1 inch tall, you'd use this mode.

When you change the UI Scale Mode to Constant Physical Size, you will see the following properties appear within the inspector:
- Physical Unit: The unit of measure. You can select from Centimeters, Millimeters, Inches, Points, and Picas
- Fallback Screen DPI: If the DPI is unknown, this is the assumed DPI
- Default Sprite DPI: The DPI of all sprites with Pixels Per Unit that are equal to the Reference Pixels Per Unit
推薦閱讀
- Java程序設計(慕課版)
- Developing Mobile Web ArcGIS Applications
- Python零基礎快樂學習之旅(K12實戰訓練)
- Python應用輕松入門
- 量化金融R語言高級教程
- 計算機應用基礎案例教程
- Mastering Python Design Patterns
- App Inventor少兒趣味編程動手做
- 算法秘籍
- Android高級開發實戰:UI、NDK與安全
- 深入淺出 HTTPS:從原理到實戰
- Perl 6 Deep Dive
- Learning C# by Developing Games with Unity 3D Beginner's Guide
- Python編程基礎
- C#編程魔法書