Struct FrameSettings
Per renderer and per frame settings.
Inherited Members
Namespace: UnityEngine.Rendering.HighDefinition
Assembly: Unity.RenderPipelines.HighDefinition.Runtime.dll
Syntax
[Serializable]
public struct FrameSettings
Fields
lodBias
If lodBiasMode
is LODBiasMode.Fixed
, then this value overwrites QualitySettings.lodBias
.
If lodBiasMode
is LODBiasMode.ScaleQualitySettings
, then this value scales QualitySettings.lodBias
.
Declaration
public float lodBias
Field Value
Type | Description |
---|---|
float |
lodBiasMode
Specifies how HDRP calculates QualitySettings.lodBias
.
Declaration
public LODBiasMode lodBiasMode
Field Value
Type | Description |
---|---|
LODBiasMode |
lodBiasQualityLevel
The quality level the rendering component uses when it fetches the quality setting value.
Declaration
public int lodBiasQualityLevel
Field Value
Type | Description |
---|---|
int |
materialQuality
The material quality level this rendering component uses.
If materialQuality == 0
, the rendering component uses the material quality from the current quality settings in the HDRP Asset.
Declaration
public MaterialQuality materialQuality
Field Value
Type | Description |
---|---|
MaterialQuality |
maximumLODLevel
If maximumLODLevelMode
is MaximumLODLevelMode.FromQualitySettings
, then this value overwrites QualitySettings.maximumLODLevel
If maximumLODLevelMode
is MaximumLODLevelMode.OffsetQualitySettings
, then this value offsets QualitySettings.maximumLODLevel
Declaration
public int maximumLODLevel
Field Value
Type | Description |
---|---|
int |
maximumLODLevelMode
Specifies how HDRP calculates QualitySettings.maximumLODLevel
.
Declaration
public MaximumLODLevelMode maximumLODLevelMode
Field Value
Type | Description |
---|---|
MaximumLODLevelMode |
maximumLODLevelQualityLevel
The maximum quality level the rendering component uses when it fetches the quality setting value.
Declaration
public int maximumLODLevelQualityLevel
Field Value
Type | Description |
---|---|
int |
msaaMode
Stores MSAA Mode on disk.
Declaration
public MSAAMode msaaMode
Field Value
Type | Description |
---|---|
MSAAMode |
sssCustomDownsampleSteps
Stores SssCustomDownsampleSteps on disk.
Declaration
public int sssCustomDownsampleSteps
Field Value
Type | Description |
---|---|
int |
sssCustomSampleBudget
Stores SssCustomSampleBudget on disk.
Declaration
public int sssCustomSampleBudget
Field Value
Type | Description |
---|---|
int |
sssQualityLevel
Stores SssQualityLevel on disk.
Declaration
public int sssQualityLevel
Field Value
Type | Description |
---|---|
int |
sssQualityMode
Stores SssQualityMode on disk.
Declaration
public SssQualityMode sssQualityMode
Field Value
Type | Description |
---|---|
SssQualityMode |
Properties
litShaderMode
Specifies the rendering path this rendering component uses. Here you can use the LitShaderMode
enum to specify whether the rendering component uses forward or deferred rendering.
Declaration
public LitShaderMode litShaderMode { get; set; }
Property Value
Type | Description |
---|---|
LitShaderMode |
Methods
Create()
Construct and initialize a FrameSettings
Declaration
public static FrameSettings Create()
Returns
Type | Description |
---|---|
FrameSettings | A new FrameSettings initialized |
Equals(object)
Equality operator between two FrameSettings. Return true
if equivalent. (comparison of content).
Declaration
public override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
object | obj | Frame Settings to compare to. |
Returns
Type | Description |
---|---|
bool | True if both settings are equal. |
Overrides
GetHashCode()
Returns the hash code of this object.
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
int | Hash code of the frame settings. |
Overrides
GetResolvedLODBias(HDRenderPipelineAsset)
Calculates the LOD bias value to use.
Declaration
public float GetResolvedLODBias(HDRenderPipelineAsset hdrp)
Parameters
Type | Name | Description |
---|---|---|
HDRenderPipelineAsset | hdrp | The HDRP Assets to use |
Returns
Type | Description |
---|---|
float | The LOD Bias to use |
GetResolvedMSAAMode(HDRenderPipelineAsset)
Calculates the Maximum LOD level to use.
Declaration
public MSAASamples GetResolvedMSAAMode(HDRenderPipelineAsset hdrp)
Parameters
Type | Name | Description |
---|---|---|
HDRenderPipelineAsset | hdrp | The HDRP Asset to use |
Returns
Type | Description |
---|---|
MSAASamples | The Maximum LOD level to use. |
GetResolvedMaximumLODLevel(HDRenderPipelineAsset)
Calculates the Maximum LOD level to use.
Declaration
public int GetResolvedMaximumLODLevel(HDRenderPipelineAsset hdrp)
Parameters
Type | Name | Description |
---|---|---|
HDRenderPipelineAsset | hdrp | The HDRP Asset to use |
Returns
Type | Description |
---|---|
int | The Maximum LOD level to use. |
GetResolvedSssDownsampleSteps(HDRenderPipelineAsset)
Returns the number downsample steps that will be performed on the source irradiance texture before the main Subsurface algorithm executes.
Declaration
public int GetResolvedSssDownsampleSteps(HDRenderPipelineAsset hdrp)
Parameters
Type | Name | Description |
---|---|---|
HDRenderPipelineAsset | hdrp | The HDRP Asset to use. |
Returns
Type | Description |
---|---|
int | The number downsample steps. |
GetResolvedSssSampleBudget(HDRenderPipelineAsset)
Returns the sample budget of the Subsurface Scattering algorithm.
Declaration
public int GetResolvedSssSampleBudget(HDRenderPipelineAsset hdrp)
Parameters
Type | Name | Description |
---|---|---|
HDRenderPipelineAsset | hdrp | The HDRP Asset to use. |
Returns
Type | Description |
---|---|
int | The sample budget of the Subsurface Scattering algorithm. |
IsEnabled(FrameSettingsField)
Gets the stored override value for the passed in Frame Setting. Use this to access boolean values.
Declaration
public bool IsEnabled(FrameSettingsField field)
Parameters
Type | Name | Description |
---|---|---|
FrameSettingsField | field | Requested field. |
Returns
Type | Description |
---|---|
bool | True if the field is enabled. |
SetEnabled(FrameSettingsField, bool)
Sets the stored override value for the passed in Frame Setting. Use this to access boolean values.
Declaration
public void SetEnabled(FrameSettingsField field, bool value)
Parameters
Type | Name | Description |
---|---|---|
FrameSettingsField | field | Requested field. |
bool | value | State to set to the field. |
Operators
operator ==(FrameSettings, FrameSettings)
Equality operator between two FrameSettings. Return true
if equivalent. (comparison of content).
Declaration
public static bool operator ==(FrameSettings a, FrameSettings b)
Parameters
Type | Name | Description |
---|---|---|
FrameSettings | a | First frame settings. |
FrameSettings | b | Second frame settings. |
Returns
Type | Description |
---|---|
bool | True if both settings are equal. |
operator !=(FrameSettings, FrameSettings)
Inequality operator between two FrameSettings. Return true
if different. (comparison of content).
Declaration
public static bool operator !=(FrameSettings a, FrameSettings b)
Parameters
Type | Name | Description |
---|---|---|
FrameSettings | a | First frame settings. |
FrameSettings | b | Second frame settings. |
Returns
Type | Description |
---|---|
bool | True if settings are not equal. |