GPUOpen-Effects / FidelityFX-FSR

FidelityFX Super Resolution
MIT License
2.05k stars 163 forks source link

Bug fix to restore non-clipping behavior #24

Closed UnityTimothyLottes closed 2 years ago

UnityTimothyLottes commented 3 years ago

There is a bug in the {hitMin,hitMax} computation. The 'mn' and 'mx' variables only contain the {b,d,f,h} ring of taps (this is needed for the rcp() based term). However it is possible that the center {e} tap could exceed the minimum and maximum of the {b,d,f,h} ring, causing incorrect function. This change places {e} tap back into the non-rcp() based term for 'hitMin' and 'hitMax' correcting the maths and restoring non-clipping output. The bug manifests visually as over-sharpening isolated pixels.

rys commented 2 years ago

Thanks @UnityTimothyLottes, fixed in a21ffb8!