diff -Nur FreeCAD-0.12.5284.orig/src/3rdParty/salomesmesh/src/Controls/SMESH_Controls.cpp FreeCAD-0.12.5284/src/3rdParty/salomesmesh/src/Controls/SMESH_Controls.cpp --- FreeCAD-0.12.5284.orig/src/3rdParty/salomesmesh/src/Controls/SMESH_Controls.cpp 2012-04-25 18:35:51.122921697 +0200 +++ FreeCAD-0.12.5284/src/3rdParty/salomesmesh/src/Controls/SMESH_Controls.cpp 2012-04-25 18:37:01.049316494 +0200 @@ -332,12 +332,12 @@ aMin = Min(aMin,A0); } - return aMin * 180.0 / PI; + return aMin * 180.0 / M_PI; } double MinimumAngle::GetBadRate( double Value, int nbNodes ) const { - //const double aBestAngle = PI / nbNodes; + //const double aBestAngle = M_PI / nbNodes; const double aBestAngle = 180.0 - ( 360.0 / double(nbNodes) ); return ( fabs( aBestAngle - Value )); } @@ -831,19 +831,19 @@ gp_XYZ N = GI.Crossed( GJ ); if ( N.Modulus() < gp::Resolution() ) - return PI / 2; + return M_PI / 2; N.Normalize(); double H = ( thePnt2 - theG ).Dot( N ); - return asin( fabs( H / L ) ) * 180. / PI; + return asin( fabs( H / L ) ) * 180. / M_PI; } double Warping::GetBadRate( double Value, int /*nbNodes*/ ) const { - // the warp is in the range [0.0,PI/2] + // the warp is in the range [0.0,M_PI/2] // 0.0 = good (no warp) - // PI/2 = bad (face pliee) + // M_PI/2 = bad (face pliee) return Value; } @@ -915,14 +915,14 @@ return 0.; // Compute skew - static double PI2 = PI / 2.; + static double PI2 = M_PI / 2.; if ( P.size() == 3 ) { double A0 = fabs( PI2 - skewAngle( P( 3 ), P( 1 ), P( 2 ) ) ); double A1 = fabs( PI2 - skewAngle( P( 1 ), P( 2 ), P( 3 ) ) ); double A2 = fabs( PI2 - skewAngle( P( 2 ), P( 3 ), P( 1 ) ) ); - return Max( A0, Max( A1, A2 ) ) * 180. / PI; + return Max( A0, Max( A1, A2 ) ) * 180. / M_PI; } else { @@ -939,15 +939,15 @@ if ( A < Precision::Angular() ) return 0.; - return A * 180. / PI; + return A * 180. / M_PI; } } double Skew::GetBadRate( double Value, int /*nbNodes*/ ) const { - // the skew is in the range [0.0,PI/2]. + // the skew is in the range [0.0,M_PI/2]. // 0.0 = good - // PI/2 = bad + // M_PI/2 = bad return Value; } diff -Nur FreeCAD-0.12.5284.orig/src/3rdParty/salomesmesh/src/SMESH/SMESH_MeshEditor.cpp FreeCAD-0.12.5284/src/3rdParty/salomesmesh/src/SMESH/SMESH_MeshEditor.cpp --- FreeCAD-0.12.5284.orig/src/3rdParty/salomesmesh/src/SMESH/SMESH_MeshEditor.cpp 2012-04-25 18:35:51.122921697 +0200 +++ FreeCAD-0.12.5284/src/3rdParty/salomesmesh/src/SMESH/SMESH_MeshEditor.cpp 2012-04-25 18:37:01.035983217 +0200 @@ -1374,7 +1374,7 @@ const SMDS_MeshNode * n1, const SMDS_MeshNode * n2) { - double angle = 2*PI; // bad angle + double angle = 2*M_PI; // bad angle // get normals SMESH::Controls::TSequenceOfXYZ P1, P2; diff -Nur FreeCAD-0.12.5284.orig/src/3rdParty/salomesmesh/src/SMESH/SMESH_Pattern.cpp FreeCAD-0.12.5284/src/3rdParty/salomesmesh/src/SMESH/SMESH_Pattern.cpp --- FreeCAD-0.12.5284.orig/src/3rdParty/salomesmesh/src/SMESH/SMESH_Pattern.cpp 2012-04-25 18:35:51.122921697 +0200 +++ FreeCAD-0.12.5284/src/3rdParty/salomesmesh/src/SMESH/SMESH_Pattern.cpp 2012-04-25 18:37:01.009316660 +0200 @@ -1234,7 +1234,7 @@ maxLen2 = Max( maxLen2, ( n[1]->myUV - n[2]->myUV ).SquareModulus() ); } maxLen2 = Max( maxLen2, ( n[2]->myUV - node->myUV ).SquareModulus() ); - minDiag = sqrt( maxLen2 ) * PI / 60.; // ~ maxLen * Sin( 3 deg ) + minDiag = sqrt( maxLen2 ) * M_PI / 60.; // ~ maxLen * Sin( 3 deg ) } // check if newUV is behind 3 dirs: n[0]-n[1], n[1]-n[2] and n[0]-n[2] @@ -1721,9 +1721,9 @@ if ( iDir == 1 ) aNorm[ iDir ].Reverse(); // along iDir isoline - double angle = tgt1.Angle( tgt2 ); // [-PI, PI] - // maybe angle is more than |PI| - if ( Abs( angle ) > PI / 2. ) { + double angle = tgt1.Angle( tgt2 ); // [-M_PI, M_PI] + // maybe angle is more than |M_PI| + if ( Abs( angle ) > M_PI / 2. ) { // check direction of the last but one perpendicular isoline TIsoNode* prevNode = bndNode2->GetNext( iDir, 0 ); bndNode1 = prevNode->GetBoundaryNode( 1 - iDir, 0 ); @@ -1733,20 +1733,20 @@ isoDir.Reverse(); double angle2 = tgt1.Angle( isoDir ); //cout << " isoDir: "<< isoDir.X() <<" "< Abs( angle ) || ( angle2 * angle < 0 && Abs( angle2 ) > Abs( angle - angle2 ))) { - //MESSAGE("Add PI"); + //MESSAGE("Add M_PI"); // cout << "NODE: "<myInitUV.X()<<" "<myInitUV.Y()<myUV.X()<<" "<myUV.Y()<< endl; // cout << "bndNode2: " << bndNode2->myUV.X()<<" "<myUV.Y()<myDir[0].Angle( node->myDir[1] ); if ( reversed ) angle = -angle; - if ( initAngle > angle && initAngle - angle > PI / 2.1 ) { + if ( initAngle > angle && initAngle - angle > M_PI / 2.1 ) { // find a close internal node TIsoNode* nClose = 0; list< TIsoNode* > testNodes; diff -Nur FreeCAD-0.12.5284.orig/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_AutomaticLength.cpp FreeCAD-0.12.5284/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_AutomaticLength.cpp --- FreeCAD-0.12.5284.orig/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_AutomaticLength.cpp 2012-04-25 18:35:51.119588376 +0200 +++ FreeCAD-0.12.5284/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_AutomaticLength.cpp 2012-04-25 18:37:00.979316783 +0200 @@ -116,14 +116,14 @@ */ //================================================================================ - const double a14divPI = 14. / PI; + const double a14divPI = 14. / M_PI; inline double segLength(double S0, double edgeLen, double minLen ) { // PAL10237 // S = S0 * f(L/Lmin) where f(x) = 1 + (2/Pi * 7 * atan(x/5) ) // => - // S = S0 * ( 1 + 14/PI * atan( L / ( 5 * Lmin ))) + // S = S0 * ( 1 + 14/M_PI * atan( L / ( 5 * Lmin ))) return S0 * ( 1. + a14divPI * atan( edgeLen / ( 5 * minLen ))); } diff -Nur FreeCAD-0.12.5284.orig/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_CompositeHexa_3D.cpp FreeCAD-0.12.5284/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_CompositeHexa_3D.cpp --- FreeCAD-0.12.5284.orig/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_CompositeHexa_3D.cpp 2012-04-25 18:35:51.119588376 +0200 +++ FreeCAD-0.12.5284/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_CompositeHexa_3D.cpp 2012-04-25 18:37:00.985983423 +0200 @@ -812,7 +812,7 @@ int iMyCommon; if ( mySides.Contain( otherSide, &iMyCommon ) ) { // check if normals of two faces are collinear at all vertices of a otherSide - const double angleTol = PI / 180 / 2; + const double angleTol = M_PI / 180 / 2; int iV, nbV = otherSide.NbVertices(), nbCollinear = 0; for ( iV = 0; iV < nbV; ++iV ) { diff -Nur FreeCAD-0.12.5284.orig/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_QuadToTriaAdaptor.cpp FreeCAD-0.12.5284/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_QuadToTriaAdaptor.cpp --- FreeCAD-0.12.5284.orig/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_QuadToTriaAdaptor.cpp 2012-04-25 18:35:51.116255055 +0200 +++ FreeCAD-0.12.5284/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_QuadToTriaAdaptor.cpp 2012-04-25 18:37:00.972650143 +0200 @@ -1037,19 +1037,19 @@ double ang1 = fabs(VN1.Angle(VI1)); double ang2 = fabs(VN2.Angle(VI2)); double h1,h2; - if(ang1>PI/3.) + if(ang1>M_PI/3.) h1 = VI1.Magnitude()/2; else h1 = VI1.Magnitude()*cos(ang1); - if(ang2>PI/3.) + if(ang2>M_PI/3.) h2 = VI2.Magnitude()/2; else h2 = VI2.Magnitude()*cos(ang2); double coef1 = 0.5; - if(ang1(Ns1[4]); diff -Nur FreeCAD-0.12.5284.orig/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_RadialQuadrangle_1D2D.cpp FreeCAD-0.12.5284/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_RadialQuadrangle_1D2D.cpp --- FreeCAD-0.12.5284.orig/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_RadialQuadrangle_1D2D.cpp 2012-04-25 18:35:51.119588376 +0200 +++ FreeCAD-0.12.5284/src/3rdParty/salomesmesh/src/StdMeshers/StdMeshers_RadialQuadrangle_1D2D.cpp 2012-04-25 18:37:00.992650061 +0200 @@ -355,8 +355,8 @@ for(; itn != theNodes.end(); itn++ ) { CNodes.push_back( (*itn).second ); double ang = (*itn).first - fang; - if( ang>PI ) ang = ang - 2*PI; - if( ang<-PI ) ang = ang + 2*PI; + if( ang>M_PI ) ang = ang - 2*M_PI; + if( ang<-M_PI ) ang = ang + 2*M_PI; Angles.Append( ang ); } } @@ -404,7 +404,7 @@ // a segment of line double fp, lp; Handle(Geom_Circle) aCirc = Handle(Geom_Circle)::DownCast( getCurve( CircEdge, &fp, &lp )); - if( fabs(fabs(lp-fp)-PI) > Precision::Confusion() ) { + if( fabs(fabs(lp-fp)-M_PI) > Precision::Confusion() ) { // not half of circle return error(COMPERR_BAD_SHAPE); } @@ -434,8 +434,8 @@ for(; itn != theNodes.end(); itn++ ) { CNodes.push_back( (*itn).second ); double ang = (*itn).first - fang; - if( ang>PI ) ang = ang - 2*PI; - if( ang<-PI ) ang = ang + 2*PI; + if( ang>M_PI ) ang = ang - 2*M_PI; + if( ang<-M_PI ) ang = ang + 2*M_PI; Angles.Append( ang ); } const SMDS_MeshNode* NF = theNodes.begin()->second; @@ -587,8 +587,8 @@ for(; itn != theNodes.end(); itn++ ) { CNodes.push_back( (*itn).second ); double ang = (*itn).first - fang; - if( ang>PI ) ang = ang - 2*PI; - if( ang<-PI ) ang = ang + 2*PI; + if( ang>M_PI ) ang = ang - 2*M_PI; + if( ang<-M_PI ) ang = ang + 2*M_PI; Angles.Append( ang ); } P1 = gp_Pnt( NF->X(), NF->Y(), NF->Z() ); @@ -1055,7 +1055,7 @@ aLine = Handle(Geom_Line)::DownCast(C3); } bool ok = !aCirc.IsNull() && !aLine.IsNull(); - if( fabs(fabs(lp-fp)-PI) > Precision::Confusion() ) { + if( fabs(fabs(lp-fp)-M_PI) > Precision::Confusion() ) { // not half of circle ok = false; } diff -Nur FreeCAD-0.12.5284.orig/src/Mod/Fem/App/AppFemPy.cpp FreeCAD-0.12.5284/src/Mod/Fem/App/AppFemPy.cpp --- FreeCAD-0.12.5284.orig/src/Mod/Fem/App/AppFemPy.cpp 2012-04-25 18:35:51.279587792 +0200 +++ FreeCAD-0.12.5284/src/Mod/Fem/App/AppFemPy.cpp 2012-04-25 18:37:08.872617387 +0200 @@ -498,12 +498,12 @@ //Do a Monte Carlo approach and start from the Principal Axis System //and rotate +/- 60° around each axis in a first iteration - double angle_range_min_x=-PI/3.0,angle_range_max_x=PI/3.0, - angle_range_min_y=-PI/3.0,angle_range_max_y=PI/3.0, - angle_range_min_z=-PI/3.0,angle_range_max_z=PI/3.0; + double angle_range_min_x=-M_PI/3.0,angle_range_max_x=M_PI/3.0, + angle_range_min_y=-M_PI/3.0,angle_range_max_y=M_PI/3.0, + angle_range_min_z=-M_PI/3.0,angle_range_max_z=M_PI/3.0; //We rotate until we are 0.1° sure to be in the right position - for (step_size = (2.0*PI/it_steps);step_size>(2.0*PI/3600.0);step_size=(2.0*PI/it_steps)) + for (step_size = (2.0*M_PI/it_steps);step_size>(2.0*M_PI/3600.0);step_size=(2.0*M_PI/it_steps)) { for(alpha_x=angle_range_min_x;alpha_x(2.0*PI/360.0);step_size=(2.0*PI/it_steps)) + for (step_size = (2.0*M_PI/it_steps);step_size>(2.0*M_PI/360.0);step_size=(2.0*M_PI/it_steps)) { for(alpha_x=angle_range_min_x;alpha_x # include +#elif defined (FC_OS_MACOSX) +# include +# include +#elif defined (FC_OS_WIN32) +# include +# include +# include +#else +# include +# include #endif #include "GLImageBox.h" diff -Nur FreeCAD-0.12.5284.orig/src/Mod/Part/App/AppPartPy.cpp FreeCAD-0.12.5284/src/Mod/Part/App/AppPartPy.cpp --- FreeCAD-0.12.5284.orig/src/Mod/Part/App/AppPartPy.cpp 2012-04-25 18:35:51.289587755 +0200 +++ FreeCAD-0.12.5284/src/Mod/Part/App/AppPartPy.cpp 2012-04-25 18:36:32.376098624 +0200 @@ -492,7 +492,7 @@ d.SetCoord(vec.x, vec.y, vec.z); } Handle_Geom_Plane aPlane = new Geom_Plane(p, d); - BRepBuilderAPI_MakeFace Face(aPlane, 0.0, length, 0.0, width); + BRepBuilderAPI_MakeFace Face(aPlane, 0.0, length, 0.0, width, Precision::Confusion()); return new TopoShapeFacePy(new TopoShape((Face.Face()))); } catch (Standard_DomainError) { diff -Nur FreeCAD-0.12.5284.orig/src/Mod/Part/App/FeatureRevolution.cpp FreeCAD-0.12.5284/src/Mod/Part/App/FeatureRevolution.cpp --- FreeCAD-0.12.5284.orig/src/Mod/Part/App/FeatureRevolution.cpp 2012-04-25 18:35:51.286254434 +0200 +++ FreeCAD-0.12.5284/src/Mod/Part/App/FeatureRevolution.cpp 2012-04-25 18:37:18.025912260 +0200 @@ -71,7 +71,7 @@ try { // Now, let's get the TopoDS_Shape TopoDS_Shape revolve = base->Shape.getShape().revolve(gp_Ax1(pnt, dir), - Angle.getValue()/180.0f*Standard_PI); + Angle.getValue()/180.0f*M_PI); if (revolve.IsNull()) return new App::DocumentObjectExecReturn("Resulting shape is null"); this->Shape.setValue(revolve); diff -Nur FreeCAD-0.12.5284.orig/src/Mod/Part/App/Geometry.cpp FreeCAD-0.12.5284/src/Mod/Part/App/Geometry.cpp --- FreeCAD-0.12.5284.orig/src/Mod/Part/App/Geometry.cpp 2012-04-25 18:35:51.286254434 +0200 +++ FreeCAD-0.12.5284/src/Mod/Part/App/Geometry.cpp 2012-04-25 18:36:32.376098624 +0200 @@ -1252,7 +1252,7 @@ Handle_Geom_Surface s = Handle_Geom_Surface::DownCast(handle()); Standard_Real u1,u2,v1,v2; s->Bounds(u1,u2,v1,v2); - BRepBuilderAPI_MakeFace mkBuilder(s, u1, u2, v1, v2); + BRepBuilderAPI_MakeFace mkBuilder(s, u1, u2, v1, v2, Precision::Confusion()); return mkBuilder.Shape(); } diff -Nur FreeCAD-0.12.5284.orig/src/Mod/Part/App/GeometrySurfacePyImp.cpp FreeCAD-0.12.5284/src/Mod/Part/App/GeometrySurfacePyImp.cpp --- FreeCAD-0.12.5284.orig/src/Mod/Part/App/GeometrySurfacePyImp.cpp 2012-04-25 18:35:51.292921076 +0200 +++ FreeCAD-0.12.5284/src/Mod/Part/App/GeometrySurfacePyImp.cpp 2012-04-25 18:36:32.376098624 +0200 @@ -79,7 +79,7 @@ s->Bounds(u1,u2,v1,v2); if (!PyArg_ParseTuple(args, "|dddd", &u1,&u2,&v1,&v2)) return 0; - BRepBuilderAPI_MakeFace mkBuilder(s, u1, u2, v1, v2); + BRepBuilderAPI_MakeFace mkBuilder(s, u1, u2, v1, v2, Precision::Confusion()); TopoDS_Shape sh = mkBuilder.Shape(); return new TopoShapeFacePy(new TopoShape(sh)); } diff -Nur FreeCAD-0.12.5284.orig/src/Mod/Part/App/PrimitiveFeature.cpp FreeCAD-0.12.5284/src/Mod/Part/App/PrimitiveFeature.cpp --- FreeCAD-0.12.5284.orig/src/Mod/Part/App/PrimitiveFeature.cpp 2012-04-25 18:35:51.286254434 +0200 +++ FreeCAD-0.12.5284/src/Mod/Part/App/PrimitiveFeature.cpp 2012-04-25 18:37:18.039245538 +0200 @@ -191,7 +191,7 @@ gp_Pnt pnt(0.0,0.0,0.0); gp_Dir dir(0.0,0.0,1.0); Handle_Geom_Plane aPlane = new Geom_Plane(pnt, dir); - BRepBuilderAPI_MakeFace mkFace(aPlane, 0.0, L, 0.0, W); + BRepBuilderAPI_MakeFace mkFace(aPlane, 0.0, L, 0.0, W, Precision::Confusion()); const char *error=0; switch (mkFace.Error()) @@ -263,9 +263,9 @@ return new App::DocumentObjectExecReturn("Radius of sphere too small"); try { BRepPrimAPI_MakeSphere mkSphere(Radius.getValue(), - Angle1.getValue()/180.0f*Standard_PI, - Angle2.getValue()/180.0f*Standard_PI, - Angle3.getValue()/180.0f*Standard_PI); + Angle1.getValue()/180.0f*M_PI, + Angle2.getValue()/180.0f*M_PI, + Angle3.getValue()/180.0f*M_PI); TopoDS_Shape ResultShape = mkSphere.Shape(); this->Shape.setValue(ResultShape); } @@ -321,9 +321,9 @@ gp_Ax2 ax2(pnt,dir); BRepPrimAPI_MakeSphere mkSphere(ax2, Radius2.getValue(), - Angle1.getValue()/180.0f*Standard_PI, - Angle2.getValue()/180.0f*Standard_PI, - Angle3.getValue()/180.0f*Standard_PI); + Angle1.getValue()/180.0f*M_PI, + Angle2.getValue()/180.0f*M_PI, + Angle3.getValue()/180.0f*M_PI); Standard_Real scale = Radius1.getValue()/Radius2.getValue(); gp_Dir xDir = ax2.XDirection(); gp_Dir yDir = ax2.YDirection(); @@ -380,7 +380,7 @@ try { BRepPrimAPI_MakeCylinder mkCylr(Radius.getValue(), Height.getValue(), - Angle.getValue()/180.0f*Standard_PI); + Angle.getValue()/180.0f*M_PI); TopoDS_Shape ResultShape = mkCylr.Shape(); this->Shape.setValue(ResultShape); } @@ -429,7 +429,7 @@ BRepPrimAPI_MakeCone mkCone(Radius1.getValue(), Radius2.getValue(), Height.getValue(), - Angle.getValue()/180.0f*Standard_PI); + Angle.getValue()/180.0f*M_PI); TopoDS_Shape ResultShape = mkCone.Shape(); this->Shape.setValue(ResultShape); } @@ -498,9 +498,9 @@ #else BRepPrimAPI_MakeTorus mkTorus(Radius1.getValue(), Radius2.getValue(), - Angle1.getValue()/180.0f*Standard_PI, - Angle2.getValue()/180.0f*Standard_PI, - Angle3.getValue()/180.0f*Standard_PI); + Angle1.getValue()/180.0f*M_PI, + Angle2.getValue()/180.0f*M_PI, + Angle3.getValue()/180.0f*M_PI); const TopoDS_Solid& ResultShape = mkTorus.Solid(); #endif this->Shape.setValue(ResultShape); diff -Nur FreeCAD-0.12.5284.orig/src/Mod/Part/App/TopoShape.cpp FreeCAD-0.12.5284/src/Mod/Part/App/TopoShape.cpp --- FreeCAD-0.12.5284.orig/src/Mod/Part/App/TopoShape.cpp 2012-04-25 18:35:51.286254434 +0200 +++ FreeCAD-0.12.5284/src/Mod/Part/App/TopoShape.cpp 2012-04-25 18:40:00.148479594 +0200 @@ -1335,7 +1335,7 @@ double u1,u2,v1,v2; surf->Bounds(u1,u2,v1,v2); - BRepBuilderAPI_MakeFace mkBuilder(surf, umin, umax, v1, v2); + BRepBuilderAPI_MakeFace mkBuilder(surf, umin, umax, v1, v2, Precision::Confusion()); return mkBuilder.Face(); } @@ -1370,7 +1370,7 @@ //circular profile Handle(Geom_Circle) aCirc = new Geom_Circle (gp::XOY(), 1.0); - aCirc->Rotate (gp::OZ(), Standard_PI/2.); + aCirc->Rotate (gp::OZ(), M_PI/2.); //perpendicular section Handle(BRepAdaptor_HCurve) myPath = new BRepAdaptor_HCurve(path_adapt); @@ -1388,7 +1388,7 @@ Standard_Real u1,u2,v1,v2; mySurface->Bounds(u1,u2,v1,v2); - BRepBuilderAPI_MakeFace mkBuilder(mySurface, u1, u2, v1, v2); + BRepBuilderAPI_MakeFace mkBuilder(mySurface, u1, u2, v1, v2, Precision::Confusion()); return mkBuilder.Shape(); } @@ -1440,7 +1440,7 @@ mkSweep.Perform(tol, Standard_False, GeomAbs_C1, BSplCLib::MaxDegree(), 1000); const Handle_Geom_Surface& surf = mkSweep.Surface(); - BRepBuilderAPI_MakeFace mkBuilder(surf, umin, umax, vmin, vmax); + BRepBuilderAPI_MakeFace mkBuilder(surf, umin, umax, vmin, vmax, Precision::Confusion()); return mkBuilder.Face(); } @@ -1469,12 +1469,12 @@ } gp_Pnt2d aPnt(0, 0); - gp_Dir2d aDir(2. * PI, pitch); + gp_Dir2d aDir(2. * M_PI, pitch); gp_Ax2d aAx2d(aPnt, aDir); Handle(Geom2d_Line) line = new Geom2d_Line(aAx2d); gp_Pnt2d beg = line->Value(0); - gp_Pnt2d end = line->Value(sqrt(4.0*PI*PI+pitch*pitch)*(height/pitch)); + gp_Pnt2d end = line->Value(sqrt(4.0*M_PI*M_PI+pitch*pitch)*(height/pitch)); Handle(Geom2d_TrimmedCurve) segm = GCE2d_MakeSegment(beg , end); TopoDS_Edge edgeOnSurf = BRepBuilderAPI_MakeEdge(segm , surf); @@ -1772,7 +1772,7 @@ Standard_Real x3, y3, z3; Handle_StlMesh_Mesh aMesh = new StlMesh_Mesh(); - StlTransfer::BuildIncrementalMesh(this->_Shape, accuracy, aMesh); + StlTransfer::BuildIncrementalMesh(this->_Shape, accuracy, false, aMesh); StlMesh_MeshExplorer xp(aMesh); for (Standard_Integer nbd=1;nbd<=aMesh->NbDomains();nbd++) { for (xp.InitTriangle (nbd); xp.MoreTriangle (); xp.NextTriangle ()) { diff -Nur FreeCAD-0.12.5284.orig/src/Mod/Part/App/TopoShapeFacePyImp.cpp FreeCAD-0.12.5284/src/Mod/Part/App/TopoShapeFacePyImp.cpp --- FreeCAD-0.12.5284.orig/src/Mod/Part/App/TopoShapeFacePyImp.cpp 2012-04-25 18:35:51.286254434 +0200 +++ FreeCAD-0.12.5284/src/Mod/Part/App/TopoShapeFacePyImp.cpp 2012-04-25 18:36:32.376098624 +0200 @@ -135,7 +135,7 @@ return -1; } - BRepBuilderAPI_MakeFace mkFace(S); + BRepBuilderAPI_MakeFace mkFace(S, Precision::Confusion()); if (bound) { Py::List list(bound); for (Py::List::iterator it = list.begin(); it != list.end(); ++it) {