Struct STP.Config
Top-level configuration structure required for STP execution
Inherited Members
Namespace: UnityEngine.Rendering
Assembly: Unity.RenderPipelines.Core.Runtime.dll
Syntax
public struct STP.Config
Fields
currentImageSize
Size of the current viewport in pixels Used to calculate image coordinate scaling factors
Declaration
public Vector2Int currentImageSize
Field Value
Type | Description |
---|---|
Vector2Int |
debugView
[Optional] Output debug view texture which STP can be configured to render debug visualizations into
Declaration
public TextureHandle debugView
Field Value
Type | Description |
---|---|
TextureHandle |
debugViewIndex
An index value that indicates which debug visualization to render in the debug view This value is only used when a valid debug view handle is provided
Declaration
public int debugViewIndex
Field Value
Type | Description |
---|---|
int |
deltaTime
Delta frame time for the current frame Used to compensate for inconsistent frame timings when working with motion vectors
Declaration
public float deltaTime
Field Value
Type | Description |
---|---|
float |
destination
Output color texture which will receive the final upscaled color result
Declaration
public TextureHandle destination
Field Value
Type | Description |
---|---|
TextureHandle |
enableHwDrs
Set to true if hardware dynamic resolution scaling is currently active
Declaration
public bool enableHwDrs
Field Value
Type | Description |
---|---|
bool |
enableMotionScaling
Set to true to enable the motion scaling feature which attempts to compensate for variable frame timing when working with motion vectors
Declaration
public bool enableMotionScaling
Field Value
Type | Description |
---|---|
bool |
enableTexArray
Set to true if the rendering environment is using 2d array textures (usually due to XR)
Declaration
public bool enableTexArray
Field Value
Type | Description |
---|---|
bool |
farPlane
Distance to the camera's far plane Used to encode depth values
Declaration
public float farPlane
Field Value
Type | Description |
---|---|
float |
frameIndex
Index of the current frame Used to calculate jitter pattern
Declaration
public int frameIndex
Field Value
Type | Description |
---|---|
int |
hasValidHistory
True if the current frame has valid history information Used to prevent STP from producing invalid data
Declaration
public bool hasValidHistory
Field Value
Type | Description |
---|---|
bool |
historyContext
Input history context to use when executing STP
Declaration
public STP.HistoryContext historyContext
Field Value
Type | Description |
---|---|
STP.HistoryContext |
inputColor
Input color texture to be upscaled
Declaration
public TextureHandle inputColor
Field Value
Type | Description |
---|---|
TextureHandle |
inputDepth
Input depth texture which will be analyzed during upscaling
Declaration
public TextureHandle inputDepth
Field Value
Type | Description |
---|---|
TextureHandle |
inputMotion
Input motion vector texture which is used to reproject information across frames
Declaration
public TextureHandle inputMotion
Field Value
Type | Description |
---|---|
TextureHandle |
inputStencil
[Optional] Input stencil texture which is used to identify pixels that need special treatment such as particles or in-game screens
Declaration
public TextureHandle inputStencil
Field Value
Type | Description |
---|---|
TextureHandle |
lastDeltaTime
Delta frame time for the previous frame Used to compensate for inconsistent frame timings when working with motion vectors
Declaration
public float lastDeltaTime
Field Value
Type | Description |
---|---|
float |
nearPlane
Distance to the camera's near plane Used to encode depth values
Declaration
public float nearPlane
Field Value
Type | Description |
---|---|
float |
noiseTexture
Blue noise texture used in various parts of the upscaling logic
Declaration
public Texture2D noiseTexture
Field Value
Type | Description |
---|---|
Texture2D |
numActiveViews
Number of active views in the perViewConfigs array
Declaration
public int numActiveViews
Field Value
Type | Description |
---|---|
int |
outputImageSize
Size of the upscaled output image in pixels Used to calculate image coordinate scaling factors
Declaration
public Vector2Int outputImageSize
Field Value
Type | Description |
---|---|
Vector2Int |
perViewConfigs
Configuration parameters that are unique per rendered view
Declaration
public STP.PerViewConfig[] perViewConfigs
Field Value
Type | Description |
---|---|
PerViewConfig[] |
priorImageSize
Size of the previous viewport in pixels Used to calculate image coordinate scaling factors
Declaration
public Vector2Int priorImageSize
Field Value
Type | Description |
---|---|
Vector2Int |
stencilMask
A mask value applied that determines which stencil bit is associated with the responsive feature Used to prevent STP from producing incorrect values on transparent pixels Set to 0 if no stencil data is present
Declaration
public int stencilMask
Field Value
Type | Description |
---|---|
int |