[Bf-blender-cvs] [cdeb3c3] master: Fix for incorrect use of abs() in intersect_sphere_sphere_2d
Campbell Barton
noreply at git.blender.org
Wed Jan 8 17:16:16 CET 2014
Commit: cdeb3c3922b6715b87bde6eefa859baa83ebc5e4
Author: Campbell Barton
Date: Thu Jan 9 03:07:17 2014 +1100
https://developer.blender.org/rBcdeb3c3922b6715b87bde6eefa859baa83ebc5e4
Fix for incorrect use of abs() in intersect_sphere_sphere_2d
===================================================================
M source/blender/python/mathutils/mathutils_geometry.c
===================================================================
diff --git a/source/blender/python/mathutils/mathutils_geometry.c b/source/blender/python/mathutils/mathutils_geometry.c
index 108ebfa..10f4e57 100644
--- a/source/blender/python/mathutils/mathutils_geometry.c
+++ b/source/blender/python/mathutils/mathutils_geometry.c
@@ -298,7 +298,7 @@ static PyObject *M_Geometry_intersect_sphere_sphere_2d(PyObject *UNUSED(self), P
if (/* out of range */
(dist > rad_a + rad_b) ||
/* fully-contained in the other */
- (dist < abs(rad_a - rad_b)) ||
+ (dist < fabsf(rad_a - rad_b)) ||
/* co-incident */
(dist < FLT_EPSILON))
{
More information about the Bf-blender-cvs
mailing list