Description
Supported Script Types: Interface Scripts • Client Entity Scripts • Avatar Scripts
ThePerformance
API provides control and
information on graphics performance settings.
Properties
| Name | Type | Summary |
|---|---|---|
| performancePreset | Performance.PerformancePreset |
The current graphics performance preset. |
| refreshRateProfile | Performance.RefreshRateProfile |
The current refresh rate profile. |
Methods
| Name | Return Value | Summary |
|---|---|---|
getActiveRefreshRate
|
number |
Gets the current target refresh rate, in Hz, per the current refresh rate profile and refresh rate regime if in desktop mode; a higher rate if in VR mode. |
getPerformancePreset
|
Performance.PerformancePreset |
Gets the current graphics performance preset in use. |
getPerformancePresetNames
|
Array.<string> |
Gets the names of the graphics performance presets. |
getRefreshRateProfile
|
Performance.RefreshRateProfile |
Gets the current refresh rate profile in use. |
getRefreshRateProfileNames
|
Array.<string> |
Gets the names of the refresh rate profiles. |
getRefreshRateRegime
|
RefreshRateRegime |
Gets the current refresh rate regime that's in effect. |
getUXMode
|
UXMode |
Gets the current user experience mode. |
setPerformancePreset
|
None |
Sets graphics performance to a preset. |
setRefreshRateProfile
|
None |
Sets the curfrent refresh rate profile. |
Signals
| Name | Summary |
|---|---|
settingsChanged
|
Triggered when the performance preset or refresh rate profile is changed. |
Type Definitions
|
PerformancePreset Type: number |
|||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
Graphics performance presets.
|
|
RefreshRateProfile Type: number |
||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
Refresh rate profile.
|
Method Details
|
(static)
getActiveRefreshRate(
) →
{number}
Returns: The current target refresh rate, in Hz. |
|---|
|
Gets the current target refresh rate, in Hz, per the current refresh rate profile and refresh rate regime if in desktop mode; a higher rate if in VR mode. |
|
(static)
getPerformancePreset(
) → {Performance.PerformancePreset}
Returns: The current graphics performance preset in use. |
|---|
|
Gets the current graphics performance preset in use. |
|
(static)
getPerformancePresetNames(
) →
{Array.<string>}
Returns: The names of the graphics performance presets. The array index values correspond to Performance.PerformancePreset values. |
|---|
|
Gets the names of the graphics performance presets. |
|
(static)
getRefreshRateProfile(
) → {Performance.RefreshRateProfile}
Returns: The refresh rate profile. |
|---|
|
Gets the current refresh rate profile in use. |
|
(static)
getRefreshRateProfileNames(
) →
{Array.<string>}
Returns: The names of the refresh rate profiles. The array index values correspond to Performance.RefreshRateProfile values. |
|---|
|
Gets the names of the refresh rate profiles. |
|
(static)
getRefreshRateRegime(
) → {RefreshRateRegime}
Returns: The current refresh rate regime. |
|---|
|
Gets the current refresh rate regime that's in effect. |
|
(static)
getUXMode(
)
→ {UXMode}
Returns: The current user experience mode. |
|---|
|
Gets the current user experience mode. |
| (static) setPerformancePreset( performancePreset ) | ||||||
|---|---|---|---|---|---|---|
|
Sets graphics performance to a preset. Parameters
|
| (static) setRefreshRateProfile( refreshRateProfile ) | ||||||
|---|---|---|---|---|---|---|
|
Sets the curfrent refresh rate profile. Parameters
|
Signal Details
|
settingsChanged(
)
Returns: Signal |
|---|
|
Triggered when the performance preset or refresh rate profile is changed. |
