mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-19 13:40:49 +03:00
0022792: Globally defined symbol PI conflicts with VTK definition (Intel compiler)
This commit is contained in:
@@ -41,7 +41,7 @@ void Prs3d_AnglePresentation::Draw (
|
||||
Standard_Real x1,y1,z1,x2,y2,z2;
|
||||
AttachmentPoint2.Coord(x1,y1,z1);
|
||||
AttachmentPoint3.Coord(x2,y2,z2);
|
||||
Standard_Integer nbp = Max (4 , Standard_Integer (50. * alpha / PI));
|
||||
Standard_Integer nbp = Max (4 , Standard_Integer (50. * alpha / M_PI));
|
||||
Standard_Real dteta = alpha/(nbp-1);
|
||||
Standard_Real x,y,z;
|
||||
gp_Vec u;
|
||||
|
@@ -51,8 +51,8 @@ void Prs3d_Arrow::Draw(const Handle(Prs3d_Presentation)& aPresentation,
|
||||
|
||||
for (Standard_Integer i = 1 ; i <= NbPoints ; i++) {
|
||||
|
||||
cosinus = cos ( 2 * PI / NbPoints * (i-1) );
|
||||
sinus = sin ( 2 * PI / NbPoints * (i-1) );
|
||||
cosinus = cos ( 2 * M_PI / NbPoints * (i-1) );
|
||||
sinus = sin ( 2 * M_PI / NbPoints * (i-1) );
|
||||
|
||||
x = xc + (cosinus * xi + sinus * xj) * aLength * Tg;
|
||||
y = yc + (cosinus * yi + sinus * yj) * aLength * Tg;
|
||||
|
@@ -3,7 +3,7 @@
|
||||
#include <Prs3d_ArrowAspect.ixx>
|
||||
|
||||
Prs3d_ArrowAspect::Prs3d_ArrowAspect ()
|
||||
: myAngle(PI/180.*10), myLength(1.) {
|
||||
: myAngle(M_PI/180.*10), myLength(1.) {
|
||||
#ifdef IMP120100
|
||||
myArrowAspect =
|
||||
new Graphic3d_AspectLine3d (
|
||||
@@ -24,7 +24,7 @@ Prs3d_ArrowAspect::Prs3d_ArrowAspect (const Quantity_PlaneAngle anAngle,
|
||||
|
||||
void Prs3d_ArrowAspect::SetAngle ( const Quantity_PlaneAngle anAngle) {
|
||||
Prs3d_InvalidAngle_Raise_if ( anAngle <= 0. ||
|
||||
anAngle >= PI /2. , "");
|
||||
anAngle >= M_PI /2. , "");
|
||||
myAngle = anAngle;
|
||||
}
|
||||
Quantity_PlaneAngle Prs3d_ArrowAspect::Angle () const
|
||||
|
@@ -68,7 +68,7 @@ void Prs3d_Datum::Add( const Handle(Prs3d_Presentation)& aPresentation,
|
||||
G->SetPrimitivesAspect(aDrawer->TextAspect()->Aspect());
|
||||
G->Text(Standard_CString("X"),A(2),16.);
|
||||
#else
|
||||
Prs3d_Arrow::Draw(aPresentation,gp_Pnt(x,y,z),oX,PI/180.*10.,DS/10.);
|
||||
Prs3d_Arrow::Draw(aPresentation,gp_Pnt(x,y,z),oX,M_PI/180.*10.,DS/10.);
|
||||
Prs3d_Root::CurrentGroup(aPresentation)->Text(Standard_CString("X"),A(2),1./81.);
|
||||
#endif
|
||||
}
|
||||
@@ -85,7 +85,7 @@ void Prs3d_Datum::Add( const Handle(Prs3d_Presentation)& aPresentation,
|
||||
G->SetPrimitivesAspect(aDrawer->TextAspect()->Aspect());
|
||||
G->Text(Standard_CString("Y"),A(2),16.);
|
||||
#else
|
||||
Prs3d_Arrow::Draw(aPresentation,gp_Pnt(x,y,z),oY,PI/180.*10.,DS/10.);
|
||||
Prs3d_Arrow::Draw(aPresentation,gp_Pnt(x,y,z),oY,M_PI/180.*10.,DS/10.);
|
||||
Prs3d_Root::CurrentGroup(aPresentation)->Text(Standard_CString("Y"),A(2),1./81.);
|
||||
#endif
|
||||
}
|
||||
@@ -103,7 +103,7 @@ void Prs3d_Datum::Add( const Handle(Prs3d_Presentation)& aPresentation,
|
||||
G->Text(Standard_CString("Z"),A(2),16.);
|
||||
#else
|
||||
Prs3d_Root::CurrentGroup(aPresentation)->Text(Standard_CString("Z"),A(2),1./81.);
|
||||
Prs3d_Arrow::Draw(aPresentation,gp_Pnt(x,y,z),oZ,PI/180.*10.,DS/10.);
|
||||
Prs3d_Arrow::Draw(aPresentation,gp_Pnt(x,y,z),oZ,M_PI/180.*10.,DS/10.);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
@@ -15,8 +15,8 @@ Prs3d_Drawer::Prs3d_Drawer(): myNbPoints(30),myIsoOnPlane(Standard_False),
|
||||
myMaximalParameterValue(500000.),
|
||||
myDeviationCoefficient(0.001),
|
||||
myHLRDeviationCoefficient(0.02),
|
||||
myDeviationAngle(12*PI/180),
|
||||
myHLRAngle(20*PI/180),
|
||||
myDeviationAngle(12*M_PI/180),
|
||||
myHLRAngle(20*M_PI/180),
|
||||
myLineDrawArrow(Standard_False),
|
||||
myDrawHiddenLine(Standard_False)
|
||||
{
|
||||
|
@@ -14,7 +14,7 @@ Prs3d_PlaneAspect::Prs3d_PlaneAspect()
|
||||
myPlaneYLength= 1.;
|
||||
myArrowsLength= 0.02;
|
||||
myArrowsSize=0.1;
|
||||
myArrowsAngle=PI/8.;
|
||||
myArrowsAngle=M_PI/8.;
|
||||
}
|
||||
|
||||
Handle(Prs3d_LineAspect) Prs3d_PlaneAspect::EdgesAspect() const
|
||||
|
@@ -40,7 +40,7 @@ void Prs3d_Vector::Add(const Handle(Prs3d_Presentation)& aPresentation,
|
||||
A(2).SetCoord(x1+dx,y1+dy,z1+dz);
|
||||
G->Polyline(A);
|
||||
Prs3d_Arrow::Draw(aPresentation,gp_Pnt(x1+dx,y1+dy,z1+dz),gp_Dir(Vec),
|
||||
PI/180.*10.,Sqrt(dx*dx+dy*dy+dz*dz)/10.);
|
||||
M_PI/180.*10.,Sqrt(dx*dx+dy*dy+dz*dz)/10.);
|
||||
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user