1
0
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:
dbv
2014-10-08 19:00:20 +04:00
committed by abv
parent 7aa1b65c2a
commit 63c629aa3a
370 changed files with 1634 additions and 1639 deletions

View File

@@ -305,7 +305,7 @@ static Standard_Boolean Connect (const Handle(ShapeAnalysis_Wire)& theSAW,
TopoDS_Edge edge3d = Lsewd3d->Edge (iedge), edge2d = Lsewd2d->Edge (iedge);
if (!IGESToBRep::TransferPCurve (edge2d, edge3d, myface)) continue;
if (sfe->FixReversed2d (edge3d, myface)) {
#ifdef DEB
#ifdef IGESCONTROL_DEB
cout << "Warning: IGESToBRep_IGESBoundary: 2D curve of edge was reversed" << endl;
#endif
}
@@ -325,19 +325,19 @@ static Standard_Boolean Connect (const Handle(ShapeAnalysis_Wire)& theSAW,
Standard_Real maxdev = BRep_Tool::Tolerance (edge3d);
//pdn 08.04.99 S4135 recomputing only if deviation is greater than maxtol
if (maxdev > maxtol) { //:e2
#ifdef DEB
#ifdef IGESCONTROL_DEB
cout << "Warning: IGESToBRep_IGESBoundary: Deviation = " << maxdev << endl;
#endif
ShapeFix_ShapeTolerance().SetTolerance (edge3d, Precision::Confusion());
for (Standard_Integer ie = 1; ie <= iedge; ie++)
ShapeBuild_Edge().RemovePCurve (Lsewd3d->Edge (ie), myface);
if (Preferred3d) {
#ifdef DEB
#ifdef IGESCONTROL_DEB
cout << "Warning: IGESToBRep_IGESBoundary: 3D and 2D curves are inconsistent; 2D is ignored" << endl;
#endif
}
else {
#ifdef DEB
#ifdef IGESCONTROL_DEB
cout << "Warning: IGESToBRep_IGESBoundary: 3D and 2D curves are inconsistent; 3D is ignored" << endl;
#endif
Lsewd = Lsewd2d;
@@ -348,7 +348,7 @@ static Standard_Boolean Connect (const Handle(ShapeAnalysis_Wire)& theSAW,
}
okCurve = okCurve && ShapeAlgo::AlgoContainer()->ConnectNextWire (saw, Lsewd, maxtol, distmin, revsewd, revnextsewd);
if (!okCurve) {
#ifdef DEB
#ifdef IGESCONTROL_DEB
cout << "Warning: IGESToBRep_IGESBoundary: Curves " << i - 1 << " and " << i << " cannot be connected" << endl;
#endif
Gsewd3d = new ShapeExtend_WireData;

View File

@@ -245,7 +245,7 @@ Standard_Boolean IGESControl_Writer::Write
if (!S) return Standard_False;
ComputeModel();
Standard_Integer nbEnt = themod->NbEntities();
#ifdef DEBUG
#ifdef IGESCONTROL_DEB
cout<<" IGES Write : "<<nbEnt<<" ent.s"<< flush;
#endif
if(!nbEnt)
@@ -253,12 +253,12 @@ Standard_Boolean IGESControl_Writer::Write
IGESData_IGESWriter IW (themod);
// ne pas oublier le mode fnes ... a transmettre a IW
IW.SendModel (IGESSelect_WorkLibrary::DefineProtocol());
#ifdef DEBUG
#ifdef IGESCONTROL_DEB
cout<<" ... ecriture ..."<<flush;
#endif
if (fnes) IW.WriteMode() = 10;
Standard_Boolean status = IW.Print(S);
#ifdef DEBUG
#ifdef IGESCONTROL_DEB
cout<<" ... fichier ecrit ..."<<endl;
#endif
return status;
@@ -269,7 +269,7 @@ Standard_Boolean IGESControl_Writer::Write
{
ofstream fout(file,ios::out);
if (!fout) return Standard_False;
#ifdef DEBUG
#ifdef IGESCONTROL_DEB
cout<<" Ecriture fichier ("<< (fnes ? "fnes" : "IGES") <<"): "<<file<<endl;
#endif
Standard_Boolean res = Write (fout,fnes);