From 8cd818a3d9833ef87223e43ff1f879936cbc6dc5 Mon Sep 17 00:00:00 2001 From: Nico de Poel Date: Mon, 6 Mar 2023 12:46:58 +0100 Subject: [PATCH] A bit of comment cleanup --- Assets/Scripts/Fsr2Context.cs | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/Assets/Scripts/Fsr2Context.cs b/Assets/Scripts/Fsr2Context.cs index 11a599d..cb80f16 100644 --- a/Assets/Scripts/Fsr2Context.cs +++ b/Assets/Scripts/Fsr2Context.cs @@ -130,7 +130,7 @@ namespace FidelityFX bool resetAccumulation = dispatchParams.Reset || _firstExecution; _firstExecution = false; - // if auto exposure is enabled use the auto exposure SRV, otherwise what the app sends. + // If auto exposure is enabled use the auto exposure SRV, otherwise what the app sends if ((_contextDescription.Flags & Fsr2.InitializationFlags.EnableAutoExposure) != 0) dispatchParams.Exposure = _resources.AutoExposure; else if (dispatchParams.Exposure == null) @@ -149,7 +149,7 @@ namespace FidelityFX int dispatchDstX = (_contextDescription.DisplaySize.x + (threadGroupWorkRegionDim - 1)) / threadGroupWorkRegionDim; int dispatchDstY = (_contextDescription.DisplaySize.y + (threadGroupWorkRegionDim - 1)) / threadGroupWorkRegionDim; - // Clear reconstructed depth for max depth store. + // Clear reconstructed depth for max depth store if (resetAccumulation) { commandBuffer.SetRenderTarget(_resources.LockStatus[frameIndex ^ 1]); @@ -238,9 +238,7 @@ namespace FidelityFX constants.jitterOffset = dispatchParams.JitterOffset; constants.renderSize = dispatchParams.RenderSize; constants.maxRenderSize = _contextDescription.MaxRenderSize; - constants.inputColorResourceDimensions = dispatchParams.InputResourceSize; // We have no way to query the actual width & height of the input resources, so trust that it matches the render size - // TODO: if we want to support dynamic resolution, we may have to differentiate between renderSize and inputColorResourceDimensions again - // TODO: come to think of it, couldn't we use Unity's ScalableBufferManager for dealing with render scale altogether? So we don't have to deal with this nasty double camera business? + constants.inputColorResourceDimensions = dispatchParams.InputResourceSize; // Compute the horizontal FOV for the shader from the vertical one float aspectRatio = (float)dispatchParams.RenderSize.x / dispatchParams.RenderSize.y;