[brlcad-commits] SF.net SVN: brlcad:[56104] brlcad/trunk/src/librt/primitives/rec/rec.c
Open Source Solid Modeling CAD
Brought to you by:
brlcad
From: <br...@us...> - 2013-07-17 15:24:29
|
Revision: 56104 http://sourceforge.net/p/brlcad/code/56104 Author: brlcad Date: 2013-07-17 15:24:23 +0000 (Wed, 17 Jul 2013) Log Message: ----------- and back to 'standard' form, this time properly propogating the sign so that we don't introduce a regression failure Modified Paths: -------------- brlcad/trunk/src/librt/primitives/rec/rec.c Modified: brlcad/trunk/src/librt/primitives/rec/rec.c =================================================================== --- brlcad/trunk/src/librt/primitives/rec/rec.c 2013-07-17 15:21:08 UTC (rev 56103) +++ brlcad/trunk/src/librt/primitives/rec/rec.c 2013-07-17 15:24:23 UTC (rev 56104) @@ -515,8 +515,8 @@ /* if the descriminant is positive, there are two roots */ descriminant = sqrt(descriminant); - k1 = (descriminant-b) * 0.5; - k2 = (descriminant+b) * (-0.5); + k1 = (-b+descriminant) * 0.5; + k2 = (-b-descriminant) * 0.5; /* * k1 and k2 are potential solutions to intersection with side. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |