Looks like it handles dynamic resolution and can compensate for inconsistent frame times when using motion vectors. It looks fairly complicated. Not 100% what the sections about "dilation" are referring to. Is it just elapsed time? Seems like it upscales using blue noise texture to randomly sample history and converge to a stable image? Uses TAA, so it's like TAA with blue noise sample selection or something?
Edit: I guess randomly sample is the wrong term. The noise is not random, and the blue noise textures are probably precomputed. With these blue noise techniques, do you use a different blue noise texture each frame, or the same texture? Like, the noise produces dithering frame to frame, which reduces noise? That necessitates a new noise mask each frame, no? Or do you use the same blue noise mask and then remove it?
/// Blue noise texture used in various parts of the upscaling logic
/// Input color texture to be upscaled
/// Input depth texture which will be analyzed during upscaling
/// Input motion vector texture which is used to reproject information across frames
/// [Optional] Input stencil texture which is used to identify pixels that need special treatment such as particles or in-game screens
/// [Optional] Output debug view texture which STP can be configured to render debug visualizations into
/// Output color texture which will receive the final upscaled color result
/// Input history context to use when executing STP
/// Set to true if hardware dynamic resolution scaling is currently active
/// Set to true if the rendering environment is using 2d array textures (usually due to XR)
/// Set to true to enable the motion scaling feature which attempts to compensate for variable frame timing when working with motion vectors
/// Distance to the camera's near plane
/// Used to encode depth values
/// Distance to the camera's far plane
/// Used to encode depth values
/// Index of the current frame
/// Used to calculate jitter pattern
/// True if the current frame has valid history information
/// Used to prevent STP from producing invalid data
/// 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
/// 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
/// Delta frame time for the current frame
/// Used to compensate for inconsistent frame timings when working with motion vectors
/// Delta frame time for the previous frame
/// Used to compensate for inconsistent frame timings when working with motion vectors
/// Size of the current viewport in pixels
/// Used to calculate image coordinate scaling factors
/// Size of the previous viewport in pixels
/// Used to calculate image coordinate scaling factors
/// Size of the upscaled output image in pixels
/// Used to calculate image coordinate scaling factors
/// Number of active views in the perViewConfigs array
/// Configuration parameters that are unique per rendered view
/// Enumeration of unique types of history textures
DepthMotion,
Luma,
Convergence,
Feedback,
Edit: I'm guessing it has some similarity to this?
https://research.nvidia.com/publication/2022-07_spatiotemporal-blue-noise-masks
Spatiotemporal blue noise is different than using multiple blue noise textures? Basically if you use a series of blue noise textures each frame they'd converge temporally towards random noise or white noise, but spatiotemporal blue noise is blue noise spatially but converges towards no noise temporally. Or something.
Interesting. In this nvidia video they mention the problem of moving pixels like TAA. Basically if a pixel moves it's position on screen (samples from history moved with motion vectors) the noise will become white noise because it disobeys the convergence of the spatiotemporal blue noise. So that's a problem this STP algorithm would have to solve.