mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-14 13:30:48 +03:00
0022792: Globally defined symbol PI conflicts with VTK definition (Intel compiler)
This commit is contained in:
@@ -187,7 +187,7 @@ static OSD_Timer FullTimer;
|
||||
*/
|
||||
|
||||
#define Zmargin 1.
|
||||
#define DEUXPI (2.*Standard_PI)
|
||||
#define DEUXPI (2. * M_PI)
|
||||
|
||||
// in case of NO_TRACE_ECHO and NO_TRACE_POINTS, in V3d_View_4.cxx and in
|
||||
// V3d_View.cxx, change MyGridEchoStructure and MyGridEchoGroup in cdl
|
||||
@@ -2560,8 +2560,8 @@ Standard_Real V3d_View::Twist()const {
|
||||
if( angle > 1. ) angle = 1. ;
|
||||
else if( angle < -1. ) angle = -1. ;
|
||||
angle = asin(angle) ;
|
||||
if( sca < 0. ) angle = Standard_PI - angle ;
|
||||
if( angle > 0. && angle < Standard_PI ) {
|
||||
if( sca < 0. ) angle = M_PI - angle ;
|
||||
if( angle > 0. && angle < M_PI ) {
|
||||
sca = pvx*Xpn + pvy*Ypn + pvz*Zpn ;
|
||||
if( sca < 0. ) angle = DEUXPI - angle ;
|
||||
}
|
||||
@@ -3134,13 +3134,13 @@ void V3d_View::Rotation(const Standard_Integer X,
|
||||
dz = atan2(Standard_Real(X)-rx/2., ry/2.-Standard_Real(Y)) -
|
||||
atan2(sx-rx/2.,ry/2.-sy);
|
||||
} else {
|
||||
dx = (Standard_Real(X) - sx) * Standard_PI/rx;
|
||||
dy = (sy - Standard_Real(Y)) * Standard_PI/ry;
|
||||
dx = (Standard_Real(X) - sx) * M_PI / rx;
|
||||
dy = (sy - Standard_Real(Y)) * M_PI / ry;
|
||||
}
|
||||
Rotate(dx, dy, dz, gx, gy, gz, Standard_False);
|
||||
#else
|
||||
Standard_Real dx = (Standard_Real(X - sx)) * Standard_PI;
|
||||
Standard_Real dy = (Standard_Real(sy - Y)) * Standard_PI;
|
||||
Standard_Real dx = (Standard_Real(X - sx)) * M_PI;
|
||||
Standard_Real dy = (Standard_Real(sy - Y)) * M_PI;
|
||||
Rotate(dx/rx, dy/ry, 0., gx, gy, gz, Standard_False);
|
||||
#endif
|
||||
#ifdef IMP020300
|
||||
|
Reference in New Issue
Block a user