Salome HOME
porting : eliminate comp. errors
[modules/hydro.git] / src / HYDROData / HYDROData_StreamAltitude.cxx
index cbd1cca0c6bcb6ce389cc8628b17c7bc6d6f6340..2360eddd0fce93aa735dd9b99d12bfe530995f6e 100644 (file)
@@ -126,7 +126,7 @@ bool IsPointBetweenEdges2( const gp_Pnt& aFirstPnt1, const gp_Pnt& aLastPnt1,
   double z1 = x1*ya -xa*y1; // v1^va: z component
   double z2 = x2*yb -xb*y2; // v2^vb: z component
   bool isBetween = true;
-  if (((z1<0) and (z2<0)) or ((z1>=0) and (z2>=0)))
+  if (((z1<0) && (z2<0)) || ((z1>=0) && (z2>=0)))
     {
       isBetween = false;
     }
@@ -138,9 +138,9 @@ bool IsPointBetweenEdges2( const gp_Pnt& aFirstPnt1, const gp_Pnt& aLastPnt1,
       double dl1 = (aLastPnt1.X()-xg)*(aLastPnt1.X()-xg) + (aLastPnt1.Y()-yg)*(aLastPnt1.Y()-yg);
       double df2 = (aFirstPnt2.X()-xg)*(aFirstPnt2.X()-xg) + (aFirstPnt2.Y()-yg)*(aFirstPnt2.Y()-yg);
       double dl2 = (aLastPnt2.X()-xg)*(aLastPnt2.X()-xg) + (aLastPnt2.Y()-yg)*(aLastPnt2.Y()-yg);
-      double r2 = fmax(df1,dl1);
-      r2 = fmax(r2,df2);
-      r2 = fmax(r2,dl2);
+      double r2 = std::max(df1,dl1);
+      r2 = std::max(r2,df2);
+      r2 = std::max(r2,dl2);
       double d2 = (thePoint.X()-xg)*(thePoint.X()-xg) + (thePoint.Y()-yg)*(thePoint.Y()-yg);
       if (d2 > r2)
         isBetween = false;