@ -33,7 +33,7 @@ namespace ArmASR
/// <summary>
/// Creates a new ASR context with standard parameters that are appropriate for the current platform.
/// </summary>
public static AsrContext CreateContext ( Vector2Int displaySize , Vector2Int maxRenderSize , AsrShaders shaders , InitializationFlags flags = 0 )
public static AsrContext CreateContext ( Variant variant , V ector2Int displaySize , Vector2Int maxRenderSize , AsrShaders shaders , InitializationFlags flags = 0 )
{
if ( SystemInfo . usesReversedZBuffer )
flags | = InitializationFlags . EnableDepthInverted ;
@ -49,6 +49,7 @@ namespace ArmASR
var contextDescription = new ContextDescription
{
Flags = flags ,
Variant = variant ,
DisplaySize = displaySize ,
MaxRenderSize = maxRenderSize ,
Shaders = shaders ,
@ -172,6 +173,13 @@ namespace ArmASR
UnityEngine . Object . Destroy ( obj ) ;
#endif
}
public enum Variant
{
Quality , // Maintains the same image quality as the original FSR2.
Balanced , // Gives a significant improvement in both bandwidth savings and performance uplift while maintaining close image quality to the 'quality' preset.
Performance , // A more aggressive preset that will give you the highest performance with some quality sacrifices.
}
public enum QualityMode
{
@ -203,6 +211,7 @@ namespace ArmASR
public struct ContextDescription
{
public InitializationFlags Flags ;
public Variant Variant ;
public Vector2Int MaxRenderSize ;
public Vector2Int DisplaySize ;
public AsrShaders Shaders ;