Fix T42344: EWA filter produces blured results
Derivatives variable names are swapped in the old EWA filter code, need to adjust for that. TODO: Make naming fore clear in there.
This commit is contained in:
parent
fcc2ca0089
commit
7bb910cd4e
Notes:
blender-bot
2023-02-14 09:55:19 +01:00
Referenced by issue #42344, blurred BI-render, 2.72a regression?
|
@ -467,7 +467,7 @@ void BLI_ewa_filter(const int width, const int height,
|
|||
/* scaling dxt/dyt by full resolution can cause overflow because of huge A/B/C and esp. F values,
|
||||
* scaling by aspect ratio alone does the opposite, so try something in between instead... */
|
||||
const float ff2 = (float)width, ff = sqrtf(ff2), q = (float)height / ff;
|
||||
const float Ux = du[0] * ff, Vx = dv[0] * q, Uy = du[1] * ff, Vy = dv[1] * q;
|
||||
const float Ux = du[0] * ff, Vx = du[1] * q, Uy = dv[0] * ff, Vy = dv[1] * q;
|
||||
float A = Vx * Vx + Vy * Vy;
|
||||
float B = -2.0f * (Ux * Vx + Uy * Vy);
|
||||
float C = Ux * Ux + Uy * Uy;
|
||||
|
|
Loading…
Reference in New Issue