使用 Resolution and Presentation 部分可以自定义屏幕外观的各个方面。
这些设置分为以下几个类别:
使用 Resolution Scaling Mode 设置可以将缩放设置为等于或低于屏幕原始分辨率:
值 | 功能 |
---|---|
Disabled | 缩放不会应用,并且应用程序将渲染屏幕原始分辨率。 |
FixedDPI | 选择此值时,将显示 Target DPI 属性。 使用 Target DPI 属性可设置游戏屏幕的目标 DPI。如果设备的屏幕原始 DPI 高于此值,则 Unity 会降低游戏画面分辨率以匹配此设置。这有助于优化性能和电池续航时间。还可以用于定位特定的 DPI 设置。 Unity 计算缩放比例的方式为 min(Target DPI * Factor / Screen DPI, 1) 。Factor 使用 Quality 设置中输入的 Resolution Scaling Fixed DPI Factor 值。 |
从 Default Orientation 下拉菜单中选择游戏的屏幕方向。默认设置是 Auto Rotation。如果选择此设置,则屏幕将按照设备方向旋转。
选择其他设置可以确定主屏幕按钮在屏幕上出现的固定位置:
设置 | 主屏幕按钮位置 |
---|---|
Portrait | 底部 |
Portrait Upside Down | 顶部 |
Landscape Left | 右侧 |
Landscape Right | 左侧 |
Auto Rotation | 屏幕方向随设备方向而变化。此为默认值。 |
注意:Default Orientation 设置对 iOS 和 Android 设备均适用。
在 Default Orientation 中选择 Auto Rotation 时,将出现以下设置:
设置 | 功能 |
---|---|
Use Animated Autorotation | 如果启用此复选框,则当用户旋转设备时,屏幕旋转将使用动画过渡。否则,屏幕旋转会立即改变。 |
Allowed Orientations for Auto Rotation | Auto Rotation 会更改屏幕方向以匹配设备方向。您可能希望限制允许的屏幕方向(例如,将设备锁定为横向)。通过选中本部分中的复选框,启用要允许的每个方向。 |
如果应用程序需要在全屏模式下运行,请启用 Requires Fullscreen 选项。
使用 Status Bar 部分来指定与 iOS 状态栏相关的参数。
设置 | 功能 |
---|---|
Status Bar Hidden | 启用此选项可在应用程序启动时隐藏状态栏。 |
Status Bar Style | 定义应用程序启动时状态栏的样式。提供的选项为 Default 和 Light。 |
Disable Depth and Stencil | 启用此选项可禁用深度和模板缓冲区。此设置对 Android 和 iOS 均适用。 |
Render Over Native UI | 启用此选项可强制应用程序在原生 iOS 或 Android UI 之上渲染。此设置对 Android 和 iOS 均适用。 |
Show Loading Indicator | 选择如何显示加载指示符。选项为 Large、Inverse Large、Small 和 Inverse Small。 |
Did you find this page useful? Please give it a rating:
Thanks for rating this page!
What kind of problem would you like to report?
Thanks for letting us know! This page has been marked for review based on your feedback.
If you have time, you can provide more information to help us fix the problem faster.
Provide more information
You've told us this page needs code samples. If you'd like to help us further, you could provide a code sample, or tell us about what kind of code sample you'd like to see:
You've told us there are code samples on this page which don't work. If you know how to fix it, or have something better we could use instead, please let us know:
You've told us there is information missing from this page. Please tell us more about what's missing:
You've told us there is incorrect information on this page. If you know what we should change to make it correct, please tell us:
You've told us this page has unclear or confusing information. Please tell us more about what you found unclear or confusing, or let us know how we could make it clearer:
You've told us there is a spelling or grammar error on this page. Please tell us what's wrong:
You've told us this page has a problem. Please tell us more about what's wrong:
Thank you for helping to make the Unity documentation better!
Your feedback has been submitted as a ticket for our documentation team to review.
We are not able to reply to every ticket submitted.