1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-19 13:40:49 +03:00

0025418: Debug output to be limited to OCC development environment

Macros ending on "DEB" are replaced by OCCT_DEBUG across OCCT code; new macros described in documentation.
Macros starting with DEB are changed to start with "OCCT_DEBUG_".
Some code cleaned.
This commit is contained in:
abv
2014-10-28 12:41:04 +03:00
committed by bugmaster
parent a507ffd9d7
commit 0797d9d30a
700 changed files with 3932 additions and 4250 deletions

View File

@@ -413,7 +413,7 @@ static Standard_Boolean IsInside(const TopoDS_Shape& S1,
return Standard_False;
}
}
#ifdef LOCOPE_DEB
#ifdef OCCT_DEBUG
cout << "Classification impossible sur vertex " << endl;
#endif

View File

@@ -62,7 +62,7 @@
#include <BRepTools.hxx>
#include <Standard_ConstructionError.hxx>
#ifdef DEB
#ifdef OCCT_DEBUG
extern Standard_Boolean BRepFeat_GettraceFEAT();
#endif
@@ -709,7 +709,7 @@ Handle(Geom_Curve) LocOpe_DPrism::BarycCurve() const
Normale.Reverse();
}
if (mySpine.Orientation() == TopAbs_REVERSED) {
#ifdef DEB
#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) {
cout << "LocOpe_DPrism::BarycCurve()" << endl;

View File

@@ -152,7 +152,7 @@ void LocOpe_FindEdges::Set(const TopoDS_Shape& FFrom,
}
else {
// Cas non traite : on est a cheval
#ifdef LOCOPE_DEB
#ifdef OCCT_DEBUG
cout <<" cas a cheval."<< endl;
#endif
@@ -204,7 +204,7 @@ void LocOpe_FindEdges::Set(const TopoDS_Shape& FFrom,
}
else {
// Cas non traite : on est a cheval
#ifdef LOCOPE_DEB
#ifdef OCCT_DEBUG
cout <<" cas a cheval."<< endl;
#endif
// myLFrom.Append(edgf);
@@ -287,7 +287,7 @@ void LocOpe_FindEdges::Set(const TopoDS_Shape& FFrom,
}
if (IsSame) {
#ifdef LOCOPE_DEB
#ifdef OCCT_DEBUG
cout <<"memes bsplines."<< endl;
#endif
myLFrom.Append(edgf);
@@ -347,7 +347,7 @@ void LocOpe_FindEdges::Set(const TopoDS_Shape& FFrom,
}
if (IsSame) {
#ifdef LOCOPE_DEB
#ifdef OCCT_DEBUG
cout <<"memes beziers."<< endl;
#endif
myLFrom.Append(edgf);

View File

@@ -907,7 +907,7 @@ void LocOpe_SplitDrafts::Perform(const TopoDS_Face& F,
MapW(edg) = GenF;
}
else {
#ifdef DEB
#ifdef OCCT_DEBUG
cout << "Pb d'analyse" << endl;
#endif
return;
@@ -1253,7 +1253,7 @@ void LocOpe_SplitDrafts::Perform(const TopoDS_Face& F,
for (itl.Initialize(itdmsls.Value());itl.More(); itl.Next()) {
if (theSubs.IsCopied(itl.Value())) {
if (theSubs.Copy(itl.Value()).Extent() != 1) {
#ifdef LOCOPE_DEB
#ifdef OCCT_DEBUG
cout << "Invalid number of descendant" << endl;
#endif
return;
@@ -1725,7 +1725,7 @@ static TopoDS_Edge NewEdge(const TopoDS_Edge& edg,
}
}
}
#ifdef DEB
#ifdef OCCT_DEBUG
Standard_Real ptol = Precision::PConfusion();
if (prmf < imf - ptol || prmf > iml + ptol ||
prml < imf - ptol || prml > iml + ptol) {

View File

@@ -559,7 +559,7 @@ void LocOpe_SplitShape::Add(const TopoDS_Wire& W,
AddClosedWire(W,F);
}
} catch (Standard_Failure ) {
#ifdef LOCOPE_DEB
#ifdef OCCT_DEBUG
cout << "Warning: SpliShape internal problem detected, some faces may be lost. Check input edges/wires" <<endl;
#endif
return;
@@ -1168,7 +1168,7 @@ const TopTools_ListOfShape& LocOpe_SplitShape::DescendantShapes
Rebuild(myShape);
myDone = Standard_True;
}
#ifdef LOCOPE_DEB
#ifdef OCCT_DEBUG
if (!myDblE.IsEmpty()) {
cout << "Le shape comporte des faces invalides" << endl;
}
@@ -1286,7 +1286,7 @@ static Standard_Boolean IsInside(const TopoDS_Face& F,
Standard_Real f,l;
Handle(Geom2d_Curve) C2d = BRep_Tool::CurveOnSurface(edg,F,f,l);
if(C2d.IsNull()) {
#ifdef LOCOPE_DEB
#ifdef OCCT_DEBUG
cout << "Edge is not on surface" <<endl;
#endif
return Standard_False;

View File

@@ -126,7 +126,7 @@ void LocOpe_Spliter::Perform(const Handle(LocOpe_WiresOnShape)& PW)
for (; itdesc.More(); itdesc.Next()) {
if (theSubs.IsCopied(itdesc.Key())) {
const TopTools_ListOfShape& lsub = theSubs.Copy(itdesc.Key());
#ifdef DEB
#ifdef OCCT_DEBUG
if (lsub.Extent() != 1) {
Standard_ConstructionError::Raise();
}
@@ -293,7 +293,7 @@ void LocOpe_Spliter::Perform(const Handle(LocOpe_WiresOnShape)& PW)
theSubs.Substitute(ebase.Oriented(TopAbs_FORWARD),lsubs);
}
else {
#ifdef LOCOPE_DEB
#ifdef OCCT_DEBUG
cout << "Pb pour substitution" << endl;
#endif
}
@@ -307,7 +307,7 @@ void LocOpe_Spliter::Perform(const Handle(LocOpe_WiresOnShape)& PW)
for (itl.Initialize(ldesc); itl.More(); itl.Next()) {
if (theSubs.IsCopied(itl.Value())) {
const TopTools_ListOfShape& lsub = theSubs.Copy(itl.Value());
#ifdef DEB
#ifdef OCCT_DEBUG
if (lsub.Extent() != 1) {
Standard_ConstructionError::Raise();
}

View File

@@ -513,7 +513,7 @@ Standard_Boolean Project(const TopoDS_Vertex& V,
BRep_Builder B;
B.UpdateVertex(V, Max(dmin, BRep_Tool::Tolerance(V)));
}
#ifdef DEB_MESH
#ifdef OCCT_DEBUG_MESH
else {
cout <<"LocOpe_WiresOnShape::Project --> le vertex projete est a une ";
cout <<"distance / la face = "<<dmin <<" superieure a la tolerance = "<<ttol<<endl;