This repository has been archived on 2023-10-09. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
blender-archive/source
Mike Erwin bd11d917c1 fix atan2f input conditional
Suspicious conditional found by PVS-Studio T48917

Original code (from Blender’s initial open-source commit!) looks like
it’s testing inputs to atan2f, to avoid undefined function values.
Passing xn=0 does *not* always evaluate to 0 though… I’m not sure if
this is a coding error or was done for a desired visual result.

Also changed xn==0 to xn>=0 to avoid function call in more cases.

Good description and visualization of atan2f function:
http://en.cppreference.com/w/c/numeric/math/atan2
2016-07-22 21:00:12 -04:00
..
2016-07-22 21:00:12 -04:00
2016-07-21 07:38:15 +10:00