NVlabs / flip

A tool for visualizing and communicating the errors in rendered images.
498 stars 41 forks source link

[CPP] Fixed Bug due to uninitialized Memory #17

Closed hhergeth closed 1 year ago

hhergeth commented 1 year ago

I noticed that on an M1 Max the computed results (both the mean and the output images) for exr input files had a 50/50 chance of being wrong. After looking through the code I noticed that the setMaxExposure function only conditionally sets the "errorMap" and "this" pixel values.

Initializing errorMapFLIP and tmpErrorMap with 0 values fixes the problem.

pandersson94 commented 1 year ago

Hi @hhergeth,

Thanks for trying out FLIP and solving the issue you found. We'll merge with your fix.

Best regards, Pontus