

A typical frame budget will be approximately 22 ms per frame at 30 fps and 11 ms per frame at 60 fps. We recommend that you use only about 65% of the available time to allow for cooldown between frames. Account for device temperatureįor mobile, however, we don’t recommend using this maximum time consistently as the device can overheat and the OS can thermal throttle the CPU and GPU. Likewise, a target of 60 fps leaves 16.66 ms per frame.ĭevices can exceed this budget for short periods of time (e.g., for cutscenes or loading sequences), but not for a prolonged duration. Ideally, an application running at 30 fps will allow for approximately 33.33 ms per frame (1000 ms / 30 fps). You can monitor supplementary Profiler Modules like Renderer, Audio, and Physics, as needed for your game (e.g., physics-heavy or music-based gameplay).Įach frame will have a time budget based on your target frames per second (fps). Enable the CPU and Memory tracks by default. The Unity Profiler can help you detect the causes of any lags or freezes at runtime and better understand what’s happening at a specific frame, or point in time. Identify genuine bottlenecks and concentrate your efforts on what benefits your work. Something that works well in one project may not translate to yours. Of course, not every optimization described here will apply to your application.

Use the Unity Profiler and platform-specific tools to locate the precise source of a lag.

Focus on optimizing the right areasĭon’t guess or make assumptions about what is slowing down your game’s performance. See Profiling Applications Made with Unity for more information. Ĭertain hardware can take advantage of additional profiling tools (e.g., Arm Mobile Studio, Intel VTune, and Snapdragon Profiler).
#How to optimize pc for gaming 2021 android
