Skip to content

Commit

Permalink
+ fix for OCC 6.3
Browse files Browse the repository at this point in the history
  • Loading branch information
wwmayer committed Feb 22, 2015
1 parent e8fafa1 commit b5b54c5
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/Mod/Part/App/Geometry.cpp
Expand Up @@ -1154,7 +1154,11 @@ Base::Vector3d GeomEllipse::getMajorAxisDir() const
*/
void GeomEllipse::setMajorAxisDir(Base::Vector3d newdir)
{
#if OCC_VERSION_HEX >= 0x060300
if (newdir.Sqr() < Precision::SquareConfusion())
#else
if (newdir.Length() < Precision::Confusion())
#endif
return;//zero vector was passed. Keep the old orientation.
try {
gp_Ax2 pos = myCurve->Position();
Expand Down Expand Up @@ -1479,7 +1483,11 @@ void GeomArcOfEllipse::setMajorAxisDir(Base::Vector3d newdir)
{
Handle_Geom_Ellipse c = Handle_Geom_Ellipse::DownCast( myCurve->BasisCurve() );
assert(!c.IsNull());
#if OCC_VERSION_HEX >= 0x060300
if (newdir.Sqr() < Precision::SquareConfusion())
#else
if (newdir.Length() < Precision::Confusion())
#endif
return;//zero vector was passed. Keep the old orientation.
try {
gp_Ax2 pos = c->Position();
Expand Down

0 comments on commit b5b54c5

Please sign in to comment.