SetPerformanceLevel(ref int, ref int)
Request a performance level change. If Constants.UnknownPerformanceLevel is passed, the subsystem picks the level to be used.
Read time 1 minuteLast updated 8 days ago
Definition
- Type: Method
- Namespace: UnityEngine.AdaptivePerformance.Provider
- Assembly: UnityEngine.AdaptivePerformanceModule
SetPerformanceLevel(int, int)
bool SetPerformanceLevel(ref int cpu, ref int gpu)
Parameters
The new performance level. Can be Constants.UnknownPerformanceLevel or range of [Constants.MinCpuPerformanceLevel, IDevicePerformanceLevelControl.MaxCpuPerformanceLevel]. If Feature.CpuPerformanceLevel is not supported (see AdaptivePerformanceSubsystem.Capabilities), this parameter is ignored.
The new performance level. Can be Constants.UnknownPerformanceLevel or range of [Constants.MinCpuPerformanceLevel, IDevicePerformanceLevelControl.MaxGpuPerformanceLevel]. If Feature.GpuPerformanceLevel is not supported (see AdaptivePerformanceSubsystem.Capabilities), this parameter is ignored.
Returns
Type | Description |
|---|---|
| bool | Returns true on success. When this fails, it means that the system took control of the active performance levels. |