mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-09 13:22:24 +03:00
0025266: Debug statements in the source are getting flushed on to the console
Output to cout activated previously in Debug mode by #ifdef DEB is suppressed by using macro <PACKAGE>_DEB instead of DEB
This commit is contained in:
@@ -203,9 +203,6 @@ Standard_Boolean BlendFunc_CSCircular::IsSolution(const math_Vector& Sol, const
|
||||
norm = ncrossns.Magnitude();
|
||||
if (norm < Eps) {
|
||||
norm = 1.;
|
||||
//#if DEB
|
||||
// cout << "CSCircular : Surface singuliere !" << endl;
|
||||
//#endif
|
||||
}
|
||||
|
||||
temp.SetXYZ(pts.XYZ() - ptc.XYZ());
|
||||
@@ -279,9 +276,6 @@ Standard_Boolean BlendFunc_CSCircular::Value(const math_Vector& X, math_Vector&
|
||||
Standard_Real norm = nplan.Crossed(ns).Magnitude();
|
||||
if (norm < Eps) {
|
||||
norm = 1.;
|
||||
//#if DEB
|
||||
// cout << "CSCircular : Surface singuliere !" << endl;
|
||||
//#endif
|
||||
}
|
||||
|
||||
ns.SetLinearForm(nplan.Dot(ns)/norm,nplan, -1./norm,ns);
|
||||
@@ -318,9 +312,6 @@ Standard_Boolean BlendFunc_CSCircular::Derivatives(const math_Vector& X, math_Ma
|
||||
norm = ncrossns.Magnitude();
|
||||
if (norm < Eps) {
|
||||
norm = 1.;
|
||||
//#if DEB
|
||||
// cout << "CSCircular : Surface singuliere !" << endl;
|
||||
//#endif
|
||||
}
|
||||
|
||||
ndotns = nplan.Dot(ns);
|
||||
@@ -374,9 +365,6 @@ Standard_Boolean BlendFunc_CSCircular::Values(const math_Vector& X, math_Vector&
|
||||
norm = ncrossns.Magnitude();
|
||||
if (norm < Eps) {
|
||||
norm = 1.;
|
||||
//#if DEB
|
||||
// cout << "CSCircular : Surface singuliere !" << endl;
|
||||
//#endif
|
||||
}
|
||||
|
||||
ndotns = nplan.Dot(ns);
|
||||
|
@@ -283,14 +283,14 @@ Standard_Boolean BlendFunc_ConstRad::ComputeValues(const math_Vector& X,
|
||||
if (invnorm1 > Eps) invnorm1 = ((Standard_Real) 1) /invnorm1;
|
||||
else {
|
||||
invnorm1 = 1; // Unsatisfactory, but it is not necessary to crash
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " ConstRad : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
if (invnorm2 > Eps) invnorm2 = ((Standard_Real) 1) /invnorm2;
|
||||
else {
|
||||
invnorm2 = 1; // Unsatisfactory, but it is not necessary to crash
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " ConstRad : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
@@ -878,7 +878,7 @@ Standard_Boolean BlendFunc_ConstRad::IsSolution(const math_Vector& Sol, const St
|
||||
Abs(controle(2)) > tolerances(2) ||
|
||||
Abs(controle(3)) > tolerances(3) ||
|
||||
Abs(controle(4)) > tolerances(4)){
|
||||
#ifdef DEB
|
||||
#ifdef BLENDFUNC_DEB
|
||||
cout<<"Cheminement : echec calcul des derivees"<<endl;
|
||||
#endif
|
||||
istangent = Standard_True;
|
||||
@@ -1087,9 +1087,6 @@ void BlendFunc_ConstRad::Tangent(const Standard_Real U1,
|
||||
(U2!=xval(3)) || (V2!=xval(4))) {
|
||||
gp_Vec d1u,d1v;
|
||||
gp_Pnt bid;
|
||||
//#if DEB
|
||||
// cout << " ConstRad::erreur de tengent !!!!!!!!!!!!!!!!!!!!" << endl;
|
||||
//#endif
|
||||
surf1->D1(U1,V1,bid,d1u,d1v);
|
||||
NmF = ns1 = d1u.Crossed(d1v);
|
||||
surf2->D1(U2,V2,bid,d1u,d1v);
|
||||
@@ -1349,15 +1346,9 @@ void BlendFunc_ConstRad::Section(const Blend_Point& P,
|
||||
norm2 = nplan.Crossed(ns2).Magnitude();
|
||||
if (norm1 < Eps) {
|
||||
norm1 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
//#if DEB
|
||||
// cout << " ConstRad : Surface singuliere " << endl;
|
||||
//#endif
|
||||
}
|
||||
if (norm2 < Eps) {
|
||||
norm2 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
//#if DEB
|
||||
// cout << " ConstRad : Surface singuliere " << endl;
|
||||
//#endif
|
||||
}
|
||||
|
||||
ns1.SetLinearForm(nplan.Dot(ns1)/norm1,nplan, -1./norm1,ns1);
|
||||
@@ -1480,13 +1471,13 @@ Standard_Boolean BlendFunc_ConstRad::Section
|
||||
norm2 = nplan.Crossed(ns2).Magnitude();
|
||||
if (norm1 < Eps) {
|
||||
norm1 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " ConstRad : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
if (norm2 < Eps) {
|
||||
norm2 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " ConstRad : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
@@ -1822,13 +1813,13 @@ Standard_Boolean BlendFunc_ConstRad::Section
|
||||
norm2 = nplan.Crossed(ns2).Magnitude();
|
||||
if (norm1 < Eps) {
|
||||
norm1 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " ConstRad : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
if (norm2 < Eps) {
|
||||
norm2 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " ConstRad : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
|
@@ -208,15 +208,9 @@ Standard_Boolean BlendFunc_ConstRadInv::Value(const math_Vector& X,
|
||||
Standard_Real norm2 = nplan.Crossed(ns2).Magnitude();
|
||||
if (norm1 < Eps) {
|
||||
norm1 = 1;
|
||||
//#if DEB
|
||||
// cout << " ConstRadInv : Surface singuliere " << endl;
|
||||
//#endif
|
||||
}
|
||||
if (norm2 < Eps) {
|
||||
norm2 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
//#if DEB
|
||||
// cout << " ConstRadInv : Surface singuliere " << endl;
|
||||
//#endif
|
||||
}
|
||||
|
||||
gp_Vec resul;
|
||||
@@ -300,13 +294,13 @@ Standard_Boolean BlendFunc_ConstRadInv::Derivatives(const math_Vector& X,
|
||||
norm2 = ncrossns2.Magnitude();
|
||||
if (norm1 < Eps) {
|
||||
norm1 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " ConstRadInv : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
if (norm2 < Eps) {
|
||||
norm2 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " ConstRadInv : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
@@ -481,13 +475,13 @@ Standard_Boolean BlendFunc_ConstRadInv::Values(const math_Vector& X,
|
||||
norm2 = ncrossns2.Magnitude();
|
||||
if (norm1 < Eps) {
|
||||
norm1 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " ConstRadInv : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
if (norm2 < Eps) {
|
||||
norm2 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " ConstRadInv : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
|
@@ -348,14 +348,14 @@ Standard_Boolean BlendFunc_EvolRad::ComputeValues(const math_Vector& X,
|
||||
if (invnorm1 > Eps) invnorm1 = ((Standard_Real) 1) /invnorm1;
|
||||
else {
|
||||
invnorm1 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " EvolRad : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
if (invnorm2 > Eps) invnorm2 = ((Standard_Real) 1) /invnorm2;
|
||||
else {
|
||||
invnorm2 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " EvolRad : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
@@ -947,7 +947,7 @@ Standard_Boolean BlendFunc_EvolRad::IsSolution(const math_Vector& Sol,
|
||||
Abs(controle(2)) > tolerances(2) ||
|
||||
Abs(controle(3)) > tolerances(3) ||
|
||||
Abs(controle(4)) > tolerances(4)){
|
||||
#ifdef DEB
|
||||
#ifdef BLENDFUNC_DEB
|
||||
cout<<"Cheminement : echec calcul des derivees"<<endl;
|
||||
#endif
|
||||
istangent = Standard_True;
|
||||
@@ -1072,7 +1072,7 @@ void BlendFunc_EvolRad::Tangent(const Standard_Real U1,
|
||||
(U2!=xval(3)) || (V2!=xval(4))) {
|
||||
gp_Vec d1u,d1v;
|
||||
gp_Pnt bid;
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " erreur de tengent !!!!!!!!!!!!!!!!!!!!" << endl;
|
||||
#endif
|
||||
surf1->D1(U1,V1,bid,d1u,d1v);
|
||||
@@ -1447,13 +1447,13 @@ void BlendFunc_EvolRad::Section(const Blend_Point& P,
|
||||
norm2 = nplan.Crossed(ns2).Magnitude();
|
||||
if (norm1 < Eps) {
|
||||
norm1 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " EvolRad : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
if (norm2 < Eps) {
|
||||
norm2 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " EvolRad : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
@@ -1580,13 +1580,13 @@ Standard_Boolean BlendFunc_EvolRad::Section
|
||||
norm2 = nplan.Crossed(ns2).Magnitude();
|
||||
if (norm1 < Eps) {
|
||||
norm1 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " EvolRad : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
if (norm2 < Eps) {
|
||||
norm2 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " EvolRad : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
@@ -1926,13 +1926,13 @@ Standard_Boolean BlendFunc_EvolRad::Section
|
||||
norm2 = nplan.Crossed(ns2).Magnitude();
|
||||
if (norm1 < Eps) {
|
||||
norm1 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " EvolRad : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
if (norm2 < Eps) {
|
||||
norm2 = 1; // Unsatisfactory, but it is not necessary to stop
|
||||
#if DEB
|
||||
#if BLENDFUNC_DEB
|
||||
cout << " EvolRad : Surface singuliere " << endl;
|
||||
#endif
|
||||
}
|
||||
|
@@ -212,15 +212,9 @@ Standard_Boolean BlendFunc_EvolRadInv::Value(const math_Vector& X,
|
||||
|
||||
if (norm1 < Eps) {
|
||||
norm1 = 1.;
|
||||
//#if DEB
|
||||
// cout << "EvolRadInv : Surface singuliere " << endl;
|
||||
//#endif
|
||||
}
|
||||
if (norm2 < Eps) {
|
||||
norm2 = 1.;
|
||||
//#if DEB
|
||||
// cout << "EvolRadInv : Surface singuliere " << endl;
|
||||
//#endif
|
||||
}
|
||||
|
||||
gp_Vec resul;
|
||||
@@ -323,15 +317,9 @@ Standard_Boolean BlendFunc_EvolRadInv::Values(const math_Vector& X,
|
||||
Standard_Real norm2 = ncrossns2.Magnitude();
|
||||
if (norm1 < Eps) {
|
||||
norm1 = 1.;
|
||||
//#if DEB
|
||||
// cout << "EvolRadInv : Surface singuliere " << endl;
|
||||
//#endif
|
||||
}
|
||||
if (norm2 < Eps) {
|
||||
norm2 = 1.;
|
||||
//#if DEB
|
||||
// cout << "EvolRadInv : Surface singuliere " << endl;
|
||||
//#endif
|
||||
}
|
||||
|
||||
gp_Vec resul1,resul2;
|
||||
|
Reference in New Issue
Block a user