Browse Source

Perform camera scaling in OnPreCull, instead of OnPreRender.

Fixed compatibility with post-FX executing OnPreRender before FSR2, and which retrieve camera resolution values to perform their rendering. For example: HBAO.
mac-autoexp
Nico de Poel 3 years ago
parent
commit
341921bdda
  1. 2
      Assets/Scripts/Fsr2Controller.cs

2
Assets/Scripts/Fsr2Controller.cs

@ -164,7 +164,7 @@ namespace FidelityFX
_reset = true; _reset = true;
} }
private void OnPreRender()
private void OnPreCull()
{ {
// Render to a smaller portion of the screen by manipulating the camera's viewport rect // Render to a smaller portion of the screen by manipulating the camera's viewport rect
_originalRect = _renderCamera.rect; _originalRect = _renderCamera.rect;

Loading…
Cancel
Save