Re:One does not simply calculate the absolute value
by titzer on Sunday August 22, 2021 @02:55PM
(#28268372)
It's IEEE-754.
[ Parent
| on HN ]
Re:One does not simply calculate the absolute value
by magicalhippo on Sunday August 22, 2021 @03:05PM
(#28268468)
And there are algorithms that rely on this, like this[1] branchless axis-aligned bounding box intersection test.
It exploits the division by zero sign logic of IEEE-754, so that the min/max operations used also handles the edge cases where the ray is parallel to an axis.