mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-04-09 18:50:54 +03:00
OCC22324 Mistakes with parenthesis position in abs calls
This commit is contained in:
parent
c80dc6c3f4
commit
82ac7cbbe7
@ -133,7 +133,8 @@ static void Hunt(const TColStd_Array1OfReal& Arr,
|
|||||||
if(Abs(Coord - Arr(i)) < Tol)
|
if(Abs(Coord - Arr(i)) < Tol)
|
||||||
Iloc = i;
|
Iloc = i;
|
||||||
else
|
else
|
||||||
if(Abs(Coord-Arr(i)>Tol)) Standard_NotImplemented::Raise("Adaptor3d_CurveOnSurface:Hunt");
|
if(Abs(Coord - Arr(i)) > Tol)
|
||||||
|
Standard_NotImplemented::Raise("Adaptor3d_CurveOnSurface:Hunt");
|
||||||
}
|
}
|
||||||
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
|
@ -163,7 +163,7 @@ void Aspect_RectangularGrid::Init () {
|
|||||||
|
|
||||||
Standard_Boolean Aspect_RectangularGrid::CheckAngle(const Standard_Real alpha,
|
Standard_Boolean Aspect_RectangularGrid::CheckAngle(const Standard_Real alpha,
|
||||||
const Standard_Real beta) const {
|
const Standard_Real beta) const {
|
||||||
return Abs( Sin(alpha)*Cos(beta+Standard_PI/2.) - Cos(alpha)*Sin(beta+Standard_PI/2.) != 0) ;
|
return (Abs( Sin(alpha) * Cos(beta+Standard_PI/2.) - Cos(alpha) * Sin(beta+Standard_PI/2.)) != 0) ;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -121,7 +121,7 @@ void GeomFill_BoundWithSurf::D1Norm(const Standard_Real U,
|
|||||||
Standard_Real nsuu = N.Dot(Suu), nsuv = N.Dot(Suv), nsvv = N.Dot(Svv);
|
Standard_Real nsuu = N.Dot(Suu), nsuv = N.Dot(Suv), nsvv = N.Dot(Svv);
|
||||||
Standard_Real susu = Su.Dot(Su), susv = Su.Dot(Sv), svsv = Sv.Dot(Sv);
|
Standard_Real susu = Su.Dot(Su), susv = Su.Dot(Sv), svsv = Sv.Dot(Sv);
|
||||||
Standard_Real deno = (susu*svsv) - (susv*susv);
|
Standard_Real deno = (susu*svsv) - (susv*susv);
|
||||||
if(Abs(deno < 1.e-16)){
|
if(Abs(deno) < 1.e-16) {
|
||||||
// on embraye sur un calcul approche, c est mieux que rien!?!
|
// on embraye sur un calcul approche, c est mieux que rien!?!
|
||||||
gp_Vec temp = Norm(U + 1.e-12);
|
gp_Vec temp = Norm(U + 1.e-12);
|
||||||
DN = N.Multiplied(-1.);
|
DN = N.Multiplied(-1.);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user