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.
@tableofcontents
+@section occt_debug_macro Compiler macro to enable extended debug messages
+
+Many OCCT algorithms can produce extended debug messages, usually printed to cout.
+These include messages on internal errors and special cases encountered, timing etc.
+In OCCT versions prior to 6.8.0 most of these messages were activated by compiler macro *DEB*, enabled by default in debug builds.
+Since version 6.8.0 this is disabled by default but can be enabled by defining compiler macro *OCCT_DEBUG*.
+
+To enable this macro on Windows when building with Visual Studio projects, edit file custom.bat and add the line:
+
+ set CSF_DEFINES=OCCT_DEBUG
+
+Some algorithms use specific macros for yet more verbose messages, usually started with OCCT_DEBUG_.
+These messages can be enabled in the same way, by defining corresponding macro.
+
+Note that some header files are modified when *OCCT_DEBUG* is enabled, hence binaries built with it enabled are not compatible with client code built without this option; this is not intended for production use.
+
+@section occt_debug_exceptions Calling JIT debugger on exception
+
+On Windows platform when using Visual Studio compiler there is a possibility to start the debugger automatically if an exception is caught in a program running OCCT. For this, set environment variable *CSF_DEBUG* to any value. Note that this feature works only if you enable OCCT exception handler in your application by calling *OSD::SetSignal()*.
+
@section occt_debug_intro Introduction
This manual describes facilities included in OCCT to support debugging, and provides some hints for more efficient debug.
The diagnostic code checks validity of the input arguments and the result of each Boolean operation. When an invalid situation is detected, the report consisting of argument shapes and a DRAW script to reproduce the problematic operation is saved to the directory pointed by *CSF_DEBUG_BOP*.
-@section occt_debug_exceptions Calling JIT debugger on exception
-
-On Windows platform when using Visual Studio compiler there is a possibility to start the debugger automatically if an exception is caught in a program running OCCT. For this, set environment variable *CSF_DEBUG* to any value. Note that this feature works only if you enable OCCT exception handler in your application by calling *OSD::SetSignal()*.
-
@section occt_debug_call Functions for calling from debugger
Modern interactive debuggers provide the possibility to execute application code at a program break point. This feature can be used to analyse the temporary objects available only in the context of the debugged code. OCCT provides several global functions that can be used in this way.
if (Handle(AIS_InteractiveObject)::DownCast(anObj->Selectable()).IsNull()) return Standard_False;
Standard_Boolean okstat = Standard_True;
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
Handle(SelectMgr_SelectableObject) aSelectable = anObj->Selectable() ;
if( hasC && ((Handle(AIS_InteractiveObject)&) aSelectable)->HasColor() )
//#else
//#endif
okstat = (myCol == ((Handle(AIS_InteractiveObject)&) anObj)->Color());
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
aSelectable = anObj->Selectable() ;
if( hasW && ((Handle(AIS_InteractiveObject)&) aSelectable)->HasWidth() )
//#else
void AIS_InteractiveContext::DisplayedObjects(AIS_ListOfInteractive& aListOfIO,
const Standard_Boolean OnlyFromNeutral) const
{
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<"AIS_IC::DisplayedObjects"<<endl;
#endif
}
//parse all local contexts...
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<"\tFrom Neutral Point : "<<theMap.Extent()<<endl;
Standard_Integer NbDisp;
for(AIS_DataMapIteratorOfDataMapOfILC it1(myLocalContexts);it1.More();it1.Next()){
Handle(AIS_InteractiveObject) IO = It.Key();
// ENDCLE
if(IO->Type()== KOI){
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean good = (Sign==-1)? Standard_True :
// ((IO->Signature()==Sign)? Standard_True:Standard_False);
#endif
NbDisp++;
}
anIObj->SetRecomputeOk();
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<"nb of modes to recalculate : "<<NbDisp<<endl;
#endif
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
// // pour isg
// if(anIObj->Type()==AIS_KOI_Datum && anIObj->Signature()==3){
// Handle(AIS_Trihedron) Tr = *((Handle(AIS_Trihedron)*)&anIObj);
NbDisp++;
}
anIObj->SetRecomputeOk();
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<"nb of modes to recalculate : "<<NbDisp<<endl;
#endif
}
NbDisp++;
}
anIObj->SetRecomputeOk();
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<"nb of modes to recalculate : "<<NbDisp<<endl;
#endif
}
NbDisp++;
}
anIObj->SetRecomputeOk();
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<"nb of modes to recalculate : "<<NbDisp<<endl;
#endif
}
NbDisp++;
}
anIObj->SetRecomputeOk();
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<"nb of modes to recalculate : "<<NbDisp<<endl;
#endif
}
NbDisp++;
}
anIObj->SetRecomputeOk();
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<"nb of modes to recalculate : "<<NbDisp<<endl;
#endif
}
anIObj->Update(ITI.Value(),Standard_False);
NbDisp++;
}
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<"nb of modes to recalculate : "<<NbDisp<<endl;
#endif
anIObj->SetRecomputeOk();
anIObj->Update(ITI.Value(),Standard_False);
NbDisp++;
}
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<"nb of modes to recalculate : "<<NbDisp<<endl;
#endif
anIObj->SetRecomputeOk();
UpdateCurrentViewer();
}
else{
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<"Nothing Done : Opened Local Context"<<endl;
#endif
}
UpdateCurrentViewer();
}
else{
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<"Nothing Done : Opened Local Context"<<endl;
#endif
}
{
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<"Not Yet Implemented"<<endl;
#endif
}
const Standard_Boolean updateviewer)
{
if(!HasOpenedContext()) {
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<" Attempt to remove a selected shape with no opened local context"<<endl;
#endif
return;
const Standard_Boolean updateviewer)
{
if(!HasOpenedContext()) {
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<" Attempt to remove a selected ownr with no opened local context"<<endl;
#endif
return;
NewLocal->MainSelector()->UpdateConversion();
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<"\tOpen Local Context No "<<myCurLocalIndex<<endl;
if(UseDisplayedObjects){
cout<<"\t\tObjects from Neutral Point loaded"<<endl;
{
Standard_Boolean debugmode(Standard_False);
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
debugmode = Standard_True;
#endif
return;
if (myDrawer.IsNull()) {
myDrawer = new AIS_Drawer;
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout << "AIS_InteractiveObject::SetContext DRAWER NUL!" << endl;
#endif
}
// purpose:
//==================================================================
//unused
-/*#ifdef DEB
+/*#ifdef OCCT_DEBUG
static void FindLimits(const Adaptor3d_Curve& aCurve,
const Standard_Real aLimit,
gp_Pnt& P1,
Handle(AIS_Selection) Sel = AIS_Selection::Selection(mySelName.ToCString());
if(Sel.IsNull()) {
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<"\t\tAIS_LocalCOntext::FindSelectedOwnerFromShape : Selection "
<<mySelName<<" Nulle "<<endl;
#endif
Handle(AIS_Selection) Sel = AIS_Selection::Selection(mySelName.ToCString());
if(Sel.IsNull()) {
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout<<"\t\tAIS_LocalCOntext::FindSelectedOwnerFromShape : Selection "<<mySelName<<" Nulle "<<endl;
#endif
return EO;
case 0:{
try { OCC_CATCH_SIGNALS StdPrs_WFDeflectionShape::Add(aPrs,myshape,myDrawer); }
catch (Standard_Failure) {
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout << "AIS_Shape::Compute() failed"<< endl;
cout << "a Shape should be incorrect : No Compute can be maked on it "<< endl;
#endif
StdPrs_ShadedShape::Add(aPrs,myshape,myDrawer);
}
catch (Standard_Failure) {
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout << "AIS_Shape::Compute() in ShadingMode failed"<< endl;
#endif
StdPrs_WFShape::Add(aPrs,myshape,myDrawer);
Standard_Boolean isOwnHLRDeviationCoefficient = OwnHLRDeviationCoefficient(newcoeff,prevcoeff);
if (((Abs (newangle - prevangle) > Precision::Angular()) && isOwnHLRDeviationAngle) ||
((Abs (newcoeff - prevcoeff) > Precision::Confusion()) && isOwnHLRDeviationCoefficient)) {
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout << "AIS_Shape : compute"<<endl;
cout << "newangle : " << newangle << " # de " << "prevangl : " << prevangle << " OU "<<endl;
cout << "newcoeff : " << newcoeff << " # de " << "prevcoeff : " << prevcoeff << endl;
}
}
catch (Standard_Failure) {
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
cout <<"AIS_Shape::Compute(Proj) HLR Algorithm failed" << endl;
#endif
StdPrs_WFShape::Add(aPresentation,SH,myDrawer);
}
else
{
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
std::cout << "Texture " << theTextureFileName << " doesn't exist\n";
std::cout << "Using Texture 0 instead ...\n";
#endif
myAspect->SetTextureMap (myTexture);
if (!myTexture->IsDone())
{
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
std::cout << "An error occurred while building texture\n";
#endif
myAspect->SetTextureMapOff();
}
catch (Standard_Failure)
{
-#ifdef AIS_DEB
+#ifdef OCCT_DEBUG
std::cout << "AIS_TexturedShape::Compute() in ShadingMode failed \n";
#endif
StdPrs_WFShape::Add (thePrs, myshape, myDrawer);
if(Handle(AIS_InteractiveObject)::DownCast(anObj->Selectable()).IsNull())
return Standard_False;
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
Handle(SelectMgr_SelectableObject) aSelectableObject = anObj->Selectable() ;
return ((Handle(AIS_InteractiveObject)&) aSelectableObject)->Type()== myKind;
//#else
// else if (*ndgjac < 61) { nbpnt = 61;} Bug Uneven number
else {
nbpnts = 50;
-#if ADVAPP2VAR_DEB
+#ifdef OCCT_DEBUG
cout << "F(U, V) : Not enough points of discretization" << endl;
#endif
}
NDGJAC = Conditions.VJacDeg();
NCFLIM = Conditions.VLimit();
break;
- //#ifndef DEB
+ //#ifndef OCCT_DEBUG
//pkv f
case GeomAbs_NoneIso:
//pkv t
Standard_Real *EMXAPP = new Standard_Real[NBSESP];
Handle (TColStd_HArray2OfReal) HERRMOY =
new TColStd_HArray2OfReal(1,NBSESP,1,IDERIV+1);
- //#ifdef DEB
+ //#ifdef OCCT_DEBUG
//Standard_Real *ERRMOY =
//#endif
// (Standard_Real *) &HERRMOY->ChangeArray2()(HERRMOY ->LowerRow(),HERRMOY ->LowerCol());
#include <PLib_JacobiPolynomial.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_Boolean AdvApprox_Debug = 0;
{
// Standard_Real EpsPar = Precision::Confusion();
Standard_Integer IDIM, NUPIL,TheDeg;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer NDIMEN = TotalDimension;
#endif
Standard_Boolean isCut = Standard_False;
CoefficientArray.SetValue(j, Coefficients.Value(i));
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Test des derives par difference finis
Standard_Integer IORDRE = ContinuityOrder;
#include <AppDef_Variational.hxx>
static Standard_Boolean scal = 1;
-#ifdef DEB
extern Standard_Boolean AppBlend_GetContextSplineApprox();
extern Standard_Boolean AppBlend_GetContextApproxWithNoTgt();
-#endif
// modified by EAP (Edward AGAPOV) Fri Jan 4 2002, bug OCC9
// --- keep pipe parametrized like path
withderiv = F.Section(Lin->Point(1),tabAppP,tabAppV,tabP2d,tabV2d,
tabW,tabDW);
-#if DEB
-// SpApprox = AppBlend_GetContextSplineApprox();
if(AppBlend_GetContextApproxWithNoTgt()) withderiv = Standard_False;
-#endif
-
for (j=1; j<=NbPoles2d; j++) {
tabAppP2d(j) = tabP2d(j);
else {
withderiv = F.Section(Lin->Point(i),tabAppP,tabAppV,tabP2d,tabV2d,
tabW,tabDW);
-#if DEB
if(AppBlend_GetContextApproxWithNoTgt()) withderiv = Standard_False;
-#endif
for (j=1; j<=NbPoles2d; j++) {
tabAppP2d(j) = tabP2d(j);
withderiv = F.Section(Lin->Point(NbPoint),tabAppP,tabAppV,tabP2d,tabV2d,
tabW,tabDW);
-#if DEB
- if(AppBlend_GetContextApproxWithNoTgt()) withderiv = Standard_False;
-#endif
+ if(AppBlend_GetContextApproxWithNoTgt()) withderiv = Standard_False;
for (j=1; j<=NbPoles2d; j++) {
tabAppP2d(j) = tabP2d(j);
mytol3d = Max(TheTol3d, mytol3d);
mytol2d = Max(TheTol2d, mytol2d);
}
-#ifdef APPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << " Tolerances obtenues --> 3d : "<< mytol3d << endl;
cout << " --> 2d : "<< mytol2d << endl;
#endif
}
theapprox.Perform(multL);
theapprox.Error(mytol3d,mytol2d);
-#ifdef APPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << " Tolerances obtenues --> 3d : "<< mytol3d << endl;
cout << " --> 2d : "<< mytol2d << endl;
#endif
mytol3d = Variation.MaxError();
mytol2d = 0.;
-#ifdef APPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << " Tolerances obtenues --> 3d : "<< mytol3d << endl;
cout << " --> 2d : "<< mytol2d << endl;
#endif
Standard_Real x,y,z;
withderiv = F.Section(Lin->Point(iLin),tabAppP,tabAppV,tabP2d,tabV2d,
tabW,tabDW);
-#if DEB
if(AppBlend_GetContextApproxWithNoTgt()) withderiv = Standard_False;
-#endif
for (j=1; j<=NbPoles2d; j++) {
tabP2d(j).Coord(x,y);
}
// modified by EAP Thu Jan 3 15:45:27 2002 ___END___
}
-#ifdef APPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << " Tolerances obtenues --> 3d : "<< mytol3d << endl;
cout << " --> 2d : "<< mytol2d << endl;
#endif
F.Parameter(Lin->Point(Lin->NbPoints())),
tabVKnots->ChangeArray1()
);
-#ifdef APPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: AppBlend_AppSurf::Perform(), bad length of aParamSeq: " <<
aParamSeq.Length() << " instead of " << tabVKnots->Length() << endl;
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_OutOfRange
#define No_Standard_RangeError
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_OutOfRange
#define No_Standard_RangeError
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_OutOfRange
#define No_Standard_RangeError
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_OutOfRange
#define No_Standard_RangeError
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_OutOfRange
#define No_Standard_RangeError
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_OutOfRange
#define No_Standard_RangeError
#endif
Standard_Integer NbElmOld = InCurve->NbElements();
if(NbElmOld >= myMaxSegment) {iscut = Standard_False; return;}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer MaxDegree =
#endif
InCurve->Base()->WorkDegree();
Standard_Integer NbElm = NbElmOld;
TColStd_Array1OfReal NewKnots(NbElm + 1, myMaxSegment);
-#ifndef DEB
+#ifndef OCCT_DEBUG
GettingKnots(Ti, InCurve, InCurve->Base()->WorkDegree(), NbElm, NewKnots);
GettingKnots(Ti, InCurve, InCurve->Base()->WorkDegree() - 1, NbElm, NewKnots);
#else
#include <AppParCurves_ConstraintCouple.hxx>
#include Approx_BSpParLeastSquareOfMyBSplGradient_hxx
-#if defined( DEB ) && defined( DRAW ) && !defined( WNT )
+#if defined(OCCT_DEBUG) && defined( DRAW ) && !defined( WNT )
static Standard_Boolean mydebug = Standard_False;
void Approx_BSplComputeLine::Perform(const MultiLine& Line)
{
-#if defined( DEB ) && defined( DRAW ) && !defined( WNT )
+#if defined(OCCT_DEBUG) && defined( DRAW ) && !defined( WNT )
if (mydebug) DUMP(Line);
#endif
}
}
-#if defined( DEB ) && defined( DRAW ) && !defined( WNT )
+#if defined(OCCT_DEBUG) && defined( DRAW ) && !defined( WNT )
if (mydebug) DUMP(TheMultiBSpCurve);
#endif
#include <stdio.h>
-#ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_Boolean mydebug = Standard_False;
#include <Geom_BezierCurve.hxx>
void Approx_ComputeLine::Perform(const MultiLine& Line)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (mydebug) DUMP(Line);
#endif
if (!myIsClear)
TheMultiCurve = AppParCurves_MultiCurve();
alldone = Compute(Line, myfirstpt, mylastpt, TheParam, thetol3d, thetol2d);
if(!alldone && TheMultiCurve.NbCurves() > 0) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (mydebug) DUMP(TheMultiCurve);
#endif
myMultiCurves.Append(TheMultiCurve);
myMultiCurves.Clear();
return;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (mydebug) DUMP(TheMultiCurve);
#endif
myMultiCurves.Append(TheMultiCurve);
myMultiCurves.Clear();
return;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (mydebug) DUMP(TheMultiCurve);
#endif
myMultiCurves.Append(TheMultiCurve);
if (TheTol3d <= mytol3d && TheTol2d <= mytol2d) {
// Stockage de la multicurve approximee.
tolreached = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (mydebug) DUMP(mySCU);
#endif
myMultiCurves.Append(mySCU);
gp_Pnt P1, P2;
gp_Pnt2d P12d, P22d;
Standard_Boolean Tangent1, Tangent2, mydone= Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean Parallel;
#endif
Standard_Integer myfirstpt = firstpt, mylastpt = lastpt;
if (nbp == 2) {
// S il n y a que 2 points, on verifie quand meme que les tangentes sont
// alignees.
-#ifdef DEB
+#ifdef OCCT_DEBUG
Parallel = Standard_True;
#endif
if (Tangent1) {
gp_Vec PVec(tabP1(i), tabP2(i));
V13d = tabV1(i);
if (!PVec.IsParallel(V13d, Precision::Angular())) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Parallel = Standard_False;
#endif
break;
gp_Vec2d PVec2d(tabP12d(i), tabP22d(i));
V12d = tabV12d(i);
if (!PVec2d.IsParallel(V12d, Precision::Angular())) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Parallel = Standard_False;
#endif
break;
gp_Vec PVec(tabP1(i), tabP2(i));
V23d = tabV2(i);
if (!PVec.IsParallel(V23d, Precision::Angular())) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Parallel = Standard_False;
#endif
break;
gp_Vec2d PVec2d(tabP12d(i), tabP22d(i));
V22d = tabV22d(i);
if (!PVec2d.IsParallel(V22d, Precision::Angular())) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Parallel = Standard_False;
#endif
break;
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (!Parallel) {
if (mydebug) cout <<"droite mais tangentes pas vraiment paralleles!!"<< endl;
}
mydone = Standard_True;
// Stockage de la multicurve approximee.
tolreached = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (mydebug) DUMP(mySCU);
#endif
myMultiCurves.Append(mySCU);
// Stockage de la multicurve approximee.
tolreached = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (mydebug) DUMP(mySCU);
#endif
myMultiCurves.Append(mySCU);
#include <CPnts_AbscissaPoint.hxx>
#include <Approx_CurvlinFunc.hxx>
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
#include <OSD_Timer.hxx>
static OSD_Chronometer chr_total, chr_init, chr_approx;
const Standard_Integer MaxDegree,
const Standard_Integer MaxSegments)
{
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
t_total = t_init = t_approx = t_uparam = 0;
uparam_count = 0;
InitChron(chr_total);
Handle(TColStd_HArray1OfReal) ThreeDTol = new TColStd_HArray1OfReal(1,Num3DSS);
ThreeDTol->Init(Tol);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
InitChron(chr_init);
#endif
Handle(Approx_CurvlinFunc) fonct = new Approx_CurvlinFunc(C3D, Tol/10);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
ResultChron(chr_init, t_init);
#endif
fonct->Intervals(CutPnts_C3,GeomAbs_C3);
AdvApprox_PrefAndRec CutTool(CutPnts_C2,CutPnts_C3);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
InitChron(chr_approx);
#endif
MaxDegree, MaxSegments,
evC, CutTool);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
ResultChron(chr_approx, t_approx);
#endif
}
myMaxError3d = aApprox.MaxError(3,1);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
ResultChron(chr_total, t_total);
cout<<" total reparametrization time = "<<t_total<<endl;
const Standard_Integer MaxDegree,
const Standard_Integer MaxSegments)
{
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
t_total = t_init = t_approx = t_uparam = 0;
uparam_count = 0;
InitChron(chr_total);
Handle(TColStd_HArray1OfReal) ThreeDTol = new TColStd_HArray1OfReal(1,Num3DSS);
ThreeDTol->Init(Tol/2.);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
InitChron(chr_init);
#endif
Handle(Approx_CurvlinFunc) fonct = new Approx_CurvlinFunc(C2D, Surf, Tol/20);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
ResultChron(chr_init, t_init);
#endif
fonct->Intervals(CutPnts_C3,GeomAbs_C3);
AdvApprox_PrefAndRec CutTool(CutPnts_C2,CutPnts_C3);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
InitChron(chr_approx);
#endif
MaxDegree, MaxSegments,
evCOnS, CutTool);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
ResultChron(chr_approx, t_approx);
#endif
myMaxError2d1 = Max (aApprox.MaxError(1,1),aApprox.MaxError(1,2));
myMaxError3d = aApprox.MaxError(3,1);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
ResultChron(chr_total, t_total);
cout<<" total reparametrization time = "<<t_total<<endl;
{
Standard_Integer i;
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
t_total = t_init = t_approx = t_uparam = 0;
uparam_count = 0;
InitChron(chr_total);
Handle(TColStd_HArray1OfReal) ThreeDTol = new TColStd_HArray1OfReal(1,Num3DSS);
ThreeDTol->Init(Tol/2);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
InitChron(chr_init);
#endif
Handle(Approx_CurvlinFunc) fonct = new Approx_CurvlinFunc(C2D1, C2D2, Surf1, Surf2, Tol/20);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
ResultChron(chr_init, t_init);
#endif
fonct->Intervals(CutPnts_C3,GeomAbs_C3);
AdvApprox_PrefAndRec CutTool(CutPnts_C2,CutPnts_C3);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
InitChron(chr_approx);
#endif
MaxDegree, MaxSegments,
evCOn2S, CutTool);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
ResultChron(chr_approx, t_approx);
#endif
myMaxError2d2 = Max (aApprox.MaxError(1,3),aApprox.MaxError(1,4));
myMaxError3d = aApprox.MaxError(3,1);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
ResultChron(chr_total, t_total);
cout<<" total reparametrization time = "<<t_total<<endl;
TolV = Tol / (4.*Max_dS_dv);
TolW = Tol / (4.*Max_dS_dw);
-#ifdef APPROX_DEB
+#ifdef OCCT_DEBUG
cout << "TolV = " << TolV << endl;
cout << "TolW = " << TolW << endl;
#endif
#include <GCPnts_AbscissaPoint.hxx>
#include <Precision.hxx>
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
#include <OSD_Timer.hxx>
static OSD_Chronometer chr_uparam;
Standard_EXPORT Standard_Integer uparam_count;
Standard_Real deltaS, base, U, Length;
Standard_Integer NbInt, NInterval, i;
Handle(TColStd_HArray1OfReal) InitUArray, InitSArray;
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
InitChron(chr_uparam);
#endif
if(S < 0 || S > 1) Standard_ConstructionError::Raise("Approx_CurvlinFunc::GetUParameter");
const_cast<Approx_CurvlinFunc*>(this)->myPrevS = S;
const_cast<Approx_CurvlinFunc*>(this)->myPrevU = U;
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
ResultChron(chr_uparam, t_uparam);
uparam_count++;
#endif
#include <BSplCLib.hxx>
#include <PLib.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
static void DEBUG(const AppParCurves_MultiCurve& MC) {
Standard_Integer i, j;
Standard_Integer nbcu = MC.NbCurves();
Standard_Integer nbcu = TheSeq.Length();
AppParCurves_MultiCurve CU;
Standard_Integer nbpolesspl=0, nbknots=0;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean debug = Standard_False;
#endif
mySpline = AppParCurves_MultiBSpCurve(tabMU, TheKnots, TheMults);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(debug) DEBUG(mySpline);
#endif
#include <Precision.hxx>
#include <Extrema_ExtPC.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#ifdef DRAW
#include <DrawTrSurf.hxx>
#endif
Standard_Integer extrap_mode[2] ;
extrap_mode[0] = extrap_mode[1] = 3;
Standard_Integer i;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Voir) {
cout<<endl;
cout<<"Control the change of variable : "<<endl;
if(temp >= glis) glis = temp;
}
dglis = sqrt(dglis);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( Voir) {
cout<<"shift of parameter to the imposed points : "<<glis<<endl;
cout<<"shift distance at the imposed points : "<<dglis<<endl;
if(temp >= dglis) dglis = temp;
}
dglis = sqrt(dglis);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Voir)
cout<<"distance de glissement en milieu d intervals : "<<dglis<<endl;
#endif
if(temp > d2) d2 = temp;
}
tol = sqrt(d2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Voir)
cout<<"distance max on "<<nn<<" points : "<<tol<<endl<<endl;
#endif
//Take a multiple of the sample pof CheckShape,
//at least the control points will be correct. No comment!!!
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer nbcoups = 0;
#endif
if(!projok)
{
//Projector
-#ifdef APPROX_DEB
+#ifdef OCCT_DEBUG
// JAG
cout << "Projection not done" << endl;
#endif
if(!extrok) { // If not already SameP and tangent to mill, abandon.
mySameParameter = Standard_False;
-#ifdef APPROX_DEB
+#ifdef OCCT_DEBUG
cout<<"SameParameter problem : zero tangent to extremities"<<endl;
#endif
return;
pcons[count] = lcons;
pc3d[count] = lc3d;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (AffichFw) {
char Name[17];
Name[0]='\0';
}
//-------------------------------------------
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (AffichFw) {
nbcoups ++;
char Name[17];
}
}
else {
-#ifdef APPROX_DEB
+#ifdef OCCT_DEBUG
// JAG
cout << "Projection not done" << endl;
#endif
if (Precision::IsInfinite(algtol)) {
mySameParameter = Standard_False;
-#ifdef APPROX_DEB
+#ifdef OCCT_DEBUG
cout<<"SameParameter problem : function of interpolation of parametration at mills !!"<<endl;
#endif
return;
if(interpolok) {
Standard_Real besttol = sqrt(besttol2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Voir) {
if(algtol > besttol){
cout<<"SameParameter : Tol can't be reached before approx"<<endl;
if(!interpolok)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Voir)
cout<<"SameParameter : Not enough points, enrich"<<endl;
#endif
}
}
else {
-#ifdef APPROX_DEB
+#ifdef OCCT_DEBUG
// JAG
cout << "Projection not done" << endl;
#endif
#include <TopTools_IndexedMapOfShape.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepTool_GetcontextNOSEW();
#endif
TopoDS_Shape& myShape);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_IMPORT Standard_Integer TopOpeBRepTool_BOOOPE_CHECK_DEB;
#endif
HDS->ChangeDS().Init();
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopOpeBRepDS_SettraceSPSX_HDS(HDS);
#endif
}
}
myBuilderCanWork = (esp || tede) ;
-#ifdef BREPALGO_DEB
+#ifdef OCCT_DEBUG
if (!esp) cout<<"BRepAlgo_BooleanOperation(DEB) some edges not SameParameter"<<endl;
#endif
if (!myBuilderCanWork) return;
TopTools_ListOfShape theOldShell, theNewShell;
Standard_Boolean modif =Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean nosew = TopOpeBRepTool_GetcontextNOSEW();
if (nosew) sewing = Standard_False;
#endif
// It is necessary to change Interferences => take the complement
iC = myHB->GetDSCurveFromSectEdge(Edge);
if (!iC) {
-#if BREPALGO_DEB
+#ifdef OCCT_DEBUG
cout << "Warning DSAccess: Modifications of Edge are not implemented" << endl;
#endif
}
TopExp_Explorer exp(DSFace, TopAbs_EDGE), exp2;
for(; exp.More(); exp.Next()) {
const TopoDS_Shape& Edge = exp.Current();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iEdge2 = DS.Shape(Edge, FindKeep);
// Standard_Integer iEdge3 = DS.Shape(Edge);
#endif
continue;
exp2.Init(Edge, TopAbs_VERTEX);
for(; exp2.More(); exp2.Next()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iEdge5 = DS.Shape(Vertex, FindKeep);
// Standard_Integer iEdge4 = DS.Shape(Vertex);
// Standard_Integer iEdge6 = DS.Shape(exp2.Current(), FindKeep);
if(!DS.HasGeometry(Edge)) {
const TopTools_ListOfShape& los = DS.ShapeSameDomain(Edge);
if(los.IsEmpty()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iEdge = DS.Shape(Edge);
#endif
DS.ChangeKeepShape(Edge, FindKeep);
TopOpeBRepDS_Kind pvk;
Standard_Integer ipv, iMother = C.Mother(), igoodC = iCurve, comp = 0;
if(iMother) igoodC = iMother;
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
TopOpeBRepDS_PointIterator PII = myHDS->CurvePoints(igoodC);
TopOpeBRepDS_PointIterator& PIt = PII; // skl : I change "M_PI" to "PIt"
//#else
myBlockB.MakeBlock(SS);
BRep_Builder WireB;
for(myBlockB.InitBlock();myBlockB.MoreBlock();myBlockB.NextBlock()) {
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
TopOpeBRepBuild_BlockIterator BI = myBlockB.BlockIterator();
//#else
// TopOpeBRepBuild_BlockIterator& BI = myBlockB.BlockIterator();
#ifdef DRAW
#include <DBRep.hxx>
#endif
-#ifdef DEBUG_ALGO
+#ifdef OCCT_DEBUG_ALGO
Standard_Boolean AffichLoop = Standard_False;
Standard_Integer NbLoops = 0;
Standard_Integer NbWires = 1;
}
if (OnStart && OnEnd) {
if (!VB[0].IsSame(VB[1])) {
-#ifdef DEBUG_ALGO
+#ifdef OCCT_DEBUG_ALGO
if (AffichLoop)
cout <<"Two different vertices on the closing vertex"<<endl;
#endif
{
TopTools_ListIteratorOfListOfShape itl;
NE.Nullify();
-#ifdef DEBUG_ALGO
+#ifdef OCCT_DEBUG_ALGO
if (AffichLoop) {
if ( LE.Extent() > 2) {
cout <<"vertex on more than 2 edges in a face."<<endl;
TopoDS_Vertex V1,V2;
Standard_Boolean YaCouture = Standard_False;
-#ifdef DEBUG_ALGO
+#ifdef OCCT_DEBUG_ALGO
if (AffichLoop) {
cout <<"NewLoop"<<endl;
NbLoops++;
NW.Closed (Standard_True);
myNewWires.Append (NW);
}
-#ifdef DEBUG_ALGO
+#ifdef OCCT_DEBUG_ALGO
else {
cout <<"BRepAlgo_Loop: Open Wire"<<endl;
if (AffichLoop)
#include <Geom2d_BSplineCurve.hxx>
#include <TopTools_ListIteratorOfListOfShape.hxx>
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
#include <OSD_Timer.hxx>
OSD_Chronometer chr_total, chr_init, chr_approx, chr_booltool;
void BRepAlgo_NormalProjection::Build()
{
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
Standard_Integer init_count = 0, approx_count = 0, booltool_count = 0;
t_total = 0;
t_init = 0;
TolU = hsur->UResolution(myTol3d)/20;
TolV = hsur->VResolution(myTol3d)/20;
// Projection
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
InitChron(chr_init);
#endif
Projector =
ProjLib_CompProjectedCurve(hsur, hcur, TolU, TolV, myMaxDist);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
ResultChron(chr_init,t_init);
init_count++;
#endif
for(k = 1; k <= Projector.NbCurves(); k++){
if(Projector.IsSinglePnt(k, P2d)){
-#ifdef BREPALGO_DEB
+#ifdef OCCT_DEBUG
cout << "Projection of edge "<<i<<" on face "<<j;
cout << " is punctual"<<endl<<endl;
#endif
/**************************************************************/
if (Projector.IsUIso(k, UIso)) {
-#ifdef BREPALGO_DEB
+#ifdef OCCT_DEBUG
cout << "Projection of edge "<<i<<" on face "<<j;
cout << " is U-isoparametric"<<endl<<endl;
#endif
Only3d = Standard_True;
}
else if (Projector.IsVIso(k, VIso)) {
-#ifdef BREPALGO_DEB
+#ifdef OCCT_DEBUG
cout << "Projection of edge "<<i<<" on face "<<j;
cout << " is V-isoparametric"<<endl<<endl;
#endif
BB.UpdateVertex(TopExp::LastVertex(TopoDS::Edge(prj)),myTol3d);
}
else {
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
InitChron(chr_approx);
#endif
Approx_CurveOnSurface appr(HPCur, hsur, Udeb, Ufin, myTol3d,
myContinuity, myMaxDegree, myMaxSeg,
Only3d, Only2d);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
ResultChron(chr_approx,t_approx);
approx_count++;
}
}
if (Degenerated) {
-#ifdef BREPALGO_DEB
+#ifdef OCCT_DEBUG
cout << "Projection of edge "<<i<<" on face "<<j;
cout << " is degenerated "<<endl<<endl;
#endif
if(myFaceBounds) {
// Trimming edges by face bounds
// if the solution is degenerated, use of BoolTool is avoided
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
InitChron(chr_booltool);
#endif
if(!Degenerated){
LS = HB->Splits(prj, TopAbs_IN);
Iter.Initialize(LS);
if(Iter.More()) {
-#ifdef BREPALGO_DEB
+#ifdef OCCT_DEBUG
cout << " BooleanOperations :" << Iter.More()<<" solutions " << endl;
#endif
for(; Iter.More(); Iter.Next()) {
}
}
else {
-#ifdef BREPALGO_DEB
+#ifdef OCCT_DEBUG
cout << " BooleanOperations : no solution " << endl;
#endif
myAncestorMap.Bind(prj, Edges->Value(i));
myCorresp.Bind(prj, Faces->Value(j));
}
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
ResultChron(chr_booltool,t_booltool);
booltool_count++;
#endif
myIsDone = Standard_True;
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
ResultChron(chr_total,t_total);
cout<<"Build - Total time : "<<t_total<<" includes:" <<endl;
}
if (NbSub == 0)
{
-#ifdef BREPALGO_DEB
+#ifdef OCCT_DEBUG
cout << "No subhape in shape!" << endl;
#endif
SS = TopoDS_Shape();
// (4) Insertion of the point if the calculation seems long.
if ((!Trouve)&&(rsnld.NbIterations()>3)) {
-#ifdef BREPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << "Evaluation in t = " << Param << "given" << endl;
rsnld.Dump(cout);
#endif
#include <gp_Vec2d.hxx>
#include <gp_Vec.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TColStd_Array1OfInteger.hxx>
#include <TColStd_Array1OfReal.hxx>
#include <TColgp_Array1OfPnt2d.hxx>
static Standard_Integer IndexOfSection = 0;
extern Standard_Boolean Blend_GettraceDRAWSECT();
-#ifdef DEB_BBPP_N_TRDERIV
+#ifdef OCCT_DEBUG_BBPP_N_TRDERIV
//-----------------------------------------------------
// For debug : visualisation of the section
static Standard_Boolean BBPP(const Standard_Real param,
if (State != Blend_OK) {
return;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(param, Func);
}
while (!Arrive) {
Standard_Boolean bonpoint = 1;
-#ifdef DEB_BBPP_N_TRDERIV
+#ifdef OCCT_DEBUG_BBPP_N_TRDERIV
//debdebdebdebdebdeb
Func.Set(param);
rsnld.Perform(Func, parinit, infbound, supbound);
}
else{
// reframing failed. Leave with PointsConfondus
-#ifdef BREPBLEND_DEB
+#ifdef OCCT_DEBUG
cout<<"reframing failed"<<endl;
#endif
State = Blend_SamePoints;
switch (State) {
case Blend_OK :
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(param, Func);
}
previousP.ParameterOnC2(),
previousP.Parameter(), tolesp);
Arrive = Standard_True;
-#ifdef BREPBLEND_DEB
+#ifdef OCCT_DEBUG
if (line->NbPoints()>=2) {
// Show that there is a stop during processing
cout<<"No more advancement in the processing"<<endl;
case Blend_StepTooSmall :
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(param,Func);
}
case Blend_OnRst1 :
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(param, Func);
}
case Blend_OnRst2 :
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(param, Func);
}
case Blend_OnRst12 :
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(param, Func);
}
case Blend_SamePoints :
{
// Stop
-#ifdef BREPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << " Mixed points in the processing" << endl;
#endif
Extrst1.SetValue(previousP.PointOnC1(),
math_FunctionSetRoot rsnld(Finv, toler, 30);
rsnld.Perform(Finv, Solinv, infb, supb);
if (!rsnld.IsDone()) {
-#ifdef BREPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << "RSNLD not done "<< endl << endl;
#endif
return Standard_False;
math_FunctionSetRoot rsnld(Finv, toler, 30);
rsnld.Perform(Finv, Solinv, infb, supb);
if (!rsnld.IsDone()) {
-#ifdef BREPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << "RSNLD not done "<< endl << endl;
#endif
return Standard_False;
math_FunctionSetRoot rsnld(FinvP, toler, 30);
rsnld.Perform(FinvP, Solinv, infb, supb);
if (!rsnld.IsDone()) {
-#ifdef BREPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << "RSNLD not done "<< endl << endl;
#endif
return Standard_False;
math_FunctionSetRoot rsnld(FinvP, toler, 30);
rsnld.Perform(FinvP, Solinv, infb, supb);
if (!rsnld.IsDone()) {
-#ifdef BREPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << "RSNLD not done "<< endl << endl;
#endif
return Standard_False;
norm = ncrossns.Magnitude();
if (norm < Eps) {
norm = 1; // Not enough, but it is not necessary to stop
-#if BREPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << " SurfRstConstRad : Singular Surface " << endl;
#endif
}
norm = ncrossns.Magnitude();
if (norm < Eps) {
norm = 1; // Not enough, but it is not necessary to stop
-#if BREPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << " SurfRstEvolRad : Surface single " << endl;
#endif
}
#include <gp_Vec2d.hxx>
#include <gp_Vec.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TColStd_Array1OfInteger.hxx>
#include <TColStd_Array1OfReal.hxx>
#include <TColgp_Array1OfPnt2d.hxx>
#endif
static Standard_Integer IndexOfSection = 0;
extern Standard_Boolean Blend_GettraceDRAWSECT();
-#ifdef DEB_BBPP_N_TRDERIV
+#ifdef OCCT_DEBUG_BBPP_N_TRDERIV
// for debug : visualisation of the section
static Standard_Boolean BBPP(const Standard_Real param,
Blend_SurfRstFunction& Func,
if (State!=Blend_OK) {
return;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(param,Func);
}
while (!Arrive) {
Standard_Boolean bonpoint = 1;
-#ifdef DEB_BBPP_N_TRDERIV
+#ifdef OCCT_DEBUG_BBPP_N_TRDERIV
//debdebdebdebdebdeb
Func.Set(param);
rsnld.Perform(Func,parinit,infbound,supbound);
}
else{
// Failed reframing. Leave with PointsConfondus
-#if BREPBLEND_DEB
+#ifdef OCCT_DEBUG
cout<<"SurfRstLineBuilder : failed reframing"<<endl;
#endif
State = Blend_SamePoints;
switch (State) {
case Blend_OK :
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(param,Func);
}
Arrive = Standard_True;
if (line->NbPoints()>=2) {
// Indicate that one stops during the processing
-#if BREPBLEND_DEB
+#ifdef OCCT_DEBUG
cout<<"SurfRstLineBuilder : No advancement in the processing"<<endl;
#endif
}
case Blend_StepTooSmall :
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(param,Func);
}
case Blend_OnRst1 :
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(param,Func);
}
case Blend_OnRst2 :
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(param,Func);
}
case Blend_OnRst12 :
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(param,Func);
}
case Blend_SamePoints :
{
// Stop
-#if BREPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << "SurfRstLineBuilder Points mixed in the processing" << endl;
#endif
previousP.ParametersOnS(U,V);
rsnld.Perform(FinvC,Solinv,infb,supb);
if (!rsnld.IsDone()) {
-#if BREPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << "SurfRstLineBuilder : RSNLD not done "<< endl << endl;
#endif
}
rsnld.Perform(FinvC,Solinv,infb,supb);
if (!rsnld.IsDone()) {
-#if BREPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << "SurfRstLineBuilder : RSNLD not done "<< endl << endl;
#endif
}
math_FunctionSetRoot rsnld(Finv,toler,30);
rsnld.Perform(Finv,Solinv,infb,supb);
if (!rsnld.IsDone()) {
-#if BREPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << "SurfRstLineBuilder :RSNLD not done "<< endl;
#endif
return Standard_False;
math_FunctionSetRoot rsnld(FinvP,toler,30);
rsnld.Perform(FinvP,Solinv,infb,supb);
if (!rsnld.IsDone()) {
-#if BREPBLEND_DEB
+#ifdef OCCT_DEBUG
cout << "SurfRstLineBuilder :RSNLD not done "<< endl;
#endif
return Standard_False;
#include <TopTools_DataMapOfShapeShape.hxx>
#include <TopTools_MapOfShape.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <stdio.h>
Standard_Boolean Affich;
#endif
}
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
//=======================================================================
//function : DEBControl
//purpose :
Update (myMod,myGen,ModBack,GenBack,SI,MKS,TopAbs_EDGE);
Update (myMod,myGen,ModBack,GenBack,SI,MKS,TopAbs_VERTEX);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Affich) {
DEBControl (myGen);
DEBControl (myMod);
else if (itl.More()) itl.Next();
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Affich) {
DEBControl (MG);
}
RequestedFirst,RequestedLast,NewCurvePtr);
}
catch (Standard_Failure) {
-#ifdef BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
cout << "Exception in BRepBuilderAPI_Sewing::SameRange: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
BRepLib::SameParameter(edge);
}
catch (Standard_Failure) {
-#ifdef BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
cout << "Exception in BRepBuilderAPI_Sewing::SameParameter: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
//purpose :
//=======================================================================
-#ifdef BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
#include <OSD_Timer.hxx>
#endif
{
const Standard_Integer aNumberOfStages = myAnalysis + myCutting + mySewing + 2;
Message_ProgressSentry aPS (thePI, "Sewing", 0, aNumberOfStages, 1);
-#ifdef BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
Standard_Real t_total = 0., t_analysis = 0., t_assembling = 0., t_cutting = 0., t_merging = 0.;
OSD_Chronometer chr_total, chr_local;
chr_total.Reset();
// face analysis
if (myAnalysis)
{
-#if BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
cout << "Begin face analysis..." << endl;
chr_local.Reset();
chr_local.Start();
if (!aPS.More())
return;
aPS.Next();
-#if BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
chr_local.Stop();
chr_local.Show(t_analysis);
cout << "Face analysis finished after " << t_analysis << " s" << endl;
if (myBoundFaces.Extent())
{
-#if BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
cout << "Begin vertices assembling..." << endl;
chr_local.Reset();
chr_local.Start();
if (!aPS.More())
return;
aPS.Next();
-#if BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
chr_local.Stop();
chr_local.Show(t_assembling);
cout << "Vertices assembling finished after " << t_assembling << " s" << endl;
#endif
if (myCutting)
{
-#if BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
cout << "Begin cutting..." << endl;
chr_local.Reset();
chr_local.Start();
if (!aPS.More())
return;
aPS.Next();
-#if BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
chr_local.Stop();
chr_local.Show(t_cutting);
cout << "Cutting finished after " << t_cutting << " s" << endl;
#endif
}
-#if BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
cout << "Begin merging..." << endl;
chr_local.Reset();
chr_local.Start();
if (!aPS.More())
return;
aPS.Next();
-#if BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
chr_local.Stop();
chr_local.Show(t_merging);
cout << "Merging finished after " << t_merging << " s" << endl;
if (mySewing)
{
-#if BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
cout << "Creating sewed shape..." << endl;
#endif
// examine the multiple edges if any and process sameparameter for edges if necessary
mySewedShape.Nullify();
return;
}
-#if BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
cout << "Sewed shape created" << endl;
#endif
}
return;
}
}
-#if BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
chr_total.Stop();
chr_total.Show(t_total);
cout << "Sewing finished!" << endl;
Standard_Real first, last;
Handle(Geom_Curve) c3d = BRep_Tool::Curve(edge,first,last);
if (c3d.IsNull()) {
-#ifdef BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: Possibly small edge can be sewed: No 3D curve" << endl;
#endif
}
isSmall = (length <= MinTolerance());
}
catch (Standard_Failure) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
cout << "Warning: Possibly small edge can be sewed: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
// Replace small edge
if (isSmall) {
-#ifdef BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: Small edge made degenerated by FaceAnalysis" << endl;
#endif
nbSmall++;
// Remove small face
if (nbSmall == nbEdges) {
-#ifdef BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: Small face removed by FaceAnalysis" << endl;
#endif
myLittleFace.Add(face);
}
}
Standard_Integer nbNodes = NodeVertices.Extent();
-#ifdef BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
cout << "Glueing " << nbNodes << " nodes..." << endl;
#endif
// Merge nearest nodes
}
// Glue vertices
if (nbVert) {
-#ifdef BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
cout << "Assemble " << nbVert << " vertices on faces..." << endl;
#endif
while (GlueVertices(myVertexNode,myNodeSections,myBoundFaces,myTolerance, thePI));
return;
aPS.Next();
if (nbVertFree) {
-#ifdef BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
cout << "Assemble " << nbVertFree << " vertices on floating edges..." << endl;
#endif
while (GlueVertices(myVertexNodeFree,myNodeSections,myBoundFaces,myTolerance, thePI));
myBoundSections.Bind(bound,listSections);
}
}
-#ifdef BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
cout << "From " << nbBounds << " bounds " << myBoundSections.Extent()
<< " were cut into " << mySectionBound.Extent() << " sections" << endl;
#endif
}
catch (Standard_Failure) {
worktol = MinTolerance();
-#ifdef BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
cout << "Exception in BRepBuilderAPI_Sewing::ProjectPointsOnCurve: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
}
//}
/*catch (Standard_Failure) {
- #ifdef DEB
+ #ifdef OCCT_DEBUG
cout << "Exception in CreateSections: segment [" << par1 << "," << par2 << "]: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
BRepLib::SameParameter(sec, BRep_Tool::Tolerance(sec));
}
catch (Standard_Failure) {
-#ifdef BREPBUILDERAPI_DEB
+#ifdef OCCT_DEBUG
cout << "Fail: BRepBuilderAPI_Sewing::SameParameterShape exception in BRepLib::SameParameter" << endl;
#endif
continue;
}
catch(Standard_Failure)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
cout<<"BRepCheck_Analyzer : ";
Standard_Failure::Caught()->Print(cout);
cout<<endl;
}
catch(Standard_Failure)
{
-#ifdef BREPCHECK_DEB
+#ifdef OCCT_DEBUG
cout<<"BRepCheck_Analyzer : ";
Standard_Failure::Caught()->Print(cout);
cout<<endl;
}
catch(Standard_Failure)
{
-#ifdef BREPCHECK_DEB
+#ifdef OCCT_DEBUG
cout<<"BRepCheck_Analyzer : ";
Standard_Failure::Caught()->Print(cout);
cout<<endl;
}
catch(Standard_Failure)
{
-#ifdef BREPCHECK_DEB
+#ifdef OCCT_DEBUG
cout<<"BRepCheck_Analyzer : ";
Standard_Failure::Caught()->Print(cout);
cout<<endl;
}
catch(Standard_Failure)
{
-#ifdef BREPCHECK_DEB
+#ifdef OCCT_DEBUG
cout<<"BRepCheck_Analyzer : ";
Standard_Failure::Caught()->Print(cout);
cout<<endl;
}
catch(Standard_Failure)
{
-#ifdef BREPCHECK_DEB
+#ifdef OCCT_DEBUG
cout<<"BRepCheck_Analyzer : ";
Standard_Failure::Caught()->Print(cout);
cout<<endl;
}
catch(Standard_Failure)
{
-#ifdef BREPCHECK_DEB
+#ifdef OCCT_DEBUG
cout<<"BRepCheck_Analyzer : ";
Standard_Failure::Caught()->Print(cout);
cout<<endl;
//function : PrintProblematicPoint
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void PrintProblematicPoint(const gp_Pnt& problematic_point,
const Standard_Real Error,
const Standard_Real Tol)
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (BRepCheck_Trace(0) > 1) {
TopTools_DataMapIteratorOfDataMapOfShapeInteger itt(MapOfShapeOrientation);
Standard_Integer upper = MapOfShapeOrientation.NbBuckets();
// orf = (TopAbs_Orientation)MapOfShapeOrientation.Find(Fref);
Fref.Orientation(orf);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (BRepCheck_Trace(0) > 3) {
cout << "Fref : " ;
PrintShape(Fref, MapOfShapeOrientation.NbBuckets());
// orf = (TopAbs_Orientation)MapOfShapeOrientation.Find(Fcur);
Fcur.Orientation(orf);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (BRepCheck_Trace(0) > 3) {
cout << " Fcur : " ;
PrintShape(Fcur, MapOfShapeOrientation.NbBuckets());
BRepCheck::Add(myMap(myShape), myOstat);
}
// quit, otherwise there is a risk of taking too much time.
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (BRepCheck_Trace(0) > 3) {
orf = (TopAbs_Orientation)MapOfShapeOrientation.Find(Fcur);
Fcur.Orientation(orf);
MapOfShapeOrientation(Fcur)=orf;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (BRepCheck_Trace(0) > 3) {
orf = (TopAbs_Orientation)MapOfShapeOrientation.Find(Fcur);
Fcur.Orientation(orf);
if (Dist < aTol3d)
return Standard_True;
-#ifdef BREPCHECK_DEB
+#ifdef OCCT_DEBUG
cout << endl;
cout << "--------Function IsDistanceIn3DTolerance(...)----------" << endl;
cout << "--- BRepCheck Wire: Closed3d -> Error" << endl;
const gp_Pnt2d& thePnt,
const gp_Pnt2d& thePntRef,
const Standard_Real aTol3d,
-#ifdef DEB
+#ifdef OCCT_DEBUG
const Standard_Boolean PrintWarnings = Standard_True)
#else
const Standard_Boolean = Standard_True)
if((dumin < dumax) && (dvmin < dvmax))
return Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(PrintWarnings)
{
cout << endl;
Standard_Real aTol2d = 2*Max( dumax, dvmax);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if((aTol2d <= 0.0) && (PrintWarnings))
{
cout<<"BRepCheck_Wire : UResolution and VResolution = 0.0 (Face too small ?)"<<endl;
if (Dist < aTol2d)
return Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(PrintWarnings)
{
cout << endl;
BRepCheck::Add(myMap(myShape),BRepCheck_SelfIntersectingWire);
}
delete [] tabDom;
-#ifdef BREPCHECK_DEB
+#ifdef OCCT_DEBUG
static Standard_Integer numpoint=0;
cout<<"point p"<<++numpoint<<" "<<P3d.X()<<" "<<P3d.Y()<<" "<<P3d.Z()<<endl;cout.flush();
#endif
}
else {
delete [] tabDom;
-#ifdef BREPCHECK_DEB
+#ifdef OCCT_DEBUG
cout<<"BRepCheck_NoCurveOnSurface or BRepCheck_InvalidRange"<<endl;cout.flush();
#endif
if(tabCur(j).IsNull()) {
//-- Check distance from edges to the curve joining
//-- the point of intersection with vertex (if exists)
if (localok == Standard_False && !CommonVertices.IsEmpty()) {
-#ifdef BREPCHECK_DEB
+#ifdef OCCT_DEBUG
cout << "\n------------------------------------------------------\n" <<endl;
cout << "\n--- BRepCheck Wire: AutoIntersection Phase1 -> Erreur \n" <<endl;
localok = Standard_False;
}
}
-#ifdef BREPCHECK_DEB
+#ifdef OCCT_DEBUG
if(localok) {
printf("--- BRepCheck Wire: AutoIntersection Phase2 -> Bon \n");
printf("--- distance Point Vertex : %10.7g (tol %10.7g)\n",distauvtxleplusproche,tolvtt);
if (Update) {
BRepCheck::Add(myMap(myShape),BRepCheck_SelfIntersectingWire);
}
-#ifdef BREPCHECK_DEB
+#ifdef OCCT_DEBUG
static Standard_Integer numpoint1=0;
cout<<"point p"<<++numpoint1<<" "<<P3d.X()<<" "<<P3d.Y()<<" "<<P3d.Z()<<endl;
cout.flush();
if (Update) {
BRepCheck::Add(myMap(myShape),BRepCheck_SelfIntersectingWire);
}
-#ifdef BREPCHECK_DEB
+#ifdef OCCT_DEBUG
static Standard_Integer numpoint1=0;
cout<<"point p"<<++numpoint1<<" "<<P3d.X()<<" "<<P3d.Y()<<" "<<P3d.Z()<<endl;
cout.flush();
IntCurveSurface_TransitionOnCurve tran = Intersector3d.Transition(i);
if (tran == IntCurveSurface_Tangent) {
-#ifdef BREPCLASS3D_DEB
+#ifdef OCCT_DEBUG
cout<<"*Problem ds BRepClass3d_SClassifier.cxx"<<endl;
#endif
continue; // ignore this point
}
// Modified by skv - Thu Sep 4 11:42:03 2003 OCC578 End
-#ifdef DEB
+#ifdef OCCT_DEBUG
//#################################################
SolidExplorer.DumpSegment(P,L,parmin,State());
//#################################################
#define MARCHEPASSIUNESEULEFACE 0
-#ifdef DEB
+#ifdef OCCT_DEBUG
#define LBRCOMPT 0
#else
#define LBRCOMPT 0
if(NbFacesInSolid==0) {
_Par=0.0;
myReject=Standard_True;
-#if BREPCLASS3D_DEB
+#ifdef OCCT_DEBUG
cout<<"\nWARNING : BRepClass3d_SolidExplorer.cxx (Solid without face)"<<endl;
#endif
return 0;
myReject=Standard_False; //-- at least one face in the solid
}
-#if BREPCLASS3D_DEB
+#ifdef OCCT_DEBUG
if(myReject) {
cout<<"\nWARNING : BRepClass3d_SolidExplorer.cxx (Solid without face)"<<endl;
}
return(Standard_False);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopAbs_State.hxx>
#endif
const Standard_Real,
const TopAbs_State) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
#endif
}
#include <BRepFeat_Builder.hxx>
//modified by NIZNHY-PKV Thu Mar 21 17:30:29 2002 t
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean BRepFeat_GettraceFEAT();
#endif
void BRepFeat_Form::GlobalPerform ()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_Form::GlobalPerform ()" << endl;
#endif
if (!mySbOK || !myGSOK || !mySFOK || !mySUOK || !myGFOK ||
!mySkOK || !myPSOK) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Fields not initialized in BRepFeat_Form" << endl;
#endif
myStatusError = BRepFeat_NotInitialized;
TopTools_DataMapIteratorOfDataMapOfShapeShape itm;
if(myJustFeat && !myFuse) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Invalid option : myJustFeat + Cut" << endl;
#endif
myStatusError = BRepFeat_InvOption;
}
if (!exp.More()) {
FromInShape = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " From not in Shape" << endl;
#endif
break;
}
if (!exp.More()) {
UntilInShape = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Until not in Shape" << endl;
#endif
break;
//--- case of gluing
if (theOpe == 1) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Gluer" << endl;
#endif
Standard_Boolean Collage = Standard_True;
//--- if the gluing is always applicable
if (theOpe == 1) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " still Gluer" << endl;
#endif
theGlue.Perform();
UpdateDescendants(theGlue);
myNewEdges = theGlue.Edges();
myTgtEdges = theGlue.TgtEdges();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Gluer result" << endl;
#endif
Done();
//--- case without gluing + Tool with proper dimensions
if (theOpe == 2 && ChangeOpe && myJustGluer) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Gluer failure" << endl;
#endif
myJustGluer = Standard_False;
//--- case without gluing
if (theOpe == 2) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " No Gluer" << endl;
#endif
TopoDS_Shape theGShape = myGShape;
if (ChangeOpe) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Passage to topological operations" << endl;
#endif
}
// Case when no part of the tool is preserved
if (!KeepParts) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " No parts of tool kept" << endl;
#endif
myStatusError = BRepFeat_NoParts;
Standard_Boolean BRepFeat_Form::TransformShapeFU(const Standard_Integer flag)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
#endif
Standard_Boolean Trf = Standard_False;
TopExp_Explorer exp(shapefu, TopAbs_FACE);
if (!exp.More()) { // no faces... It is necessary to return an error
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " BRepFeat_Form::TransformShapeFU : invalid Shape" << endl;
#endif
return Trf;
myMap(fac).Append(fac);
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
if (Trf && (flag == 0)) cout << " TransformShapeFU From" << endl;
if (Trf && (flag == 1)) cout << " TransformShapeFU Until" << endl;
#include <BRepFeat.hxx>
#include <TopAbs.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean BRepFeat_GettraceFEAT();
#endif
const Standard_Boolean Modify)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeDPrism::Init" << endl;
#endif
myMap(exp.Current()).Append(exp.Current());
}
myAngle = Angle;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
if (myJustFeat) cout << " Just Feature" << endl;
if (myFuse) cout << " Fuse" << endl;
void BRepFeat_MakeDPrism::Add(const TopoDS_Edge& E,
const TopoDS_Face& F)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeDPrism::Add(Edge,face)" << endl;
#endif
void BRepFeat_MakeDPrism::Perform(const Standard_Real Height)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeDPrism::Perform(Height)" << endl;
#endif
void BRepFeat_MakeDPrism::Perform(const TopoDS_Shape& Until)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeDPrism::Perform(Until)" << endl;
#endif
void BRepFeat_MakeDPrism::Perform(const TopoDS_Shape& From,
const TopoDS_Shape& Until)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeDPrism::Perform(From,Until)" << endl;
#endif
void BRepFeat_MakeDPrism::PerformUntilEnd()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeDPrism::PerformUntilEnd()" << endl;
#endif
void BRepFeat_MakeDPrism::PerformFromEnd(const TopoDS_Shape& Until)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeDPrism::PerformFromEnd(From,Until)" << endl;
#endif
void BRepFeat_MakeDPrism::PerformThruAll()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeDPrism::PerformThruAll()" << endl;
#endif
void BRepFeat_MakeDPrism::PerformUntilHeight(const TopoDS_Shape& Until,
const Standard_Real Height)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeDPrism::PerformUntilHeight(Until,Height)" << endl;
#endif
//============================================================================
void BRepFeat_MakeDPrism::BossEdges (const Standard_Integer signature)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeDPrism::BossEdges (integer)" << endl;
#endif
// }
// Standard_Real Height = abs(2.*(parmax - parmin));
// return(2.*Height);
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
Standard_Real par = Max( Max( fabs(c[1] - c[0]), fabs(c[3] - c[2]) ), fabs(c[5] - c[4]) );
//#else
// Standard_Real par = Max( Max( abs(c[1] - c[0]), abs(c[3] - c[2]) ), abs(c[5] - c[4]) );
//#endif
-#ifdef BREPFEAT_DEB
+#ifdef OCCT_DEBUG
cout << "Height = > " << par << endl;
#endif
return par;
#include <BRepLib_MakeWire.hxx>
//#include <DbgTools.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean BRepFeat_GettraceFEAT();
extern Standard_Boolean BRepFeat_GettraceFEATRIB();
#endif
const Standard_Integer Mode,
const Standard_Boolean Modify)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeLinearForm::Init" << endl;
#endif
myFuse = Standard_False;
else // if(Mode == 1)
myFuse = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
if (myFuse) cout << " Fuse" << endl;
if (!myFuse) cout << " Cut" << endl;
if(!myDir1.IsEqual(nulldir, myTol, myTol)) {
Standard_Real ang = myDir1.Angle(myDir);
if(ang != M_PI) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Directions must be opposite" << endl;
#endif
myStatusError = BRepFeat_BadDirect;
else {
// Rib is centre in the middle of translation
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Rib is centre" << endl;
#endif
const gp_Vec& DirTranslation = (Direc + Direc1) * 0.5;
OnFirstEdge, OnLastEdge);
if(!Data) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " No Extreme faces" << endl;
#endif
myStatusError = BRepFeat_NoExtFace;
SliList.Append(FirstFace);
if(Sliding) { // sliding
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Sliding" << endl;
#endif
Standard_Boolean Sliding = Standard_False;
// ---case of sliding : construction of the profile face
if(Sliding) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " still Sliding" << endl;
#endif
TopoDS_Face Prof;
FirstEdge,LastEdge);
if (!ProfileOK) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc)
{
cout << "Not computable" << endl;
Sliding = Propagate(SliList, Prof, myFirstPnt, myLastPnt, falseside);
// Control if there is everything required to have the material at the proper side
if(falseside == Standard_False) {
-#ifdef BREPFEAT_DEB
+#ifdef OCCT_DEBUG
cout << "Verify plane and wire orientation" << endl;
#endif
myStatusError = BRepFeat_FalseSide;
// ---Case without sliding : construction of the profile face
if(!Sliding) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
if (Modify) cout << " Sliding failure" << endl;
cout << " no Sliding" << endl;
FirstEdge,LastEdge,OnFirstFace,OnLastFace);
if (!ProfileOK) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc)
{
cout << "Not computable" << endl;
Propagate(SliList, Prof, myFirstPnt, myLastPnt, falseside);
// Control if there is everything required to have the material at the proper side
if(falseside == Standard_False) {
-#ifdef BREPFEAT_DEB
+#ifdef OCCT_DEBUG
cout << "Verify plane and wire orientation" << endl;
#endif
myStatusError = BRepFeat_FalseSide;
void BRepFeat_MakeLinearForm::Add(const TopoDS_Edge& E,
const TopoDS_Face& F)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeLinearForm::Add" << endl;
#endif
void BRepFeat_MakeLinearForm::Perform()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeLinearForm::Perform()" << endl;
#endif
if(mySbase.IsNull() || mySkface.IsNull() || myPbase.IsNull()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Fields not initialized" << endl;
#endif
myStatusError = BRepFeat_NotInitialized;
for(; exx.More(); exx.Next()) {
const TopoDS_Edge& e = TopoDS::Edge(exx.Current());
if(!myMap.IsBound(e)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Sliding face not in Base shape" << endl;
#endif
myStatusError = BRepFeat_IncSlidFace;
SetGluedFaces(mySlface, theForm, myGluedF); // management of sliding faces
if(!myGluedF.IsEmpty() && !mySUntil.IsNull()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc)
{
cout << "The case is not computable" << endl;
const gp_Pnt& Lastpnt,
Standard_Boolean& falseside)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEATRIB();
if (trc) cout << "BRepFeat_MakeLinearForm::Propagate" << endl;
#endif
for (it.Initialize(ledg); it.More(); it.Next()) {
const TopTools_ListOfShape& gfac = thePrism.Shapes(it.Value());
if (gfac.Extent() != 1) {
-#ifdef BREPFEAT_DEB
+#ifdef OCCT_DEBUG
cout << "Pb SetGluedFace" << endl;
#endif
}
#include <TopExp.hxx>
#include <BRepBndLib.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean BRepFeat_GettraceFEAT();
#endif
const Standard_Integer Mode,
const Standard_Boolean Modify)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakePipe::Init" << endl;
#endif
myMap.Bind(exp.Current(), thelist);
myMap(exp.Current()).Append(exp.Current());
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
if (myJustFeat) cout << " Just Feature" << endl;
if (myFuse) cout << " Fuse" << endl;
void BRepFeat_MakePipe::Add(const TopoDS_Edge& E,
const TopoDS_Face& F)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakePipe::Add(Edge,face)" << endl;
#endif
void BRepFeat_MakePipe::Perform()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakePipe::Perform()" << endl;
#endif
void BRepFeat_MakePipe::Perform(const TopoDS_Shape& Until)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakePipe::Perform(Until)" << endl;
#endif
void BRepFeat_MakePipe::Perform(const TopoDS_Shape& From,
const TopoDS_Shape& Until)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakePipe::Perform(From,Until)" << endl;
#endif
#include <gp_Pln.hxx>
#include <Geom_Plane.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean BRepFeat_GettraceFEAT();
#endif
const Standard_Integer Mode,
const Standard_Boolean Modify)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakePrism::Init" << endl;
#endif
myMap.Bind(exp.Current(), thelist);
myMap(exp.Current()).Append(exp.Current());
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
if (myJustFeat) cout << " Just Feature" << endl;
if (myFuse) cout << " Fuse" << endl;
void BRepFeat_MakePrism::Add(const TopoDS_Edge& E,
const TopoDS_Face& F)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakePrism::Add(Edge,face)" << endl;
#endif
void BRepFeat_MakePrism::Perform(const Standard_Real Length)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakePrism::Perform(Length)" << endl;
#endif
void BRepFeat_MakePrism::Perform(const TopoDS_Shape& Until)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakePrism::Perform(Until)" << endl;
#endif
void BRepFeat_MakePrism::Perform(const TopoDS_Shape& From,
const TopoDS_Shape& Until)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakePrism::Perform(From,Until)" << endl;
#endif
void BRepFeat_MakePrism::PerformUntilEnd()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakePrism::PerformUntilEnd()" << endl;
#endif
void BRepFeat_MakePrism::PerformFromEnd(const TopoDS_Shape& Until)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakePrism::PerformFromEnd(From,Until)" << endl;
#endif
void BRepFeat_MakePrism::PerformThruAll()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakePrism::PerformThruAll()" << endl;
#endif
void BRepFeat_MakePrism::PerformUntilHeight(const TopoDS_Shape& Until,
const Standard_Real Length)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakePrism::PerformUntilHeight(Until,Length)" << endl;
#endif
if(c[i] > parmax) parmax = c[i];
if(c[i] < parmin ) parmin = c[i];
}
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
Standard_Real Height = fabs(2.*(parmax - parmin));
//#else
// Standard_Real Height = abs(2.*(parmax - parmin));
#include <ElCLib.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean BRepFeat_GettraceFEAT();
#endif
const Standard_Integer Mode,
const Standard_Boolean Modify)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeRevol::Init" << endl;
#endif
myMap.Bind(exp.Current(), thelist);
myMap(exp.Current()).Append(exp.Current());
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
if (myJustFeat) cout << " Just Feature" << endl;
if (myFuse) cout << " Fuse" << endl;
void BRepFeat_MakeRevol::Add(const TopoDS_Edge& E,
const TopoDS_Face& F)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeRevol::Add(Edge,face)" << endl;
#endif
void BRepFeat_MakeRevol::Perform(const Standard_Real Angle)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeRevol::Perform(Angle)" << endl;
#endif
void BRepFeat_MakeRevol::Perform(const TopoDS_Shape& Until)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeRevol::Perform(Until)" << endl;
#endif
LocOpe_Revol theRevol;
if(!TourComplet) {
Angle = 2.*M_PI- 3*M_PI/180.;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " No complete Revolution" << endl;
#endif
}
void BRepFeat_MakeRevol::Perform(const TopoDS_Shape& From,
const TopoDS_Shape& Until)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeRevol::Perform(From,Until)" << endl;
#endif
void BRepFeat_MakeRevol::PerformThruAll()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeRevol::PerformThruAll()" << endl;
#endif
void BRepFeat_MakeRevol::PerformUntilAngle(const TopoDS_Shape& Until,
const Standard_Real Angle)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeRevol::PerformUntilAngle(Until,Angle)" << endl;
#endif
break;
}
if (!GluedFaces) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << " Intersection Revol/skface : no gluing" << endl;
#endif
#include <GeomLProp_CLProps.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean BRepFeat_GettraceFEAT();
extern Standard_Boolean BRepFeat_GettraceFEATRIB();
#endif
const Standard_Integer Mode,
Standard_Boolean& Modify)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeRevolutionForm::Init" << endl;
#endif
GeomAPI_ProjectPointOnCurve proj1(p1, Line);
GeomAPI_ProjectPointOnCurve proj2(p2, Line);
if(proj1.NbPoints() < 1 || proj2.NbPoints() < 1) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " No projection points" << endl;
#endif
myStatusError = BRepFeat_NoProjPt;
myFuse = Standard_False;
else // if(Mode == 1)
myFuse = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
if (myFuse) cout << " Fuse" << endl;
if (!myFuse) cout << " Cut" << endl;
OnFirstEdge, OnLastEdge);
if(!Data) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " No Extreme faces" << endl;
#endif
myStatusError = BRepFeat_NoExtFace;
SliList.Append(FirstFace);
if(Sliding) { // sliding
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Sliding" << endl;
#endif
Handle(Geom_Surface) s = BRep_Tool::Surface(FirstFace);
if(Sliding) { // sliding
GeomAPI_ProjectPointOnCurve proj(myFirstPnt, Line);
if(proj.NbPoints() < 1) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " No First Point projection" << endl;
#endif
myStatusError = BRepFeat_NoProjPt;
GeomAPI_ProjectPointOnCurve proj1(myLastPnt, Line);
if(proj.NbPoints() < 1) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " No Last Point projection" << endl;
#endif
myStatusError = BRepFeat_NoProjPt;
Precision::Confusion()))
Sliding = Standard_False;
else {
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
if(fabs(FirstCircle.Radius()-FirstRayon) >=
//#else
// if(abs(FirstCircle.Radius()-FirstRayon) >=
Sliding = Standard_False;
else {
Standard_Real rad = LastCircle.Radius();
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
if(fabs(rad - LastRayon) >= Precision::Confusion()) {
//#else
// if(abs(rad - LastRayon) >= Precision::Confusion()) {
// ---case of sliding : construction of the face profile
if(Sliding) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " still Sliding" << endl;
#endif
TopoDS_Face Prof;
FirstEdge,LastEdge);
if (!ProfileOK) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc)
{
cout << "Not computable" << endl;
Sliding = Propagate(SliList, Prof, myFirstPnt, myLastPnt, falseside);
// Control if there is everything required to have the material at the proper side
if(falseside == Standard_False) {
-#ifdef BREPFEAT_DEB
+#ifdef OCCT_DEBUG
cout << " Verify plane and wire orientation" << endl;
#endif
myStatusError = BRepFeat_FalseSide;
// ---Case without sliding : construction of the face profile
if(!Sliding) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
if (Modify) cout << " Sliding failure" << endl;
cout << " no Sliding" << endl;
if(!BRepAlgo::IsValid(NewBndFace)) {
-#ifdef BREPFEAT_DEB
+#ifdef OCCT_DEBUG
cout << "Invalid new bounding face" << endl;
#endif
myStatusError = BRepFeat_InvShape;
FirstEdge,LastEdge,OnFirstFace,OnLastFace);
if (!ProfileOK) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc)
{
cout << "Not computable" << endl;
Propagate(SliList, Prof, myFirstPnt, myLastPnt, falseside);
// Control if there is everything required to have the material at the proper side
if(falseside == Standard_False) {
-#ifdef BREPFEAT_DEB
+#ifdef OCCT_DEBUG
cout << " Verify plane and wire orientation" << endl;
#endif
myStatusError = BRepFeat_FalseSide;
void BRepFeat_MakeRevolutionForm::Add(const TopoDS_Edge& E,
const TopoDS_Face& F)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeRevolutionForm::Add" << endl;
#endif
void BRepFeat_MakeRevolutionForm::Perform()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_MakeRevolutionForm::Perform()" << endl;
#endif
if(mySbase.IsNull() || mySkface.IsNull() || myPbase.IsNull()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Fields not initialized" << endl;
#endif
myStatusError = BRepFeat_NotInitialized;
if(!ASI1.IsDone() || !ASI2.IsDone() ||
ASI1.NbPoints(1) != 1 || ASI2.NbPoints(1) != 1) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Intersection failure" << endl;
#endif
myStatusError = BRepFeat_BadIntersect;
for(; exx.More(); exx.Next()) {
const TopoDS_Edge& e = TopoDS::Edge(exx.Current());
if(!myMap.IsBound(e)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Sliding face not in Base shape" << endl;
#endif
myStatusError = BRepFeat_IncSlidFace;
myGShape = VraiForm;
if(!myGluedF.IsEmpty() && !mySUntil.IsNull()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc)
{
cout << "The case is not computable" << endl;
const gp_Pnt& Lastpnt,
Standard_Boolean& falseside)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEATRIB();
if (trc) cout << "BRepFeat_MakeRevolutionForm::Propagate" << endl;
#endif
for (it.Initialize(ledg); it.More(); it.Next()) {
const TopTools_ListOfShape& gfac = thePrism.Shapes(it.Value());
if (gfac.Extent() != 1) {
-#ifdef BREPFEAT_DEB
+#ifdef OCCT_DEBUG
cout << "Pb SetGluedFace" << endl;
#endif
}
#include <BRepFeat_Builder.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean BRepFeat_GettraceFEAT();
extern Standard_Boolean BRepFeat_GettraceFEATRIB();
#endif
void BRepFeat_RibSlot::LFPerform()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_RibSlot::LFPerform()" << endl;
#endif
if (mySbase.IsNull() || myPbase.IsNull() || mySkface.IsNull()
|| myGShape.IsNull() || myLFMap.IsEmpty()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
cout << "Topological reconstruction is impossible" << endl;
if (trc) cout << " Fields not initialized" << endl;
#endif
(!myFuse && ope != LocOpe_CUT) ||
(!Collage)) {
theOpe = 2;
-#ifdef BREPFEAT_DEB
+#ifdef OCCT_DEBUG
cout << "Passage to topological operations" << endl;
#endif
}
}
else {
theOpe = 2;
-#ifdef BREPFEAT_DEB
+#ifdef OCCT_DEBUG
cout << "Passage to topologic operation" << endl;
#endif
}
const TopTools_ListOfShape& BRepFeat_RibSlot::Modified
(const TopoDS_Shape& F)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_RibSlot::Modified" << endl;
#endif
const TopTools_ListOfShape& BRepFeat_RibSlot::Generated
(const TopoDS_Shape& S)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_RibSlot::Generated" << endl;
#endif
const Handle(Geom_Plane)& Pln)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEATRIB();
if (trc) cout << "BRepFeat_RibSlot::CheckPoint" << endl;
#endif
gp_Dir BRepFeat_RibSlot::Normal(const TopoDS_Face& F,const gp_Pnt& P)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEATRIB();
if (trc) cout << "BRepFeat_RibSlot::Normal" << endl;
#endif
const Standard_Real bnd,
const Standard_Boolean FirstLast)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_RibSlot::EdgeExtention" << endl;
#endif
const Handle(Geom_Plane)& Pln)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEATRIB();
if (trc) cout << "BRepFeat_RibSlot::ChoiceOfFaces" << endl;
#endif
gp_Pnt& p1,
gp_Pnt& p2)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEATRIB();
if (trc) cout << "BRepFeat_RibSlot::HeightMax" << endl;
#endif
TopoDS_Edge& OnLastEdge)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_RibSlot::ExtremeFaces" << endl;
#endif
// ---the wire includes only one edge
if(NumberOfEdges == 1) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " One Edge" << endl;
#endif
exp.ReInit();
}
//--- FirstFace or LastFace was not found
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " FirstFace or LastFace null" << endl;
#endif
LocOpe_CSIntersector ASI(mySbase);
}
}
else {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Less than 2 intersection points" << endl;
#endif
Data = Standard_False;
}
if(FirstFace.IsNull() || LastFace.IsNull()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " First or Last Faces still null" << endl;
#endif
Data = Standard_False;
}
else {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " FirstFace and LastFace OK" << endl;
#endif
Data = Standard_True;
}
// ---The wire consists of several edges
else {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Multiple Edges" << endl;
#endif
BRepTools_WireExplorer ex(myWire);
f = f - bnd/10000; l = l +bnd/10000;
Handle(Geom_TrimmedCurve) curve;
curve = new Geom_TrimmedCurve(Cur, f, l, Standard_True);
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Pnt P1 =
#endif
BRep_Tool::Pnt(TopExp::FirstVertex(E,Standard_True));
return Standard_True;
}
else {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " First or Last not OK" << endl;
#endif
return Standard_False;
TopoDS_Vertex& OnVertex)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEATRIB();
if (trc) cout << "BRepFeat_RibSlot::PtOnEdgeVertex" << endl;
#endif
const TopoDS_Edge& LastEdge)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_RibSlot::SlidingProfile" << endl;
#endif
}
if(BndEdge1.IsNull() || BndEdge2.IsNull()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Null bounding edge" << endl;
#endif
ProfileOK = Standard_False;
TopoDS_Face fac = TopoDS::Face(f.Shape());
if (!BRepAlgo::IsValid(fac)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Invalid Face" << endl;
#endif
ProfileOK = Standard_False;
}
if (!BRepAlgo::IsValid(Prof)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Invalid Face Profile" << endl;
#endif
ProfileOK = Standard_False;
const Standard_Boolean OnLastFace)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) cout << "BRepFeat_RibSlot::NoSlidingProfile" << endl;
#endif
}
if(BndEdge1.IsNull() || BndEdge2.IsNull()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Null bounding edge" << endl;
#endif
ProfileOK = Standard_False;
TopoDS_Face fac = TopoDS::Face(fa.Shape());
if (!BRepAlgo::IsValid(fac)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Invalid Face" << endl;
#endif
ProfileOK = Standard_False;
}
if (!BRepAlgo::IsValid(Prof)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " Invalid Face Profile" << endl;
#endif
ProfileOK = Standard_False;
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <Standard_Type.hxx>
}
}
}
-#if BREPFILL_DEB
+#ifdef OCCT_DEBUG
else {
cout << "BRepFill::SearchOrigine : Echec Distance" << endl;
}
// Standard_Integer MaxDeg = 0;
if ( NbCurves == 0) {
-#ifdef DEBUG_EVOLVED
+#ifdef OCCT_DEBUG
cout << " TrimSurfaceTool : Approx echoue, on met les polygones" << endl;
#endif
#include <TColStd_Array1OfReal.hxx>
#include <TColStd_SequenceOfReal.hxx>
-#ifdef DEB_EFV
+#ifdef OCCT_DEBUG_EFV
static void EdgesFromVertex (const TopoDS_Wire& W,
const TopoDS_Vertex& V,
TopoDS_Edge& E1,
isol = iss;
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Pnt Psol =
#endif
DSS.PointOnShape2(isol);
newwire.Orientation( TopAbs_FORWARD );
myWork(i) = newwire;
}
-#ifdef DEB_EFV
+#ifdef OCCT_DEBUG_EFV
for ( i=ideb; i<=myWork.Length(); i++) {
EdgesFromVertex(wire,Vmini,E1,E2);
TopExp::Vertices(E1,V1,V2,Standard_True);
-#ifndef DEB
+#ifndef OCCT_DEBUG
Standard_Real U1=0, U2=0;
#else
Standard_Real U1, U2;
r = V.Magnitude()/l;
Standard_Integer ii, Ind;
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
Standard_Integer Nb = (Standard_Integer) (4+(10*r));
//#else
// Standard_Integer Nb = 4+(10*r);
myWire = MW.Wire();
}
else {
-#if BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout << "Error in MakeWire" << endl;
#endif
Standard_ConstructionError::Raise("BRepFill_Draft");
}
}
else {
-#if BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout << "No Free Borders !" << endl;
#endif
Standard_ConstructionError::Raise("BRepFill_Draft");
myShape = solid;
}
}
-#if BREPFILL_DEB
+#ifdef OCCT_DEBUG
else cout << "Draft : No assembly !" << endl;
#endif
return Ok;
gp_Ax1 axe(gp::Origin(), cross.XYZ());
N2.Rotate(axe, alpha);
-#if BREPFILL_DEB
+#ifdef OCCT_DEBUG
if (N2.Dot(T1) > 1.e-9) {
cout << "Inprecision in TransformInCompatibleLaw" << endl;
cout << "--- T1.R(N2) = " << N2.Dot(T1) << endl;
}
else {
W.Nullify();
-#if BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout << "BRepFill_LocationLaw::D0 : Attention position out of limits"
<< endl;
#endif
Dist = TheU.Circle().Radius();
}
else {
-#ifdef BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout << "MultiLine : D1 = D2 and the Curve is not a circle" << endl;
cout << " ---> ValueOnFace failed at parameter U = " << U << endl;
#endif
Geom2dInt_GInter Intersector(Cu1,Cu2,TolConf,Tol);
if ( !Intersector.IsDone()) {
-#ifdef BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout << "Intersector not done" << endl;
cout << " ---> ValueonFace failed at parameter U = " << U << endl;
#endif
VV = Alp*(VS2 - VS1) + VS1;
}
else {
-#ifdef BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout << "Intersector done, but no points found" << endl;
cout << " ---> ValueonFace failed at parameter U = " << U << endl;
#endif
#include <Precision.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_Boolean Affich = 0;
#endif
const Standard_Boolean Build)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( Affich) {
#ifdef DRAW
Standard_Integer NBSECT = 0;
{
myShape.Nullify();
myIsDone = Standard_False;
-#ifdef BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout<<"An exception was caught in BRepFill_OffsetWire::Perform : ";
Standard_Failure::Caught()->Print(cout);
cout<<endl;
#include <TColStd_Array1OfInteger.hxx>
#include <Precision.hxx>
-#if DEB
+#ifdef OCCT_DEBUG
static Standard_Boolean myDebug = Standard_False;
#endif
Standard_Real theParam = Place.ParameterOnPath(),
eps = Precision::PConfusion();
-#if DEB
+#ifdef OCCT_DEBUG
if (myDebug) {
gp_Pnt P_Path;
P_Path = adpPath->Value(theParam);
Standard_False, 20);
if (!Bof) Bof = Concat.Add(TC, 200*epsV,
Standard_True, Standard_False, 20);
-#if BREPFILL_DEB
+#ifdef OCCT_DEBUG
if (!Bof)
cout << "BRepFill_ShapeLaw::ConcatenedLaw INCOMPLET !!!"
<< endl;
Approx_SameParameter sp( HC3d, Pcurv, S, tol3d );
if(sp.IsDone() && !sp.IsSameParameter()) Pcurv = sp.Curve2d();
else if(!sp.IsDone() && !sp.IsSameParameter()){
-#ifdef BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout<<"echec SameParameter"<<endl;
#endif
return Standard_False;
ResTol = sp.TolReached();
if(ResTol > tolreached ){
-#ifdef BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout<<"SameParameter : Tolerance not reached!"<<endl;
cout<<"tol visee : "<<tol3d<<" tol obtained : "<<ResTol<<endl;
#endif
thePlane->UReverse();
BRepLib_MakeFace MkF( thePlane, WW );
if (MkF.Error() != BRepLib_FaceDone) {
-#if BREPFILL_DEB
+#ifdef OCCT_DEBUG
BRepLib_FaceError Err = MkF.Error();
cout << "Planar Face Error :" << Err << endl;
#endif
GeomAbs_C1, GeomAbs_C1,
8, 8, 2*NbInt, 0);
if (!App.HasResult()) {
-#if DEB
+#ifdef OCCT_DEBUG
cout << "Filling_Approx : Pas de resultat" << endl;
#endif
return Standard_False;
}
-#if DEB
+#ifdef OCCT_DEBUG
cout << "Filling_Approx Error 3d = " <<
App.MaxError() << endl;
#endif
Substitute( aSubstitute, OldEdge, NewEdge );
}
}
-#if DEB
+#ifdef OCCT_DEBUG
if (!done) cout << "Substitution of Edge failed" << endl;
#endif
}
LastShape = Last;
// It is necessary to check the SameRange on its (PRO13551)
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean issame = Standard_True;
#endif
BRep_Builder B;
if (!BRepLib::CheckSameRange(wexp.Current())) {
B.SameRange(wexp.Current(), Standard_False);
B.SameParameter(wexp.Current(), Standard_False);
-#ifdef DEB
+#ifdef OCCT_DEBUG
issame = Standard_False;
#endif
}
if (!BRepLib::CheckSameRange(wexp.Current())) {
B.SameRange(wexp.Current(), Standard_False);
B.SameParameter(wexp.Current(), Standard_False);
-#ifdef DEB
+#ifdef OCCT_DEBUG
issame = Standard_False;
#endif
}
}
}
-#if BREPFILL_DEB
+#ifdef OCCT_DEBUG
if (!issame)
cout<<"Sweep Warning : Edge not SameRange in the limits"<<endl;
#endif
Max(myTol3d, TabErr(isec,ipath)));
}
if (Degenerated(isec, ipath)) {
-#if BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout << "Sweep : Degenerated case" << endl;
#endif
hasdegen = Standard_True;
t2 = M.Column(3);
if (t1.Angle(t2) < myAngMin) {
-#if BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout << "BRepFill_Sweep::PerformCorner : This is not a corner !" << endl;
#endif
return;
}
else if ((TheTransition == BRepFill_Right) ||
aTrim.HasSection() ) {
-#if BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout << "Fail of TrimCorner" << endl;
#endif
return; // Nothing is touched
if (ii==1) BordFirst = Bord1;
}
}
-#if BREPFILL_DEB
+#ifdef OCCT_DEBUG
else cout << "PerformCorner : Unsymmetry of free border" << endl;
#endif
}
&& ( Points2.Length() != Params.Length() ||
(Points2.Length() == 0 && Params.Length() == 0) ) ) {
-#ifdef BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout << "BRepFill_TrimEdgeTool: incoherent intersection. Try with a greater tolerance" << endl;
#endif
SeanceDeRattrapage++;
}
-#ifdef BREPFILL_DEB
+#ifdef OCCT_DEBUG
if(SeanceDeRattrapage != 0) cout << "SeanceDeRattrapage = " << SeanceDeRattrapage << endl;
if(SeanceDeRattrapage == nn) {
cout << "BRepFill_TrimEdgeTool: incoherent intersection" << endl;
Standard_Real P1xP2x=Abs( P1.X() - P2.X());
if ( P1xP2x > Tol ) {
-#ifdef BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout << "BRepFill_TrimEdgeTool: no same parameter on the bissectrice" << endl;
#endif
if(P1xP2x>TolInit) {
-#ifdef BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout << "BRepFill_TrimEdgeTool: Continue somehow" << endl;
#endif
i++;
}
if (ToProj) {
-#ifdef BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout << " project extremity bissectrice on parallel."<<endl;
#endif
Geom2dAPI_ProjectPointOnCurve Projector2(PBis,C2,f2,l2);
if (Projector1.NbPoints() == 0) {
-#ifdef BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout << "Failed projection in BRepFill_TrimEdgeTool::AddOrConfuse"<<endl;
#endif
return;
}
if (!Projector1.NearestPoint().IsEqual(PBis,Tol)) {
-#ifdef BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout <<"Incorrect solution in BRepFill_TrimEdgeTool::AddOrConfuse"<<endl;
#endif
return;
}
if (Projector2.NbPoints() == 0) {
-#ifdef BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout << "Failed projection in BRepFill_TrimEdgeTool::AddOrConfuse"<<endl;
#endif
return;
}
if (!Projector2.NearestPoint().IsEqual(PBis,Tol)) {
-#ifdef BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout <<" Mauvaisesolution dans BRepFill_TrimEdgeTool::AddOrConfuse"<<endl;
#endif
return;
#include <DrawTrSurf.hxx>
#include <DBRep.hxx>
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_Boolean Affich = Standard_False;
static Standard_Integer NBCALL = 1;
#endif
myInv2(Inv2),
myBis (Bis)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( Affich) {
cout << " ---------->TrimSurfaceTool : NBCALL = " << NBCALL << endl;
NbSegments = Intersector.NbSegments();
if (NbSegments > 0) {
-#ifdef BREPFILL_DEB
+#ifdef OCCT_DEBUG
cout << " IntersectWith : " << NbSegments
<< " Segments of intersection" << endl;
#endif
// evaluate the projection of the point on the curve.
Geom2dAPI_ProjectPointOnCurve Projector(Point, C2d);
-#ifdef BREPFILL_DEB
+#ifdef OCCT_DEBUG
Standard_Real Dist = Projector.LowerDistance();
if ( Dist > Precision::Confusion() ) {
cout << " *** WARNING TrimSurfaceTool: *** " << endl;
#include <TopTools_ListOfShape.hxx>
#include <BRepCheck_Shell.hxx>
#include <TopTools_ListIteratorOfListOfShape.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_Integer AffichEps = 0;
#endif
static Standard_Real surfaceProperties(const TopoDS_Shape& S, GProp_GProps& Props, const Standard_Real Eps){
Standard_Integer i;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iErrorMax = 0;
#endif
Standard_Real ErrorMax = 0.0, Error;
Error = G.GetEpsilon();
if(ErrorMax < Error) {
ErrorMax = Error;
-#ifdef DEB
+#ifdef OCCT_DEBUG
iErrorMax = i;
#endif
}
else G.Perform(BF, BD);
}
Props.Add(G);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(AffichEps) cout<<"\n"<<i<<":\tEpsArea = "<< G.GetEpsilon();
#endif
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(AffichEps) cout<<"\n-----------------\n"<<iErrorMax<<":\tMaxError = "<<ErrorMax<<"\n";
#endif
return ErrorMax;
static Standard_Real volumeProperties(const TopoDS_Shape& S, GProp_GProps& Props, const Standard_Real Eps){
Standard_Integer i;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iErrorMax = 0;
#endif
Standard_Real ErrorMax = 0.0, Error = 0.0;
Error = G.GetEpsilon();
if(ErrorMax < Error) {
ErrorMax = Error;
-#ifdef DEB
+#ifdef OCCT_DEBUG
iErrorMax = i;
#endif
}
else G.Perform(BF, BD);
}
Props.Add(G);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(AffichEps) cout<<"\n"<<i<<":\tEpsVolume = "<< G.GetEpsilon();
#endif
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(AffichEps) cout<<"\n-----------------\n"<<iErrorMax<<":\tMaxError = "<<ErrorMax<<"\n";
#endif
return ErrorMax;
gp_Pnt P(0,0,0); P.Transform(S.Location());
Props = GProp_GProps(P);
Standard_Integer i;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iErrorMax = 0;
#endif
Standard_Real ErrorMax = 0.0, Error = 0.0;
Error = volumeProperties(Sh,Props,Eps);
if(ErrorMax < Error) {
ErrorMax = Error;
-#ifdef DEB
+#ifdef OCCT_DEBUG
iErrorMax = i;
#endif
}
}
}
} else ErrorMax = volumeProperties(S,Props,Eps);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(AffichEps) cout<<"\n\n==================="<<iErrorMax<<":\tMaxEpsVolume = "<<ErrorMax<<"\n";
#endif
return ErrorMax;
#include <GeomAdaptor_Curve.hxx>
#include <GeomConvert.hxx>
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
//Standard_IMPORT Standard_Boolean TopOpeBRepBuild_GettraceFE();
//#endif
void BRepLib_FuseEdges::BuildListEdges()
{
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
//Standard_Boolean tFE = TopOpeBRepBuild_GettraceFE();
//#endif
void BRepLib_FuseEdges::BuildListResultEdges()
{
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
//Standard_Boolean tFE = TopOpeBRepBuild_GettraceFE();
//#endif
void BRepLib_FuseEdges::Perform()
{
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
//Standard_Boolean tFE = TopOpeBRepBuild_GettraceFE();
//#endif
typC1 != STANDARD_TYPE(Geom_Ellipse) &&
typC1 != STANDARD_TYPE(Geom_BSplineCurve) &&
typC1 != STANDARD_TYPE(Geom_BezierCurve)) {
-#ifdef BREPLIB_DEB
+#ifdef OCCT_DEBUG
cout << " TopOpeBRepTool_FuseEdge : Type de Support non traite" << endl;
#endif
return Standard_False;
if (V1.IsSame(myVertex)) VRef = V2;
else if (V2.IsSame(myVertex)) VRef = V1;
else {
-#if BREPLIB_DEB
+#ifdef OCCT_DEBUG
cout << "MakeWire : There is a PROBLEM !!" << endl;
#endif
myError = BRepLib_NonManifoldWire;
if (VF.IsSame(VL)) {
// Particular case: it is required to control the orientation
-#if BREPLIB_DEB
+#ifdef OCCT_DEBUG
if (!VF.IsSame(myVertex))
cout << "MakeWire : There is a PROBLEM !!" << endl;
#endif
if (VF.IsSame(myVertex)) VF = VRef;
else if (VL.IsSame(myVertex)) VL = VRef;
else {
-#if BREPLIB_DEB
+#ifdef OCCT_DEBUG
cout << "MakeWire : Y A UN PROBLEME !!" << endl;
#endif
myError = BRepLib_NonManifoldWire;
}
else {
//Mixed not finished!
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
cout <<" faces locally mixed"<<endl;
#endif
I.Type(BRepOffset_Convex);
mapEdgeType(E).Append(Inter);
}
else {
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
cout <<"edge shared by more than two faces"<<endl;
#endif
}
Standard_Real aT2 = ResParamsOnE2(i); //ponc2.Parameter();
if (Precision::IsInfinite(aT1) || Precision::IsInfinite(aT2))
{
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
cout << "Inter2d : Solution rejected due to infinite parameter"<<endl;
#endif
continue;
dist1 = Max( dist1, dist3 );
B.UpdateVertex( aNewVertex, dist1 );
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
if (aT1 < f[1]-Tol || aT1 > l[1]+Tol)
{
cout << "out of limit"<<endl;
if (E1.Orientation() == TopAbs_REVERSED) V1or.Reverse();
if (E2.Orientation() == TopAbs_REVERSED) V2or.Reverse();
Standard_Real CrossProd = V2or ^ V1;
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
if (Abs(CrossProd) <= gp::Resolution())
cout<<endl<<"CrossProd = "<<CrossProd<<endl;
#endif
Standard_Real aT2 = ResParamsOnE2(i); //ponc2.Parameter();
if (Precision::IsInfinite(aT1) || Precision::IsInfinite(aT2))
{
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
cout << "Inter2d : Solution rejected due to infinite parameter"<<endl;
#endif
continue;
dist1 = Max( dist1, dist3 );
B.UpdateVertex( aNewVertex, dist1 );
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
if (aT1 < f[1]-Tol || aT1 > l[1]+Tol)
{
cout << "out of limit"<<endl;
if (E1.Orientation() == TopAbs_REVERSED) V1or.Reverse();
if (E2.Orientation() == TopAbs_REVERSED) V2or.Reverse();
Standard_Real CrossProd = V2or ^ V1;
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
if (Abs(CrossProd) <= gp::Resolution())
cout<<endl<<"CrossProd = "<<CrossProd<<endl;
#endif
Projector.Init( P1, C3d );
if (Projector.NbPoints() > 0)
f = Projector.LowerDistanceParameter();
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
else
cout<<"ProjectPointOnCurve not done"<<endl;
#endif
Projector.Init( P2, C3d );
if (Projector.NbPoints() > 0)
l = Projector.LowerDistanceParameter();
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
else
cout<<"ProjectPointOnCurve not done"<<endl;
#endif
#include <DBRep.hxx>
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <OSD_Chronometer.hxx>
//#define DEB_VERB
Standard_Boolean AffichInt2d = Standard_False;
YaResult = 1;
Glue.Add (exp.Current().Reversed());
}
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
if(YaResult == 0)
{
cout << "OffsetShape does not contain a FACES." << endl;
}
#endif
}
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
else
{
cout << "OffsetShape is null!" << endl;
//=======================================================================
void BRepOffset_MakeOffset::BuildOffsetByInter()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( ChronBuild) {
cout << " CONSTRUCTION OF OFFSETS :" << endl;
Clock.Reset();
//-------------------------------
myMakeLoops.Build(LFE ,AsDes,IMOE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopTools_IndexedMapOfShape COES;
#endif
//---------------------------
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
DEBVerticesControl (COES,myAsDes);
if ( ChronBuild) Clock.Show();
#endif
//=======================================================================
void BRepOffset_MakeOffset::BuildOffsetByArc()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( ChronBuild) {
cout << " CONSTRUCTION OF OFFSETS :" << endl;
Clock.Reset();
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( ChronBuild) Clock.Show();
#endif
}
void BRepOffset_MakeOffset::SelfInter(TopTools_MapOfShape& /*Modif*/)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( ChronBuild) {
cout << " AUTODEBOUCLAGE:" << endl;
Clock.Reset();
Standard_NotImplemented::Raise();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( ChronBuild) Clock.Show();
#endif
}
void BRepOffset_MakeOffset::Intersection3D(BRepOffset_Inter3d& Inter)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (ChronBuild) {
cout << " INTERSECTION 3D:" << endl;
Clock.Reset();
//--------------------------------
Inter.ConnexIntByArc(OffsetFaces,myShape,myAnalyse,myInitOffsetFace);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( ChronBuild) Clock.Show();
#endif
}
void BRepOffset_MakeOffset::Intersection2D(const TopTools_IndexedMapOfShape& Modif,
const TopTools_IndexedMapOfShape& NewEdges)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (ChronBuild) {
cout << " INTERSECTION 2D:" << endl;
Clock.Reset();
BRepOffset_Inter2d::Compute(myAsDes,F,NewEdges,myTol);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (AffichInt2d) {
DEBVerticesControl (NewEdges,myAsDes);
}
void BRepOffset_MakeOffset::MakeLoops(TopTools_IndexedMapOfShape& Modif)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (ChronBuild) {
cout << " DEBOUCLAGE 2D:" << endl;
Clock.Reset();
if (myOffset > 0 ) InSide = 0;
myMakeLoops.BuildOnContext(LC,myAnalyse,myAsDes,myImageOffset,InSide);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( ChronBuild) Clock.Show();
#endif
}
void BRepOffset_MakeOffset::MakeFaces(TopTools_IndexedMapOfShape& /*Modif*/)
{
-#ifdef DEb
+#ifdef OCCT_DEBUG
if (ChronBuild) {
cout << " RECONSTRUCTION OF FACES:" << endl;
Clock.Reset();
}
myMakeLoops.BuildFaces(LOF,myAsDes,myImageOffset);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( ChronBuild) Clock.Show();
#endif
}
void BRepOffset_MakeOffset::MakeShells ()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (ChronBuild) {
cout << " RECONSTRUCTION OF SHELLS:" << endl;
Clock.Reset();
void BRepOffset_MakeOffset::EncodeRegularity ()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (ChronBuild) {
cout << " CODING OF REGULARITIES:" << endl;
Clock.Reset();
const TopTools_ListOfShape& LofOF = myAsDes->Ascendant(ROE);
if (LofOF.Extent() != 2) {
-#ifdef DEB_VERB
+#ifdef OCCT_DEBUG_VERB
cout << " Edge shared by " << LofOF.Extent() << " Faces" << endl;
#endif
continue;
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( ChronBuild) Clock.Show();
#endif
}
#include <GProp_GProps.hxx>
#include <BRepGProp.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_Boolean Affich = Standard_False;
static Standard_Integer NbOFFSET = 0;
#endif
if (BRep_Tool::Degenerated(E)) {
myBuilder.Degenerated(OE, Standard_True);
/*
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Pnt P1,P2;
gp_Pnt2d P2d;
P2d = C2d->Value(f); TheSurf->D0(P2d.X(),P2d.Y(),P1);
Edge3 = TopoDS::Edge(aLocalEdge);
// Edge3 = TopoDS::Edge(FirstEdge.Oriented(TopAbs_FORWARD));
TopExp::Vertices(Edge3,VVf,VVl);
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
// si firstedge n est pas nul, il faut que les vertex soient partages
if ( !VVf.IsSame(V1f) && !VVf.IsSame(V2f) ) {
cout << "Attention Vertex non partages !!!!!!" << endl;
Edge4 = TopoDS::Edge(aLocalEdge);
// Edge4 = TopoDS::Edge(LastEdge.Oriented(TopAbs_FORWARD));
TopExp::Vertices(Edge4,VVf,VVl);
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
// si lastedge n est pas nul, il faut que les vertex soient partages
if ( !VVf.IsSame(V1l) && !VVf.IsSame(V2l) ) {
cout << "Attention Vertex non partages !!!!!!" << endl;
TopoDS_Vertex V1, V2, V3, V4;
-#ifdef DEB
+#ifdef OCCT_DEBUG
char* name = new char[100];
if (Affich) {
NbOFFSET++;
static Standard_Integer NbExtE = 1;
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_Boolean AffichExtent = Standard_False;
#endif
TopoDS_Edge anEdge = TopoDS::Edge(eseq(i));
BRepLib::SameParameter(anEdge, aSameParTol, Standard_True);
Standard_Real EdgeTol = BRep_Tool::Tolerance(anEdge);
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
cout<<"Tolerance of glued E = "<<EdgeTol<<endl;
#endif
if (EdgeTol > 1.e-2)
{
ReconstructPCurves(anEdge);
BRepLib::SameParameter(anEdge, aSameParTol, Standard_True);
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
cout<<"After projection tol of E = "<<BRep_Tool::Tolerance(anEdge)<<endl;
#endif
}
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (AffichExtent) {
Standard_Real Dist = P.Distance(C.Value(U));
if (Dist > TolConf) {
// if (j == 1) C2 = BRep_Tool::CurveOnSurface(E2,F,fl2[0],fl2[1]);
// else C2 = BRep_Tool::CurveOnSurface(TopoDS::Edge(E2.Reversed()),
// F,fl2[0],fl2[1]);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (C1.IsNull() || C2.IsNull()) {
cout <<"Inter2d : Pas de pcurve"<<endl;
#ifdef DRAW
Standard_Real U1on2 = IntP2.ParamOnFirst();
Standard_Real U2on1 = IntP1.ParamOnSecond();
Standard_Real U2on2 = IntP2.ParamOnSecond();
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
cout << " BRepOffset_Tool::Inter2d SEGMENT d intersection" << endl;
cout << " ===> Parametres sur Curve1 : ";
cout << U1on1 << " " << U1on2 << endl;
LV.Clear();LV.Append(VF); LV.Append(VL);
}
-#ifdef BREPOFFSET_DEB
+#ifdef OCCT_DEBUG
if (!YaSol) {
cout <<"Inter2d : Pas de solution"<<endl;
#ifdef DRAW
Standard_Real U1,U2;
Standard_Real eps = Precision::Confusion();
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopLoc_Location L;
#endif
B.MakeWire(NW);
}
catch(...) //Every exception was caught.
{
-#ifdef BREPOFFSETAPI_DEB
+#ifdef OCCT_DEBUG
cout<<"An exception was caught in BRepOffsetAPI_MakeOffset::Perform : ";
Standard_ConstructionError::Caught()->Print(cout);
cout<<endl;
dd3 = BRepPrim_YMax;
dd4 = BRepPrim_XMin;
break;
-#ifndef DEB
+#ifndef OCCT_DEBUG
default:
break;
#endif
return 1;
}
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
// Flag = Draw::Atof(a[9*ii+7]); // BUG?? Real -> Boolean ???
//#else
Flag = (Standard_Boolean ) Draw::Atof(a[9*ii+7]);
if (dst.IsDone())
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
//dst.Dump(cout);
di << "*** Dump of \"BRepExtrema_DistShapeShape\" in DEBUG mode (begin) *****\n";
Standard_SStream aSStream;
#include <gp_Pnt.hxx>
// pour mes tests
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <OSD_Chronometer.hxx>
#include <Geom_Line.hxx>
#endif
static Standard_Integer filling( Draw_Interpretor & di, Standard_Integer n, const char** a )
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Chronmetrage
OSD_Chronometer Chrono;
Chrono.Reset();
TopoDS_Face ResFace= TopoDS::Face( MakeFilling.Shape() );
DBRep::Set( a[1], ResFace );
-#ifdef DEB
+#ifdef OCCT_DEBUG
Chrono.Stop();
Standard_Real Tps;
Chrono.Show(Tps);
shape.Location ( nullLoc );
}
-#ifdef BREPTOOLS_DEB
+#ifdef OCCT_DEBUG
if ( IsRecorded ( shape ) && ((myConsiderLocation && ! Value ( shape ).IsPartner ( newshape )) ||
(!myConsiderLocation && ! Value ( shape ).IsSame ( newshape ))))
cout << "Warning: BRepTools_ReShape::Replace: shape already recorded" << endl;
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
#define LBRCOMPT 0
#else
#define LBRCOMPT 0
//-- and the last point registered in SeqPnt2d
//-- Try to remote the first point of the current edge
//-- from the last saved point
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Pnt2d Pnt2dDebutEdgeCourant=
#endif
C.Value(u);
if(NbEdges)
{ //-- on compte ++ with a normal explorer and with the Wire Explorer
/*
-#ifdef DEB
+#ifdef OCCT_DEBUG
cout << endl;
cout << "*** BRepTopAdaptor_Fclass2d ** Wire Probablement FAUX **" << endl;
// {
// BadWire=1;
// TabOrien.Append(-1);
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
// cout << endl;
// cout << "*** BRepTopAdaptor_Fclass2d ** Wire Probably FALSE **" << endl;
// cout << "*** Total rotation angle of the wire : " << angle << endl;
}//if(nbpoints>3
else
{
-#ifdef BREPTOPADAPTOR_DEB
+#ifdef OCCT_DEBUG
cout << endl;
cout << "*** BRepTopAdaptor_Fclass2d ** Wire Probably FALSE **" << endl;
cout << "*** The sample wire contains less than 3 points" << endl;
//const BRepTopAdaptor_FClass2d & BRepTopAdaptor_FClass2d::Copy(const BRepTopAdaptor_FClass2d& Other) const {
const BRepTopAdaptor_FClass2d & BRepTopAdaptor_FClass2d::Copy(const BRepTopAdaptor_FClass2d& ) const {
-#ifdef BREPTOPADAPTOR_DEB
+#ifdef OCCT_DEBUG
cerr<<"Copy not allowed in BRepTopAdaptor_FClass2d"<<endl;
#endif
Standard_ConstructionError::Raise();
return(myTopolTool);
}
else {
-#ifdef BREPTOPADAPTOR_DEB
+#ifdef OCCT_DEBUG
cout<<"\n*** Error ds Handle(BRepTopAdaptor_TopolTool) BRepTopAdaptor_Tool::GetTopolTool()\n"<<endl;
#endif
return(myTopolTool);
return(myHSurface);
}
else {
-#ifdef BREPTOPADAPTOR_DEB
+#ifdef OCCT_DEBUG
cout<<"\n*** Error ds Handle(BRepTopAdaptor_TopolTool) BRepTopAdaptor_Tool::GetSurface()\n"<<endl;
#endif
return(myHSurface);
Standard_Real& KnotsResult,
Standard_Real& PolesResult)
{
-#if BSPLCLIB_DEB
+#ifdef OCCT_DEBUG
if (CDegree<Continuity+1) {
cout<<"The BSpline degree must be greater than the order of continuity"<<endl;
}
}
else {
UTolerance=VTolerance=0.0;
-#ifdef DEB
+#ifdef OCCT_DEBUG
cout<<"ElSLib.cxx : maxderivative = 0.0 "<<endl;
#endif
}
{
Handle(Geom_Curve) C;
-#if BITGTE_DEB
+#ifdef OCCT_DEBUG
OSD_Chronometer ch;
ChFi3d_InitChron(ch);
#endif
Conv.Degree());
}
-#if BITGTE_DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch, t_mkcurve);
#endif
myShape = SewedShape;
// end Sewing for false free borders.
-#if BITGTE_DEB
+#ifdef OCCT_DEBUG
OSD_Chronometer cl_total, ch;
Standard_Real t_total, t_center, t_surface, t_shape;
// ----------------------------------------------
// Calculate lines of centers and of surfaces
// ----------------------------------------------
-#if BITGTE_DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch);
#endif
ComputeCenters();
-#if BITGTE_DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch, t_center);
#endif
// -----------------------------
// Calculate connection Surfaces
// -----------------------------
-#if BITGTE_DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch);
#endif
ComputeSurfaces();
-#if BITGTE_DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch, t_surface);
#endif
// ----------------------------------
// Calculate the generated shape if required
// ----------------------------------
-#if BITGTE_DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch);
#endif
if ( myBuildShape) ComputeShape();
-#if BITGTE_DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch, t_shape);
#endif
// since the partition is provided ( A Priori);
BRepLib::BuildCurves3d(myResult, Precision::Confusion());
-#ifdef BITGTE_DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(cl_total, t_total);
cout<<endl;
cout<<"Blend_PERFORM: temps total "<<t_total<<" s dont :"<<endl;
}
}
-#ifdef BITGTE_DEB
+#ifdef OCCT_DEBUG
if ( myResult.IsNull()) {
cout << " No Lines of Generated Centers" << endl;
}
Handle(Geom2d_Curve) PC2 =
BRep_Tool::CurveOnSurface(CurCutE,F2,f2,l2);
if ( PC1.IsNull() || PC2.IsNull()) {
-#ifdef BITGTE_DEB
+#ifdef OCCT_DEBUG
cout << "No PCurves on Intersections : No tubes constructed";
cout << endl;
#endif
InitShape2.ShapeType() == TopAbs_EDGE &&
myStopFaces.Contains(InitShape2);
-#ifdef BITGTE_DEB
+#ifdef OCCT_DEBUG
if ( F1surBordLibre && F2surBordLibre) {
cout << "Rejection : 2 tubes on free border are not intersected";
cout << endl;
if ( Done.Add(V1)) {
Standard_Boolean IsOnR1 = IsOnRestriction(V1,CurE,Face,E1);
Standard_Boolean IsOnR2 = IsOnRestriction(V1,CurE,F2,E2);
-#ifdef BITGTE_DEB
+#ifdef OCCT_DEBUG
if (IsOnR1 && IsOnR2) {
cout << "Leave in the same tps on 2 faces, ";
cout << "propagation only on free border";
// Leave in the same tps on 2 faces, propagate only on
// free borders.
// A priori, only facet is closed.
-#ifdef BITGTE_DEB
+#ifdef OCCT_DEBUG
if (IsOnR1 && IsOnR2) {
cout << "Leave with the same tps on 2 faces, ";
cout << "propagate only if the border is free";
{
if (theGUID == BinStorageDriver)
{
-#ifdef BINDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "BinDrivers : Storage Plugin" << endl;
#endif
static Handle(BinDrivers_DocumentStorageDriver) model_sd =
if (theGUID == BinRetrievalDriver)
{
-#ifdef BINDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "BinDrivers : Retrieval Plugin" << endl;
#endif
static Handle(BinDrivers_DocumentRetrievalDriver) model_rd =
(BinLDrivers_DocumentSection& theSection,
Standard_OStream& theOS)
{
-
-#if defined(_DEBUG) || defined(DEB)
- TCollection_ExtendedString aMethStr ("BinDrivers_DocumentStorageDriver, ");
-#else
- TCollection_ExtendedString aMethStr;
-#endif
const Standard_Size aShapesSectionOffset = (Standard_Size) theOS.tellp();
Handle(BinMNaming_NamedShapeDriver) aNamedShapeDriver;
TCollection_ExtendedString anErrorStr ("Error: ");
Handle(Standard_Failure) aFailure = Standard_Failure::Caught();
TCollection_ExtendedString aStr =
- anErrorStr + aMethStr + "Shape Section :";
+ anErrorStr + "BinDrivers_DocumentStorageDriver, Shape Section :";
WriteMessage (aStr + aFailure->GetMessageString());
}
}
{
if (theGUID == BinLStorageDriver)
{
-#ifdef BINLDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "BinLDrivers : Storage Plugin" << endl;
#endif
static Handle(BinLDrivers_DocumentStorageDriver) model_sd =
if (theGUID == BinLRetrievalDriver)
{
-#ifdef BINLDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "BinLDrivers : Retrieval Plugin" << endl;
#endif
static Handle(BinLDrivers_DocumentRetrievalDriver) model_rd =
Handle(TDocStd_Document) aDoc =
Handle(TDocStd_Document)::DownCast(theNewDocument);
if (aDoc.IsNull()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
WriteMessage (aMethStr + "error: null document");
#endif
myReaderStatus = PCDM_RS_NoDocument;
#ifdef DATATYPE_MIGRATION
TCollection_AsciiString newName;
if(Storage_Schema::CheckTypeMigration(aStr, newName)) {
-#ifdef DATATYPE_MIGRATION_DEB
+#ifdef OCCT_DEBUG
cout << "CheckTypeMigration:OldType = " <<aStr << " Len = "<<aStr.Length()<<endl;
cout << "CheckTypeMigration:NewType = " <<newName << " Len = "<< newName.Length()<<endl;
#endif
#if DO_INVERSE
aShapeSectionPos = InverseInt (aShapeSectionPos);
#endif
-#ifdef DATATYPE_MIGRATION_DEB
+#ifdef OCCT_DEBUG
cout <<"aShapeSectionPos = " <<aShapeSectionPos <<endl;
#endif
if(aShapeSectionPos) {
if (!IS.eof())
{
const std::streamoff endPos = IS.rdbuf()->pubseekoff(0L, std::ios_base::end, std::ios_base::in);
-#ifdef DATATYPE_MIGRATION_DEB
+#ifdef OCCT_DEBUG
cout << "endPos = " << endPos <<endl;
#endif
if(ShapeSectionPos != endPos) {
myMsgDriver = theDocument -> Application() -> MessageDriver();
myMapUnsupported.Clear();
-#if defined(_DEBUG) || defined(DEB)
- TCollection_ExtendedString aMethStr ("BinLDrivers_DocumentStorageDriver, ");
-#else
- TCollection_ExtendedString aMethStr;
-#endif
- TCollection_ExtendedString anErrorStr ("Error: ");
-
Handle(TDocStd_Document) aDoc =
Handle(TDocStd_Document)::DownCast(theDocument);
if (aDoc.IsNull()) {
ofstream anOS (aFileName.ToCString(), ios::ate);
//ofstream anOS (aFileName.ToCString(), ios::out| ios::binary | ios::ate);
#endif
-#ifdef BINLDRIVERS_DEB
+#ifdef OCCT_DEBUG
const Standard_Integer aP = (Standard_Integer) anOS.tellp();
cout << "POS = " << aP <<endl;
#endif
if (!myRelocTable.Extent()) {
// No objects written
-#ifdef DEB
- WriteMessage (aMethStr + "no objects written");
+#ifdef OCCT_DEBUG
+ WriteMessage ("BinLDrivers_DocumentStorageDriver, no objects written");
#endif
- SetIsError(Standard_True);
- SetStoreStatus(PCDM_SS_No_Obj);
-
+ SetIsError(Standard_True);
+ SetStoreStatus(PCDM_SS_No_Obj);
}
myRelocTable.Clear();
}
if (!anOS) {
// A problem with the stream
-#if defined(_DEBUG) || defined(DEB)
- WriteMessage (anErrorStr + aMethStr +
- "Problem with the file stream, rdstate="
+#ifdef OCCT_DEBUG
+ TCollection_ExtendedString anErrorStr ("Error: ");
+ WriteMessage (anErrorStr + "BinLDrivers_DocumentStorageDriver, Problem with the file stream, rdstate="
+ (Standard_Integer )anOS.rdstate());
-#else
- TCollection_ExtendedString aStr =
- anErrorStr + aMethStr + "Problem writing the file ";
- WriteMessage (aStr + theFileName);
#endif
SetIsError(Standard_True);
SetStoreStatus(PCDM_SS_WriteFailure);
void BinLDrivers_DocumentStorageDriver::UnsupportedAttrMsg
(const Handle(Standard_Type)& theType)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
static TCollection_ExtendedString aMsg
("BinDrivers_DocumentStorageDriver: warning: attribute driver for type ");
#endif
if (!myMapUnsupported.Contains(theType)) {
myMapUnsupported.Add(theType);
-#ifdef DEB
+#ifdef OCCT_DEBUG
WriteMessage (aMsg + theType->Name() + " not found");
#endif
}
// Write data to the stream -->!!!
theOS << myPAtt;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
else
UnsupportedAttrMsg (aType);
#endif
hasAttr = Standard_True;
myTypesMap.Add (aType);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
else
UnsupportedAttrMsg (aType);
#endif
{
FSD_BinaryFile aFileDriver;
if (aFileDriver.Open( theFileName, Storage_VSWrite ) != Storage_VSOk) {
-#if defined(DEB) || defined(_DEBUG)
- WriteMessage ("BinDrivers_DocumentStorageDriver: error opening file");
-#else
WriteMessage (TCollection_ExtendedString("Error: Cannot open file ") +
theFileName);
-#endif
SetIsError(Standard_True);
return;
}
aFileDriver.EndWriteDataSection();
}
else {
-#if defined(DEB) || defined(_DEBUG)
- WriteMessage("BinDrivers_DocumentStorageDriver: error writing header");
-#else
WriteMessage(TCollection_ExtendedString("Error: Problem writing header "
"into file ") + theFileName);
-#endif
SetIsError(Standard_True);
}
-#ifdef BINLDRIVERS_DEB
+#ifdef OCCT_DEBUG
const Standard_Integer aP = (Standard_Integer) aFileDriver.Tell();
cout << "POS = " << aP <<endl;
#endif
else
aDelta = (Standard_Boolean)aDeltaValue;
}
-#ifdef BINMDATASTD_DEB
+#ifdef OCCT_DEBUG
else if(BinMDataStd::DocumentVersion() == -1)
cout << "Current DocVersion field is not initialized. " <<endl;
#endif
TCollection_AsciiString entry;
ok = theSource >> entry;
if(ok) {
-#ifdef BINMNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "NamingDriver:: Retrieved Context Label = " << entry << " Ok = " << theSource.IsOK() <<endl;
#endif
if(ok) {
OrientationToApply = (TopAbs_Orientation)anIndx;
aName.Orientation(OrientationToApply);
-#ifdef BINMNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "NamingDriver:: Retrieved Orientation = " << OrientationToApply << " Ok = " << theSource.IsOK() <<endl;
#endif
} else {
}
}
}
-#ifdef BINMNAMING_DEB
+#ifdef OCCT_DEBUG
else if(BinMNaming::DocumentVersion() == -1)
cout << "Current DocVersion field is not initialized. " <<endl;
else
// The location is not identity
if( myLocations == 0 )
{
-#ifdef BINMXCAFDOC_DEB
+#ifdef OCCT_DEBUG
cout<<"Pointer to LocationSet is NULL\n";
#endif
return;
{
if(aGUID == BinStorageDriver)
{
-#ifdef BINTOBJDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "BinTObjDrivers : Storage Plugin" << endl;
#endif
static Handle(BinTObjDrivers_DocumentStorageDriver) model_sd
if(aGUID == BinRetrievalDriver)
{
-#ifdef BINTOBJDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "BinTObjDrivers : Retrieval Plugin" << endl;
#endif
static Handle (BinTObjDrivers_DocumentRetrievalDriver) model_rd
if (IS.fail() || strcmp(buffer,"Curve2ds")) {
Standard_SStream aMsg;
aMsg << "BinTools_Curve2dSet::Read: Not a Curve2d table"<<endl;
-#ifdef BINTOOLS_DEB
+#ifdef OCCT_DEBUG
cout <<"Curve2dSet buffer: " << buffer << endl;
#endif
Standard_Failure::Raise(aMsg);
if (IS.fail() || strcmp(buffer,"Curves")) {
Standard_SStream aMsg;
aMsg << "BinTools_CurveSet::Read: Not a Curve table"<<endl;
-#ifdef BINTOOLS_DEB
+#ifdef OCCT_DEBUG
cout <<"CurveSet buffer: " << buffer << endl;
#endif
Standard_Failure::Raise(aMsg);
BinTools::PutReal(OS, BRep_Tool::Tolerance(V));
gp_Pnt p = BRep_Tool::Pnt(V);
OS << p;
-#ifdef MDTV_DEB
- Standard_Integer aPos;
+#ifdef OCCT_DEBUG_POS
+ std::streamoff aPos;
#endif
Handle(BRep_TVertex) TV = Handle(BRep_TVertex)::DownCast(S.TShape());
BRep_ListIteratorOfListOfPointRepresentation itrp(TV->Points());
const Handle(BRep_PointRepresentation)& PR = itrp.Value();
// BinTools::PutReal(OS, PR->Parameter());
if (PR->IsPointOnCurve()) {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG_POS
aPos = OS.tellp();
#endif
OS << (Standard_Byte)1; // 1
}
else if (PR->IsPointOnCurveOnSurface()) {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG_POS
aPos = OS.tellp();
#endif
OS << (Standard_Byte)2;// 2
}
else if (PR->IsPointOnSurface()) {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG_POS
aPos = OS.tellp();
#endif
OS << (Standard_Byte)3;// 3
BRep_ListOfPointRepresentation& lpr = TV->ChangePoints();
TopLoc_Location L;
Standard_Boolean aNewF = (myFormatNb > 2) ? Standard_True : Standard_False;
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
gp_Pnt aPnt = gp_Pnt(X,Y,Z);
#endif
do {
streampos aPos = IS.tellg();
BinTools::GetReal(IS, p1);
val = (Standard_Integer)IS.get();//case {0|1|2|3}
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout << "\nVal = " << val <<endl;
#endif
if(val != 1 && val !=2 && val !=3){
if (IS.fail() || strstr(buffer,"Polygon3D") == NULL) {
aMsg << "BinTools_ShapeSet::ReadPolygon3D: Not a Polygon3D section" <<endl;
-#ifdef BINTOOLS_DEB
+#ifdef OCCT_DEBUG
cout <<"Buffer: " << buffer << endl;
#endif
Standard_Failure::Raise(aMsg);
if (IS.fail() || strcmp(buffer,"Surfaces")) {
Standard_SStream aMsg;
aMsg << "BinTools_SurfaceSet::Read: Not a surface table"<<endl;
-#ifdef BINTOOLS_DEB
+#ifdef OCCT_DEBUG
cout <<"SurfaceSet buffer: " << buffer << endl;
#endif
Standard_Failure::Raise(aMsg);
if (theGUID == BinXCAFStorageDriver)
{
-#ifdef BINXCAFDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "BinXCAFDrivers : Storage Plugin" << endl;
#endif
static Handle(BinXCAFDrivers_DocumentStorageDriver) model_sd =
if (theGUID == BinXCAFRetrievalDriver)
{
-#ifdef BINXCAFDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "BinXCAFDrivers : Retrieval Plugin" << endl;
#endif
static Handle(BinXCAFDrivers_DocumentRetrievalDriver) model_rd =
}
type = curve->DynamicType();
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Pnt2d Point(asecondpoint->Pnt2d());
#else
asecondpoint->Pnt2d();
case 2 : {
GccAna_LinPnt2dBisec Bisector(line,asecondpoint->Pnt2d());
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Vec2d V(line.Direction());
#else
line.Direction();
//purpose :
//=============================================================================
// Unused :
-#ifdef DEB_CUR
+#ifdef OCCT_DEBUG_CUR
static Standard_Real Curvature (const Handle(Geom2d_Curve)& C,
Standard_Real U,
Standard_Real Tol)
else {
Standard_Real A = 0.5*SquareMagPPC/Prosca;
Standard_Real Dist = A*A*NorNor;
-#ifdef DEB_CUR
+#ifdef OCCT_DEBUG_CUR
//----------------------------------------
// Test Curvature if the curve is concave.
//----------------------------------------
// Change guiedline on Bis2.
BisTemp = Bis2->ChangeGuide();
Guide = Bis2->Curve(2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Pnt2d P2S = Bis2->ValueAndDist(D2.FirstParameter(),U1,UMax,Dist);
gp_Pnt2d P2E = Bis2->ValueAndDist(D2.LastParameter() ,U1,UMin,Dist);
#else
#include <Adaptor2d_HCurve2d.hxx>
#include <Precision.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TColStd_Array1OfInteger.hxx>
#include <TColStd_Array1OfReal.hxx>
#include <TColgp_Array1OfPnt2d.hxx>
if (State!=Blend_OK) {
return;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(surf,curv,param,Func);
}
if (!rsnld.IsDone()) {
-#ifdef BLEND_DEB
+#ifdef OCCT_DEBUG
cout << "RSNLD not done "<< endl << endl;
#endif
return Standard_False;
switch (State) {
case Blend_OK :
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(surf,curv,param,Func);
}
case Blend_StepTooSmall :
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(surf,curv,param,Func);
}
case Blend_OnRst1 :
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(surf,curv,param,Func);
}
#include <CSLib_NormalStatus.hxx>
#include <Precision.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TColStd_Array1OfInteger.hxx>
#include <TColStd_Array1OfReal.hxx>
#include <TColgp_Array1OfPnt2d.hxx>
sol = ParDep;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
sectioncalculee = 0;
#endif
State = TestArret(Func, Blend_OK, Standard_False);
if (State!=Blend_OK) {
return;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(surf1,surf2,sol,param,Func);
}
}
TestArret(Func, Blend_OK, Standard_False);
- #ifdef DEB
+ #ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT())
{
Drawsect(surf1, surf2, sol, param, Func);
{
case Blend_OnRst1:
{
- #ifdef DEB
+ #ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT())
{
Drawsect(surf1, surf2, sol, param, Func);
case Blend_OnRst2:
{
- #ifdef DEB
+ #ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT())
{
Drawsect(surf1, surf2, sol, param, Func);
case Blend_OnRst12 :
{
- #ifdef DEB
+ #ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT())
{
Drawsect(surf1, surf2, sol, param, Func);
if ( !TestSolu) tolsolu *= 1000; //Ca doit toujours etre bon
if (Function.IsSolution(sol,tolsolu)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
sectioncalculee = 1;
#endif
Standard_Boolean curpointistangent = Function.IsTangencyPoint();
// Resolution...
rsnld.Perform(FuncInv,solrst,infb,supb);
if (!rsnld.IsDone()) {
-#ifdef BLEND_DEB
+#ifdef OCCT_DEBUG
cout << "Walking::Recadre : RSNLD not done " << endl;
#endif
recadre = Standard_False;
rsnld.Perform(FuncInv,solrst,infb,supb);
if (!rsnld.IsDone()) {
-#ifdef BLEND_DEB
+#ifdef OCCT_DEBUG
cout << "Walking::Recadre : RSNLD not done " << endl;
#endif
recadre = Standard_False;
TheSurfaceTool::LastVParameter(surf),
stat, thenormal, iu, iv);
normale.SetXYZ(thenormal.XYZ());
-#if BLEND_DEB
+#ifdef OCCT_DEBUG
if (stat == CSLib_InfinityOfSolutions)
cout << "Blend_Walking::Transition : Infinite de Normal" << endl;
#endif
while (!Arrive) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
sectioncalculee = 0;
nbcomputedsection++;
#endif
}
Standard_Boolean testdefl = 1;
-#ifdef DEB
+#ifdef OCCT_DEBUG
testdefl = !Blend_GetcontextNOTESTDEFL();
#endif
if (recad1 || recad2) {
if (stepw > 2*tolgui) State = Blend_StepTooLarge;
// Sinon echec recadrage. On sort avec PointsConfondus
else {
-#if BLEND_DEB
+#ifdef OCCT_DEBUG
cout << "Echec recadrage" << endl;
#endif
State = Blend_SamePoints;
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Blend_GettraceDRAWSECT()){
Drawsect(surf1,surf2,sol,param,Func, State);
}
case Blend_SamePoints :
{
// On arrete
-#if BLEND_DEB
+#ifdef OCCT_DEBUG
cout << " Points confondus dans le cheminement" << endl;
#endif
Ext1.SetValue(previousP.PointOnS1(),
Arrive = Standard_True;
}
break;
-#ifndef DEB
+#ifndef OCCT_DEBUG
default:
break;
#endif
if (invnorm1 > Eps) invnorm1 = ((Standard_Real) 1) /invnorm1;
else {
invnorm1 = 1; // Unsatisfactory, but it is not necessary to crash
-#if BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
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 BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout << " ConstRad : Surface singuliere " << endl;
#endif
}
Abs(controle(2)) > tolerances(2) ||
Abs(controle(3)) > tolerances(3) ||
Abs(controle(4)) > tolerances(4)){
-#ifdef BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout<<"Cheminement : echec calcul des derivees"<<endl;
#endif
istangent = Standard_True;
norm2 = nplan.Crossed(ns2).Magnitude();
if (norm1 < Eps) {
norm1 = 1; // Unsatisfactory, but it is not necessary to stop
-#if BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout << " ConstRad : Surface singuliere " << endl;
#endif
}
if (norm2 < Eps) {
norm2 = 1; // Unsatisfactory, but it is not necessary to stop
-#if BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout << " ConstRad : Surface singuliere " << endl;
#endif
}
P.ParametersOnS2(X(3), X(4));
/* Pour debuger par des D.F
-#if DEB
+#ifdef OCCT_DEBUG
Standard_Real deltat = 1.e-7;
if (prm==tcurv->LastParameter()){deltat *= -1;} //Pour les discont
Standard_Real deltaX = 1.e-7;
distmin = Min (distmin, pts1.Distance(pts2));
/*
-#if DEB
+#ifdef OCCT_DEBUG
MDiff = (M - DEDX)*(1/deltat);
VDiff = (V - DEDT)*(1/deltat);
norm2 = nplan.Crossed(ns2).Magnitude();
if (norm1 < Eps) {
norm1 = 1; // Unsatisfactory, but it is not necessary to stop
-#if BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout << " ConstRad : Surface singuliere " << endl;
#endif
}
if (norm2 < Eps) {
norm2 = 1; // Unsatisfactory, but it is not necessary to stop
-#if BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout << " ConstRad : Surface singuliere " << endl;
#endif
}
norm2 = ncrossns2.Magnitude();
if (norm1 < Eps) {
norm1 = 1; // Unsatisfactory, but it is not necessary to stop
-#if BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout << " ConstRadInv : Surface singuliere " << endl;
#endif
}
if (norm2 < Eps) {
norm2 = 1; // Unsatisfactory, but it is not necessary to stop
-#if BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout << " ConstRadInv : Surface singuliere " << endl;
#endif
}
norm2 = ncrossns2.Magnitude();
if (norm1 < Eps) {
norm1 = 1; // Unsatisfactory, but it is not necessary to stop
-#if BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout << " ConstRadInv : Surface singuliere " << endl;
#endif
}
if (norm2 < Eps) {
norm2 = 1; // Unsatisfactory, but it is not necessary to stop
-#if BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout << " ConstRadInv : Surface singuliere " << endl;
#endif
}
if (invnorm1 > Eps) invnorm1 = ((Standard_Real) 1) /invnorm1;
else {
invnorm1 = 1; // Unsatisfactory, but it is not necessary to stop
-#if BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
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 BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout << " EvolRad : Surface singuliere " << endl;
#endif
}
Abs(controle(2)) > tolerances(2) ||
Abs(controle(3)) > tolerances(3) ||
Abs(controle(4)) > tolerances(4)){
-#ifdef BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout<<"Cheminement : echec calcul des derivees"<<endl;
#endif
istangent = Standard_True;
(U2!=xval(3)) || (V2!=xval(4))) {
gp_Vec d1u,d1v;
gp_Pnt bid;
-#if BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout << " erreur de tengent !!!!!!!!!!!!!!!!!!!!" << endl;
#endif
surf1->D1(U1,V1,bid,d1u,d1v);
norm2 = nplan.Crossed(ns2).Magnitude();
if (norm1 < Eps) {
norm1 = 1; // Unsatisfactory, but it is not necessary to stop
-#if BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout << " EvolRad : Surface singuliere " << endl;
#endif
}
if (norm2 < Eps) {
norm2 = 1; // Unsatisfactory, but it is not necessary to stop
-#if BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout << " EvolRad : Surface singuliere " << endl;
#endif
}
norm2 = nplan.Crossed(ns2).Magnitude();
if (norm1 < Eps) {
norm1 = 1; // Unsatisfactory, but it is not necessary to stop
-#if BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout << " EvolRad : Surface singuliere " << endl;
#endif
}
if (norm2 < Eps) {
norm2 = 1; // Unsatisfactory, but it is not necessary to stop
-#if BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout << " EvolRad : Surface singuliere " << endl;
#endif
}
P.ParametersOnS2(X(3), X(4));
/*
-#if DEB
+#ifdef OCCT_DEBUG
Standard_Real deltat = 1.e-9;
if (prm==tcurv->LastParameter()){deltat *= -1;} //Pour les discont
Standard_Real deltaX = 1.e-9;
distmin = Min (distmin, pts1.Distance(pts2));
/*
-#if DEB
+#ifdef OCCT_DEBUG
MDiff = (M - DEDX)*(1/deltat);
VDiff = (V - DEDT)*(1/deltat);
norm2 = nplan.Crossed(ns2).Magnitude();
if (norm1 < Eps) {
norm1 = 1; // Unsatisfactory, but it is not necessary to stop
-#if BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout << " EvolRad : Surface singuliere " << endl;
#endif
}
if (norm2 < Eps) {
norm2 = 1; // Unsatisfactory, but it is not necessary to stop
-#if BLENDFUNC_DEB
+#ifdef OCCT_DEBUG
cout << " EvolRad : Surface singuliere " << endl;
#endif
}
const TCollection_ExtendedString& aName,
const TCollection_ExtendedString& aVersion,
const Standard_Boolean UseStorageConfiguration) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
CDF_Timer theTimer;
#endif
else
theMetaData=theMetaDataDriver->MetaData(aFolder,aName,aVersion);
-#ifdef DEB
+#ifdef OCCT_DEBUG
theTimer.ShowAndRestart("Getting MetaData: ");
#endif
CDF_TypeOfActivation theTypeOfActivation=TypeOfActivation(theMetaData);
Handle(CDM_Document) theDocument=Retrieve(theMetaData,UseStorageConfiguration,Standard_False);
-#ifdef DEB
+#ifdef OCCT_DEBUG
theTimer.ShowAndRestart("Creating Transient: ");
#endif
CDF_Session::CurrentSession()->Directory()->Add(theDocument);
Activate(theDocument,theTypeOfActivation);
-#ifdef DEB
+#ifdef OCCT_DEBUG
theTimer.ShowAndStop("Activate: ");
#endif
//=======================================================================
PCDM_ReaderStatus CDF_Application::CanRetrieve(const TCollection_ExtendedString& aFolder, const TCollection_ExtendedString& aName, const TCollection_ExtendedString& aVersion) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
CDF_Timer theTimer;
#endif
else if (!theMetaDataDriver->HasReadPermission(aFolder,aName,aVersion))
return PCDM_RS_PermissionDenied;
else {
-#ifdef DEB
+#ifdef OCCT_DEBUG
theTimer.ShowAndRestart("theMetaDataDriver->Find: ");
#endif
Handle(CDM_MetaData) theMetaData = theMetaDataDriver->MetaData(aFolder,aName,aVersion);
-#ifdef DEB
+#ifdef OCCT_DEBUG
theTimer.ShowAndStop("Getting MetaData: ");
#endif
//=======================================================================
const CSLib_Class2d& CSLib_Class2d::Copy(const CSLib_Class2d& ) const
{
-#ifdef CSLIB_DEB
+#ifdef OCCT_DEBUG
cerr<<"Copy not allowed in CSLib_Class2d"<<endl;
#endif
Standard_ConstructionError::Raise();
}
}
else {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"ConcaveSide : no concave face"<<endl;
#endif
//This 10 shows that the face at end is in the extension of one of two base faces
//here it turns back, the points are taken in faces
//neither too close nor too far as much as possible.
Standard_Real u,v;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Real deport = 1000*BRep_Tool::Tolerance(E);
#endif
ChFi3d_Coefficient(dint1,DU1,DV1,u,v);
#include <TestTopOpeTools.hxx>
#include <TestTopOpe.hxx>
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <OSD_Chronometer.hxx>
void ChFi3d_Builder::Compute()
{
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
t_total=0;t_extent=0; t_perfsetofsurf=0;t_perffilletonvertex=0;
t_filds=0;t_reconstruction=0;t_setregul=0;
t_perfsetofkpart=0; t_perfsetofkgen=0;t_makextremities=0;
ExtentAnalyse();
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_ResultChron(cl_extent,t_extent);
ChFi3d_InitChron(cl_perfsetofsurf);
#endif
}
catch(Standard_Failure) {
Handle(Standard_Failure) exc = Standard_Failure::Caught();
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"EXCEPTION Stripe compute " << exc << endl;
#endif
badstripes.Append(itel.Value());
}
done = (badstripes.IsEmpty());
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_ResultChron(cl_perfsetofsurf,t_perfsetofsurf);
ChFi3d_InitChron(cl_perffilletonvertex);
#endif
catch(Standard_Failure)
{
Handle(Standard_Failure) exc = Standard_Failure::Caught();
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"EXCEPTION Corner compute " << exc << endl;
#endif
badvertices.Append(myVDataMap.FindKey(j));
}
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_ResultChron(cl_perffilletonvertex,t_perffilletonvertex);
ChFi3d_InitChron(cl_filds);
#endif
}
catch(Standard_Failure) {
Handle(Standard_Failure) exc = Standard_Failure::Caught();
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"EXCEPTION Fillets compute " << exc << endl;
#endif
badstripes.Append(itel.Value());
if (!done) break;
}
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_ResultChron(cl_filds,t_filds);
ChFi3d_InitChron(cl_reconstruction);
#endif
}
}
}
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_ResultChron(cl_reconstruction ,t_reconstruction);
ChFi3d_InitChron(cl_setregul);
#endif
SetRegul();
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_ResultChron(cl_setregul ,t_setregul);
#endif
}
}
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_ResultChron(cl_total,t_total);
#endif
// display of time for perfs
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(ChFi3d_GettraceCHRON()){
cout<<endl;
cout<<"COMPUTE: temps total "<<t_total<<"s dont :"<<endl;
{
if(sp->Status(isfirst) == ChFiDS_FreeBoundary) return;
if(nba>3) {
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_InitChron(cl_performatend);
#endif
PerformIntersectionAtEnd(Index);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(cl_performatend,t_performatend);
#endif
}
else {
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_InitChron(cl_perform1corner);
#endif
if (MoreSurfdata(Index))
PerformMoreSurfdata(Index);
else PerformOneCorner(Index);
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_ResultChron(cl_perform1corner,t_perform1corner);
#endif
}
case 2 :
{
if(nba>3){
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_InitChron(cl_performmore3corner);
#endif
PerformMoreThreeCorner(Index, i);
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_ResultChron(cl_performmore3corner,t_performmore3corner);
#endif
}
else {
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_InitChron(cl_perform2corner);
#endif
PerformTwoCorner(Index);
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_ResultChron(cl_perform2corner,t_perform2corner);
#endif
}
case 3 :
{
if(nba>3){
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_InitChron(cl_performmore3corner);
#endif
PerformMoreThreeCorner(Index, i);
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_ResultChron(cl_performmore3corner,t_performmore3corner);
#endif
}
else {
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_InitChron(cl_perform3corner);
#endif
PerformThreeCorner(Index);
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_ResultChron(cl_perform3corner,t_perform3corner);
#endif
}
}
break;
default : {
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_InitChron(cl_performmore3corner);
#endif
PerformMoreThreeCorner(Index, i);
-#ifdef DEB //perf
+#ifdef OCCT_DEBUG //perf
ChFi3d_ResultChron(cl_performmore3corner,t_performmore3corner);
#endif
}
#include <ChFi3d_Builder_0.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <OSD_Chronometer.hxx>
extern Standard_Boolean ChFi3d_GetcontextFORCEBLEND();
extern Standard_Boolean ChFi3d_GettraceDRAWINT();
#include <TColStd_Array1OfReal.hxx>
#include <TColStd_Array1OfInteger.hxx>
#include <TopTools_Array1OfShape.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <OSD_Chronometer.hxx>
extern OSD_Chronometer simul,elspine,chemine;
#endif
#include <LocalAnalysis_SurfaceContinuity.hxx>
#include <TopOpeBRepTool_TOOL.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean ChFi3d_GetcontextFORCEBLEND();
#endif
E[i] = Ec;
}
else{
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"top has more than 3 edges"<<endl;
#endif
sommetpourri = Standard_True;
}
if(nbf>3) {
Spine->SetFirstStatus(ChFiDS_BreakPoint);
-#if CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"top has : "<<nbf<<" faces."<<endl;
#endif
}
}
if(nbf>3) {
Spine->SetLastStatus(ChFiDS_BreakPoint);
-#if CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"top has : "<<nbf<<" faces."<<endl;
#endif
}
#include <ChFi3d.hxx>
#include <ChFi3d_Builder_0.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#ifdef DRAW
#include <DrawTrSurf.hxx>
#endif
Handle(BRepAdaptor_HSurface)& Surf1,
Handle(BRepAdaptor_HSurface)& Surf2)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OSD_Chronometer ch1;
#endif
Handle(BRepAdaptor_HSurface) HSon1, HSon2;
}
else{
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch1);//initial perform for PerformSurf
#endif
MaxStep,Fleche,tolesp,
First,Last,Inside,Inside,forward,
RecOnS1,RecOnS2,Soldep,intf,intl);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch1,t_performsurf);// result perf for PerformSurf
#endif
}
}
else{
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch1);//init perf for PerformSurf
#endif
MaxStep,Fleche,tolesp,
First,Last,Inside,Inside,forward,
RecOnS1,RecOnS2,Soldep,intf,intl);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch1,t_performsurf);// result perf for PerformSurf
#endif
}
TopoDS_Edge E;
if (Pc.IsVertex()){
// attention it is necessary to analyze all faces that turn around of the vertex
-#if CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"Commonpoint on vertex, the process hangs up"<<endl;
#endif
if (Pc.HasVector()) { //General processing
FindFace = Standard_False;
if (Spine.IsNull()) {
//La Spine peut etre nulle (ThreeCorner)
-#if CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout << "FindFace sur vertex avec spine nulle! QUEZAKO ?" << endl;
#endif
return Standard_False;
Standard_Integer opp = 3-ons;
if (!SD->Vertex(isfirst,opp).IsOnArc() ||
SD->TwistOnS1() || SD->TwistOnS2() ) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"ChFi3d_Purge : No output on extension."<<endl;
#endif
ChFiDS_SequenceOfSurfData& Seq =
Handle(BRepTopAdaptor_TopolTool)& It2,
const Standard_Boolean Simul)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OSD_Chronometer ch1;
#endif
//sinon solution approchee.
Inside = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch1);// init perf for StartSol
#endif
StartSol(Stripe,HGuide,HS1,HS2,It1,It2,pp1,pp2,First);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch1,t_startsol); // result perf for StartSol
#endif
First = wl; Last = Guide.FirstParameter();
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch1);// init perf for startsol
#endif
HC1.Nullify();
HC2.Nullify();
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch1,t_startsol); // result perf for startsol
#endif
if(intl && forward) Vref = Spine->LastVertex();
if(!ref.IsNull()){
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch1);// init perf for StartSol
#endif
HSref2,HCref2, RecP2,RecS2,RecRst2,obstacleon2,
HS4,pp4,decroch2,Vref);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch1,t_startsol); // result perf for StartSol
#endif
RecP1,RecRst1,RecP2,RecRst2,SoldepCC);
}
else{
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch1); // init perf for PerformSurf
#endif
PerformSurf(SeqSD,HGuide,Spine,Choix,
HS2,It2,HC2,HSref2,HCref2,decroch2,Or2,
MaxStep,locfleche,tolesp,First,Last,Inside,Inside,forward,
RecP1,RecRst1,RecP2,RecRst2,SoldepCC);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch1,t_performsurf); //result perf for PerformSurf
#endif
}
Inside,Inside,forward,RecP1,RecS2,RecRst1,SoldepCS);
}
else{
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch1); // init perf for PerformSurf
#endif
PerformSurf(SeqSD,HGuide,Spine,Choix,HS1,It1,HC1,HSref1,HCref1,decroch1,
HS2,It2,Or2,MaxStep,locfleche,tolesp,First,Last,
Inside,Inside,forward,RecP1,RecS2,RecRst1,SoldepCS);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch1,t_performsurf);//result perf for PerformSurf
#endif
}
First,Last,Inside,Inside,forward,RecP2,RecS1,RecRst2,SoldepCS);
}
else{
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch1); // init perf for PerformSurf
#endif
PerformSurf(SeqSD,HGuide,Spine,Choix,HS1,It1,Or1,
HS2,It2,HC2,HSref2,HCref2,decroch2,MaxStep,locfleche,tolesp,
First,Last,Inside,Inside,forward,RecP2,RecS1,RecRst2,SoldepCS);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch1,t_performsurf); //result perf for PerformSurf
#endif
}
ChFiDS_SequenceOfSurfData LSD;
if(!ChFiKPart_ComputeData::Compute(DStr,SD,HS1,HS2,Or1,Or2,Spine,iedge)){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"failed calculation KPart"<<endl;
#endif
}
else if(!SplitKPart(SD,LSD,Spine,iedge,HS1,It1,HS2,It2,intf,intl)){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"failed calculation KPart"<<endl;
#endif
LSD.Clear();
ChFiDS_ListOfHElSpine& ll = Spine->ChangeElSpines();
ChFiDS_ListIteratorOfListOfHElSpine ILES(ll);
for ( ; ILES.More(); ILES.Next()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(ChFi3d_GettraceCHRON()) elspine.Start();
#endif
ChFi3d_PerformElSpine(ILES.Value(),Spine,myConti,tolesp);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(ChFi3d_GettraceCHRON()) { elspine.Stop(); }
#endif
}
ChFiDS_ListOfHElSpine& ll = Spine->ChangeElSpines();
ChFiDS_ListIteratorOfListOfHElSpine ILES(ll);
for ( ; ILES.More(); ILES.Next()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(ChFi3d_GettraceCHRON()) { chemine.Start(); }
#endif
PerformSetOfSurfOnElSpine(ILES.Value(),Stripe,It1,It2,Simul);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(ChFi3d_GettraceCHRON()) chemine.Stop();
#endif
}
ChFi3d_ReparamPcurv(0.,1.,PC1);
ChFi3d_ReparamPcurv(0.,1.,PC2);
Handle(Geom_Surface) newsurf = fil.Surface();
-#ifdef DEB
+#ifdef OCCT_DEBUG
#ifdef DRAW
//POP for NT
char* pops = "newsurf";
}
else if(IF < IL){
TColStd_Array1OfReal wv(IF,IL - 1);
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"length of the trajectory : "<<(WL-WF)<<endl;
#endif
for(i = IF; i < IL; i++){
Standard_Real wi = Spine->LastParameter(iloc);
if(periodic) wi = ElCLib::InPeriod(wi,WF,WF+period);
gp_Pnt pv = Spine->Value(wi);
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
gp_Pnt pelsapp = curels.Value(wi);
Standard_Real distinit = pv.Distance(pelsapp);
cout<<"distance psp/papp : "<<distinit<<endl;
wv(i) = ext.Point().Parameter();
}
else {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"fail of projection vertex ElSpine!!!"<<endl;
#endif
}
{
TopOpeBRepDS_DataStructure& DStr = myDS->ChangeDS();
-#ifdef DEB
+#ifdef OCCT_DEBUG
OSD_Chronometer ch;
ChFi3d_InitChron(ch);// init perf for PerformSetOfKPart
#endif
Stripe->SetSolidIndex(SI);
if(!sp->SplitDone()) PerformSetOfKPart(Stripe,Simul);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch ,t_perfsetofkpart); // result perf PerformSetOfKPart(
ChFi3d_InitChron(ch); // init perf for PerformSetOfKGen
#endif
PerformSetOfKGen(Stripe,Simul);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch, t_perfsetofkgen);//result perf PerformSetOfKGen
ChFi3d_InitChron(ch); // init perf for ChFi3d_MakeExtremities
#endif
if(!Simul) ChFi3d_MakeExtremities(Stripe,DStr,myEFMap,tolesp,tol2d);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch, t_makextremities); // result perf t_makextremities
#endif
}
#include <TopTools_ListOfShape.hxx>
#include <TopTools_ListIteratorOfListOfShape.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
// For measurements.
#include <OSD_Chronometer.hxx>
//static OSD_Chronometer appclock;
static Standard_Integer IndexOfConge = 0;
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean ChFi3d_GettraceDRAWFIL();
extern Standard_Boolean ChFi3d_GettraceDRAWWALK();
extern Standard_Boolean ChFi3d_GetcontextNOOPT();
else if(IsVois(curE,Vref,VEMap,DONE,prof+1,profmax)) return Standard_True;
}
const TopTools_ListOfShape& L2 = VEMap(V2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer i2 = nbedconnex(L2);
#endif
TopTools_ListIteratorOfListOfShape It2(L2);
}
else {
//(2) Intersection
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<< "CompParam : bad intersection parameters"<<endl;
#endif
IntRes2d_IntersectionPoint int2d;
if (!Intersection.IsEmpty()){
nbseg = Intersection.NbSegments();
if ( nbseg > 0 ){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<< "segments of intersection on the restrictions"<<endl;
#endif
}
if(!found){
// (3) Projection...
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"CompParam : failed intersection PC, projection is created."<<endl;
#endif
parc = prefarc;
// This happens in some cases when there is a vertex
// at the end of spine...
ptg = preftg;
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"CompParam : failed proj p2d/c2d, the extremity is taken!" <<endl;
#endif
}
tolappangle, // Contact G1
myConti, Degmax, Segmax);
if (!approx.IsDone()) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout << "Approximation non faite !!!" << endl;
#endif
return Standard_False;
}
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
approx.Dump(cout);
#endif
return StoreData( Data, approx, lin, S1, S2, Or1, Gd1, Gd2, Gf1, Gf2, Reversed);
tolappangle, // Contact G1
myConti);
if (!approx.IsDone()) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout << "Approximation is not done!" << endl;
#endif
return Standard_False;
}
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
approx.Dump(cout);
#endif
tolappangle, // Contact G1
myConti);
if (!approx.IsDone()) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout << "Approximation non faite !!!" << endl;
#endif
return Standard_False;
}
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
approx.Dump(cout);
#endif
chc.Load(Crv3d1,par1,par2);
if(!ChFi3d_CheckSameParameter(checkcurve,PCurveOnFace,S1,tolC1,tolcheck)){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"aaproximate tolerance under-valued : "<<tolC1<<" for "<<tolcheck<<endl;
#endif
tolC1 = tolcheck;
approx.Curves2dDegree());
chc.Load(Crv3d2,par1,par2);
if(!ChFi3d_CheckSameParameter(checkcurve,PCurveOnFace,S2,tolC2,tolcheck)){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"approximate tolerance under-evaluated : "<<tolC2<<" for "<<tolcheck<<endl;
#endif
tolC2 = tolcheck;
if(!TheWalk.PerformFirstSection(Func,FInv,FInvP,FInvC,PFirst,Target,Soldep,
tolesp,TolGuide,RecRst,RecP,RecS,
NewFirst,ParSol)){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"ChFi3d_Builder::ComputeData : calculation fail first section"<<endl;
#endif
return Standard_False;
MS,TolGuide,ParSol,tolesp,Fleche,Appro);
if (!TheWalk.IsDone()) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout << "Path not created" << endl;
#endif
return Standard_False;
if (reverse) {
if (!TheWalk.Complete(Func,FInv,FInvP,FInvC,SpLast)) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout << "Not completed" << endl;
#endif
}
Nbpnt = Lin->NbPoints();
if (Nbpnt <= 1 && again == 0) {
again++;
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"one point of the path MS/50 is attempted."<<endl;
#endif
MS = MS/50.; Target = Targetsov;
}
else if (Nbpnt<=nbptmin && again == 0) {
again++;
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"Number of points is too small, the step is reduced"<<endl;
#endif
Standard_Real u1 = Lin->Point(1).Parameter();
Target = Targetsov;
}
else if(Nbpnt<=nbptmin){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"Number of points is still too small, quit"<<endl;
#endif
return Standard_False;
if (!TheWalk.PerformFirstSection(Func, FInv1, FInvP1, FInv2, FInvP2, PFirst, Target, Soldep,
tolesp, TolGuide, RecRst1, RecP1, RecRst2, RecP2,
NewFirst, ParSol)){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"ChFi3d_Builder::ComputeData : fail calculation first section"<<endl;
#endif
return Standard_False;
MS, TolGuide, ParSol, tolesp, Fleche, Appro);
if (!TheWalk.IsDone()) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout << "Path not done" << endl;
#endif
return Standard_False;
if (reverse) {
if (!TheWalk.Complete(Func, FInv1, FInvP1, FInv2, FInvP2, SpLast)) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout << "Not completed" << endl;
#endif
}
Nbpnt = Lin->NbPoints();
if (Nbpnt <= 1 && again == 0) {
again++;
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"one point of path MS/50 is attempted."<<endl;
#endif
MS = MS/50.; Target = Targetsov;
}
else if (Nbpnt<=nbptmin && again == 0) {
again++;
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"Number of points is too small, the step is reduced"<<endl;
#endif
Standard_Real u1 = Lin->Point(1).Parameter();
Target = Targetsov;
}
else if(Nbpnt<=nbptmin){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"Number of points is still too small, quit"<<endl;
#endif
return Standard_False;
if(!TheWalk.PerformFirstSection(Func,FInv,FInvP,FInvC,PFirst,Target,Soldep,
tolesp,TolGuide,RecRst,RecP,RecS,
NewFirst,ParSol)){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"ChFi3d_Builder::SimulData : fail calculate first section"<<endl;
#endif
TheWalk.Perform (Func,FInv,FInvP,FInvC,NewFirst,Last,
MS,TolGuide,ParSol,tolesp,Fleche,Appro);
if (!TheWalk.IsDone()) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout << "Path not done" << endl;
#endif
return Standard_False;
}
if (reverse) {
if (!TheWalk.Complete(Func,FInv,FInvP,FInvC,SpLast)) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout << "Not completed" << endl;
#endif
}
Nbpnt = Lin->NbPoints();
if (Nbpnt <= 1 && again == 0) {
again++;
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"one point of path MS/50 is attempted."<<endl;
#endif
MS = MS/50.; Target = Targetsov;
}
else if (Nbpnt <= NbSecMin && again == 0) {
again++;
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"Number of points is too small, the step is reduced"<<endl;
#endif
Standard_Real u1 = Lin->Point(1).Parameter();
Target = Targetsov;
}
else if(Nbpnt<=NbSecMin){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"Number of points is still too small, quit"<<endl;
#endif
return Standard_False;
if(!TheWalk.PerformFirstSection(Func, FInv1, FInvP1, FInv2, FInvP2, PFirst, Target, Soldep,
tolesp, TolGuide, RecRst1, RecP1, RecRst2, RecP2,
NewFirst,ParSol)){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"ChFi3d_Builder::SimulData : calculation fail first section"<<endl;
#endif
TheWalk.Perform (Func, FInv1, FInvP1, FInv2, FInvP2, NewFirst, Last,
MS, TolGuide, ParSol, tolesp, Fleche, Appro);
if (!TheWalk.IsDone()) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout << "Path not created" << endl;
#endif
return Standard_False;
}
if (reverse) {
if (!TheWalk.Complete(Func, FInv1, FInvP1, FInv2, FInvP2, SpLast)) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout << "Not completed" << endl;
#endif
}
Nbpnt = Lin->NbPoints();
if (Nbpnt <= 1 && again == 0) {
again++;
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"only one point of path MS/50 is attempted."<<endl;
#endif
MS = MS/50.; Target = Targetsov;
}
else if (Nbpnt <= NbSecMin && again == 0) {
again++;
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"Number of points is too small, the step is reduced"<<endl;
#endif
Standard_Real u1 = Lin->Point(1).Parameter();
Target = Targetsov;
}
else if(Nbpnt<=NbSecMin){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"Number of points is still too small, quit"<<endl;
#endif
return Standard_False;
if(!TheWalk.PerformFirstSection(Func,FInv,PFirst,Target,Soldep,
tolesp,TolGuide,RecOnS1,RecOnS2,
NewFirst,ParSol)){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"ChFi3d_Builder::ComputeData : calculation fail first section"<<endl;
#endif
return Standard_False;
TheWalk.Perform(Func,FInv,NewFirst,Target,MS,TolGuide,
ParSol,TolEsp,Fleche,Appro);
if (!TheWalk.IsDone()) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout << "Path is not created" << endl;
#endif
return Standard_False;
Standard_Boolean complmnt = Standard_True;
if (Inside) complmnt = TheWalk.Complete(Func,FInv,SpLast);
if(!complmnt){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout << "Not completed" << endl;
#endif
return Standard_False;
//- if one has gone far enough.
Nbpnt = Lin->NbPoints();
if (Nbpnt == 0){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"0 point of path, quit."<<endl;
#endif
return Standard_False;
//It drags, the controls are extended, it is expected to evaluate a
//satisfactory maximum step. If it already done, quit.
if(tchernobyl){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"If it drags without control, quit."<<endl;
#endif
return Standard_False;
tchernobyl = Standard_True;
TheWalk.Check(0);
if (Nbpnt == 1){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"only one point of path MS/100 is attempted"<<endl;
cout <<"and the controls are extended."<<endl;
#endif
MS *= 0.01;
}
else{
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"It drags, the controls are extended."<<endl;
#endif
MS = (lpointpar-fpointpar)/Nbpnt; //EvalStep(Lin);
}
else if (Nbpnt < nbptmin){
if(again == 0){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"Number of points is too small, the step is reduced"<<endl;
#endif
u1sov = fpointpar;
else if(again == 1){
if(Abs(fpointpar-u1sov)>=TolGuide ||
Abs(lpointpar-u2sov)>=TolGuide){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"Number of points is still too small, the step is reduced"<<endl;
#endif
MS = (lpointpar - fpointpar) * factor;
}
else{
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"Number of points is still too small, quit"<<endl;
#endif
return Standard_False;
if(TheWalk.TwistOnS1()){
Data->TwistOnS1(Standard_True);
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"Path completed, but TWIST on S1"<<endl;
#endif
}
if(TheWalk.TwistOnS2()){
Data->TwistOnS2(Standard_True);
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"Parh completed, but TWIST on S2"<<endl;
#endif
}
if(!TheWalk.PerformFirstSection(Func,FInv,PFirst,Target,Soldep,
tolesp,TolGuide,RecOnS1,RecOnS2,
NewFirst,ParSol)){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"ChFi3d_Builder::SimulData : calculation fail first section"<<endl;
#endif
return Standard_False;
ParSol,TolEsp,Fleche,Appro);
if (!TheWalk.IsDone()) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout << "Path not created" << endl;
#endif
return Standard_False;
Standard_Boolean complmnt = Standard_True;
if (Inside) complmnt = TheWalk.Complete(Func,FInv,SpLast);
if(!complmnt){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout << "Not completed" << endl;
#endif
return Standard_False;
Nbpnt = Lin->NbPoints();
Standard_Real factor = 1./(NbSecMin + 1);
if (Nbpnt == 0){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"0 point of path, quit."<<endl;
#endif
return Standard_False;
}
else if (Nbpnt == 1 && again == 0) {
again++;
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"only one point of path, MS/100 is attempted."<<endl;
#endif
MS *= 0.01; Target = Targetsov;
}
else if (Nbpnt< NbSecMin && again == 0) {
again++;
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"Number of points is too small, the step is reduced"<<endl;
#endif
Standard_Real u1 = u1sov = Lin->Point(1).Parameter();
Standard_Real u2 = Lin->Point(Nbpnt).Parameter();
if(Abs(u1-u1sov)>=TolGuide || Abs(u2-u2sov)>=TolGuide){
again++;
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"Number of points is still too small, the step is reduced"<<endl;
#endif
MS /= 100;
Target = Targetsov;
}
else{
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"Number of points is still too small, quit"<<endl;
#endif
return Standard_False;
}
}
else if(Nbpnt < NbSecMin){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout <<"Number of points is still too small, quit"<<endl;
#endif
return Standard_False;
#include <TColStd_Array1OfReal.hxx>
#include <TColStd_Array1OfInteger.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
# ifdef DRAW
#include <OSD_Chronometer.hxx>
#include <DrawTrSurf.hxx>
{
TopOpeBRepDS_DataStructure& DStr = myDS->ChangeDS();
-#ifdef DEB
+#ifdef OCCT_DEBUG
OSD_Chronometer ch;// init perf for PerformSetOfKPart
#endif
// the top,
Fop = TopoDS::Face(DStr.Shape(Fd->Index(IFopArc)));
TopExp_Explorer ex;
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch); // init perf condition if (onsame)
#endif
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch,t_same); // result perf condition if (same)
ChFi3d_InitChron(ch); // init perf condition if (inters)
#endif
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch ,t_inter); //result perf condition if (inter)
ChFi3d_InitChron(ch); // init perf condition if (onsame && inters)
#endif
if (!CV2.IsVertex())
ChFi3d_SetPointTolerance(DStr,box2,stripe->IndexPoint(isfirst,2));
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch, t_sameinter);//result perf condition if (same &&inter)
#endif
}
// - top has 3 edges and fillet on one of edges touches
// more than one face
-#ifdef DEB
+#ifdef OCCT_DEBUG
OSD_Chronometer ch;// init perf
#endif
if (Ishape1 > 0) {
trafil1 = DStr.Shape(Ishape1).Orientation();
}
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
else {
cout<<"erreur"<<endl;
}
trafil1 = TopAbs::Compose(TopAbs::Reverse(Fi1.Transition()),trafil1);
}
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
else cout<<"erreur"<<endl;
#endif
// eap, Apr 22 2002, occ 293
const TopoDS_Face& Favoid) const
{
if (P1.IsVertex() || P2.IsVertex()) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"change of face on vertex"<<endl;
#endif
}
}
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean ContainsV = Standard_False;
if (Found) {
for(It.Initialize(myVFMap(V));It.More();It.Next()) {
{
TopOpeBRepDS_DataStructure& DStr = myDS->ChangeDS();
-#ifdef DEB
+#ifdef OCCT_DEBUG
OSD_Chronometer ch;// init perf pour PerformSetOfKPart
#endif
// The fillet is returned,
Fop = TopoDS::Face(DStr.Shape(Fd->Index(IFopArc)));
TopExp_Explorer ex;
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch); // init perf condition
#endif
{
pced->ChangeCurve2d().Initialize(CPadArc.Arc(),Fv);
Update(HBs,pced,HGs,FiadArc,CPadArc,isfirst);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch,t_same); // result perf condition if (same)
ChFi3d_InitChron(ch); // init perf condition if (inters)
#endif
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch ,t_inter); //result perf condition if (inter)
ChFi3d_InitChron(ch); // init perf condition if ( inters)
#endif
if (!CV2.IsVertex())
ChFi3d_SetPointTolerance(DStr,box2,stripe->IndexPoint(isfirst,2));
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch, t_sameinter);//result perf condition if (same &&inter)
#endif
}
Standard_Boolean isfirst2 = (Sens2 == 1);
Stat1 = Corner1->Spine()->Status(isfirst1);
Stat2 = Corner2->Spine()->Status(isfirst2);
-/*#ifdef DEB
+/*#ifdef OCCT_DEBUG
Standard_Boolean evolcoin = ((Stat1 == ChFiDS_OnSame && Stat2 == ChFiDS_OnDiff) ||
(Stat2 == ChFiDS_OnSame && Stat1 == ChFiDS_OnDiff));
#endif*/
UIntPC1,UIntPC2,FaCo,SameSide,
IFaCo1,IFaCo2,Okvisavis,Vtx,Standard_True);
if (!Okvisavis) {
-#if CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"TwoCorner : pas de face commune"<<endl;
#endif
done=Standard_False;
}
if (!Okvisavis) {
-#if CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"TwoCorner : no common face"<<endl;
#endif
done=Standard_False;
return done;
}
if (!OkinterCC) {
-#if CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"biseau : failed intersection of tangency lines on common face"<<endl;
#endif
done=Standard_False;
ChFiDS_CommonPoint& CP2 = Fd2->ChangeVertex(isfirst2,IFaArc2);
if (!CP1.IsOnArc() || !CP2.IsOnArc()) {
-#if CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"fail 1 of 2 fillets are not on arc"<<endl;
#endif
done=Standard_False;
}
if ( ! CP1.Arc().IsSame( CP2.Arc()) ) {
// look like OnSame + OnDiff case (eap, Arp 9 2002, occ266)
-#if CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"PerformTwoCornerbyInter(): fillets are not on the same arc"<<endl;
#endif
done = Standard_True;
}
}
if(!ok1 || !ok2){
-#if CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"fail one of surfaces has no common base face with the pivot edge"<<endl;
#endif
done=Standard_False;
if (IFaCo1 == 1 &&
!ChFi3d_ComputeCurves(HS1,HS2,Pardeb,Parfin,Gc,
PGc1,PGc2,tolesp,tol2d,tolreached)) {
-#if CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"failed to calculate bevel error interSS"<<endl;
#endif
done=Standard_False;
else if (IFaCo1 == 2 &&
!ChFi3d_ComputeCurves(HS1,HS2,Parfin,Pardeb,Gc,
PGc1,PGc2,tolesp,tol2d,tolreached)) {
-#if CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"failed to calculate bevel error interSS"<<endl;
#endif
done=Standard_False;
Reduce(UIntPCSma,UIntPCBig,Hctg);
}
if(!ChFi3d_IntCS(BigHS,Hctg,UVi,wi)){
-#if CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"bevel : failed inter C S"<<endl;
#endif
done=Standard_False;
Standard_Real tolreached;
if (!ChFi3d_ComputeCurves(SmaHS,BigHS,Pardeb,Parfin,Gc,
PGc1,PGc2,tolesp,tol2d,tolreached)) {
-#if CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"failed to calculate bevel failed interSS"<<endl;
#endif
done=Standard_False;
Adaptor3d_CurveOnSurface consf(c2df,HF);
Handle(Adaptor3d_HCurveOnSurface) Hconsf = new Adaptor3d_HCurveOnSurface(consf);
if(!ChFi3d_IntCS(BigHS,Hconsf,UVi,wi)) {
-#if CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"bevel : failed inter C S"<<endl;
#endif
done=Standard_False;
if (!ChFi3d_ComputeCurves(HF,BigHS,Pardeb,Parfin,Gc,
PGc1,PGc2,tolesp,tol2d,tolreached)) {
-#if CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"fail calculation bevel fail interSS"<<endl;
#endif
done=Standard_False;
#include <BRepLib_MakeFace.hxx>
#include <Precision.hxx>
// performances
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <OSD_Chronometer.hxx>
extern Standard_Real t_plate ,t_approxplate,t_batten;
extern void ChFi3d_InitChron(OSD_Chronometer& ch);
FairCurve_AnalysisCode Iana;
Standard_Boolean Ok;
Ok = Bat.Compute(Iana,25,1.e-2);
-#if CHFI3D_DEB
+#ifdef OCCT_DEBUG
if (!Ok) {
cout<<"no batten :";
Bat.Dump(cout);
ChFiDS_CommonPoint& Com12= stripe1->SetOfSurfData()->Value(index1)->ChangeVertex (isfirst,2);
isfirst=sens2==1;
ChFiDS_CommonPoint& Com21= stripe2->SetOfSurfData()->Value(index2)->ChangeVertex (isfirst,1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// ChFiDS_CommonPoint& Com22=
// stripe2->SetOfSurfData()->Value(index2)->ChangeVertex (isfirst,2);
#endif
// ========================================
// Initialisations
// ========================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
OSD_Chronometer ch;
#endif
TopOpeBRepDS_DataStructure& DStr=myDS->ChangeDS();
Standard_Integer num;
TopoDS_Edge Ecur;
TopTools_ListIteratorOfListOfShape ItF;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nface=ChFi3d_nbface(myVFMap(V1));
#endif
TopoDS_Face F1,F2;
isOnSameDiff = isOnSame && isOnDiff;
}
if ( isOnSameDiff ) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout << "OnSame + OnDiff, PerformMoreThreeCorner() calls PerformOneCorner()" << endl;
#endif
PerformOneCorner (Jndex, Standard_True);
Standard_Boolean contraint1=Standard_True,
contraint2=Standard_True;
if (raccordbatten) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch);// initial performances for battens
#endif
Standard_Boolean inverseic,inverseicplus;
contraint2=Standard_False;
CalculBatten(Asurf,TopoDS::Face(Fvive(ic,icplus)),xdir,ydir,p2d1,p2d2,contraint1,contraint2,curv2d1,curv2d2,p.Value(ic,icplus),
p.Value(icplus,ic),inverseic,inverseicplus,pcurve);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron( ch,t_batten); // resulting performances for battens
#endif
}
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch); // init performances for plate
#endif
PSurf.Perform();
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch, t_plate); //result performances for plate
#endif
// call of approx
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch); // init performances for approxplate
#endif
if (PSurf.IsDone()) {
Standard_Real coef = 1.1 ,apperror;
apperror=Mapp.CriterionError()*coef;
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch, t_approxplate); // result performances for approxplate
#endif
// Storage of the surface plate and corresponding curves in the DS
TopAbs_Orientation orplate,orsurfdata,orpcurve,orien;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Real ang1=PSurf.G1Error();
#endif
// gp_Vec n1,n2,du,dv,du1,dv1;
#include <ChFi3d_Builder.jxx>
#include <ChFi3d_Builder_0.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean ChFi3d_GettraceDRAWFIL();
extern void ChFi3d_CheckSurfData(const TopOpeBRepDS_DataStructure& DStr,
const Handle(ChFiDS_SurfData)& Data);
Standard_Real tolc = CE.Resolution(tol);
found = ChFi3d_InterPlaneEdge(plan,HE,Nl,First,tolc);
gp_Pnt point = CE.Value(Nl);
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"******* ParamOnSpine() for edge "<<iedge<<endl;
cout<<Nl<<endl;
cout<<"point ped "<<point.X()<<" "<<point.Y()<<" "<<point.Z()<<endl;
#endif
if(found) Nl = Spine->Absc(Nl,ii);
point = Spine->Value(Nl);
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
if (found) cout << "found by edge " << ii << " : ";
cout<<Nl<<endl;
cout<<"point psp "<<point.X()<<" "<<point.Y()<<" "<<point.Z()<<endl;
}
if (iSansFirst != 0) {
if (iSansLast == 0) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"Parsing : Pb of Hatcher"<<endl;
#endif
return 0;
if(!H1.IsDone(iH1)) return 0;
Nb1 = H1.NbDomains(iH1);
if(Nb1 == 0) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"SplitKPart : tangency line out of the face"<<endl;
#endif
return Standard_False;
if(!H2.IsDone(iH2)) return 0;
Nb2 = H2.NbDomains(iH2);
if(Nb2 == 0) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"SplitKPart : tangency line out of the face"<<endl;
#endif
return Standard_False;
// situation, eap occ354
if (C1.IsNull() && C2.IsNull()) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"SplitData : 2 zero lines hatching impossible"<<endl;
#endif
return Standard_False;
onS = 1;
else
onS = 2;
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
if (threeE[0].IsSame(threeE[1]))
cout << "SplitKPart(), wrong corner vertex at switcher search" << endl;
#endif
onS = 1;
else
onS = 2;
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
if (threeE[0].IsSame(threeE[1]))
cout << "SplitKPart(), wrong corner vertex at switcher search" << endl;
#endif
SetData.Remove(i+1,SetData.Length());
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(ChFi3d_GettraceDRAWFIL()) {
for (i = 1; i <= SetData.Length(); i++) {
ChFi3d_CheckSurfData(DStr,SetData.Value(i));
#include <Standard_NotImplemented.hxx>
#include <Standard_DomainError.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean ChFi3d_GettraceCHRON();
#endif
void ChFi3d_ChBuilder::Simulate (const Standard_Integer IC)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(ChFi3d_GettraceCHRON()){
simul.Reset();elspine.Reset();chemine.Reset();
simul.Start();
break;
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(ChFi3d_GettraceCHRON()){
simul.Stop();
cout<<"Total simulation time : ";
if (inter.IsDone()) {
Standard_Integer nbl = inter.NbLines();
if (nbl > 1) {
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"trop d'intersection entre les surfaces"<<endl;
#endif
}
#include <DBRep.hxx>
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
OSD_Chronometer simul,elspine,chemine;
#endif
#include <Standard_ConstructionError.hxx>
#include <Standard_Failure.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean ChFi3d_GettraceCHRON();
extern Standard_Real t_computedata ,t_completedata;
Handle(ChFiDS_HElSpine) HGuide = fsp->ElSpine(IE);
Standard_Real la = HGuide->LastParameter(), fi = HGuide->FirstParameter();
Standard_Real longueur = la - fi, temp, w;
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
Standard_Real radiussect = 0.;
//#else
// Standard_Real radiussect;
void ChFi3d_FilBuilder::Simulate (const Standard_Integer IC)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(ChFi3d_GettraceCHRON()){
simul.Reset();elspine.Reset();chemine.Reset();
simul.Start();
break;
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(ChFi3d_GettraceCHRON()){
simul.Stop();
cout<<"Total simulation time : ";
if(fsp.IsNull()) Standard_ConstructionError::Raise
("SimulSurf : this is not the spine of the fillet");
Handle(BRepBlend_Line) lin;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// TopAbs_Orientation Or = S1->ChangeSurface().Face().Orientation();
#endif
// Flexible parameters!!!
Standard_Boolean& intf,
Standard_Boolean& intl)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OSD_Chronometer ch;
#endif
Handle(ChFiDS_SurfData) Data = SeqData(1);
FInv.Set(fsp->Radius(),Choix);
Func.Set(myShape);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch); //init perf ComputeData
#endif
Inside,Appro,Forward,Soldep,intf,intl,
gd1,gd2,gf1,gf2,RecOnS1,RecOnS2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch , t_computedata);// result perf ComputeData
#endif
if(!done) return Standard_False; // recovery is possible PMN 14/05/1998
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch);// init perf CompleteData
#endif
done = CompleteData(Data,Func,lin,S1,S2,Or,gd1,gd2,gf1,gf2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch , t_completedata);// result perf CompleteData
#endif
FInv.Set(Choix);
Func.Set(myShape);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch);// init perf ComputeData
#endif
PFirst,MaxStep,Fleche,TolGuide,First,Last,
Inside,Appro,Forward,Soldep,intf,intl,
gd1,gd2,gf1,gf2,RecOnS1,RecOnS2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch , t_computedata); //result perf ComputeData
#endif
if(!done) return Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch);// init perf CompleteData
#endif
done = CompleteData(Data,Func,lin,S1,S2,Or,gd1,gd2,gf1,gf2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch , t_completedata);// result perf CompleteData
#endif
#ifdef DRAW
#include <DrawTrSurf.hxx>
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <Geom_TrimmedCurve.hxx>
extern Standard_Boolean ChFi3d_GettraceDRAWSPINE();
extern Standard_Boolean ChFi3d_GetcontextFORCEFILLING();
void ChFi3d_FilBuilder::PerformTwoCorner(const Standard_Integer Index)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OSD_Chronometer ch;
ChFi3d_InitChron(ch); // init perf initialisation
#endif
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch ,t_t2cornerinit);//result perf initialisation
#endif
ChFiDS_FaceInterference intf11,intf12,intf21,intf22;
if(c1biseau){
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch); // init perf PerformTwoCornerbyInter
#endif
done = PerformTwoCornerbyInter(Index);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch , t_perf2cornerbyinter); // result perf PerformTwoCornerbyInter
#endif
intf12 = sd1->InterferenceOnS2();
intf21 = sd2->InterferenceOnS1();
intf22 = sd2->InterferenceOnS2();
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch); // init perf PerformTwoCornerbyInter
#endif
done = PerformTwoCornerbyInter(Index);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch , t_perf2cornerbyinter); // result perf PerformTwoCornerbyInter
#endif
if (!done) {
if(yapiv) bid = ChFi3d::ConcaveSide(BRS1,BRS2,pivot,op1,op2);
op1 = TopAbs::Reverse(op1);
op2 = TopAbs::Reverse(op2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch);// init perf ChFiKPart_ComputeData
#endif
Standard_Real radius =
Handle(ChFiDS_FilSpine)::DownCast(st1->Spine())->Radius();
done = ChFiKPart_ComputeData::ComputeCorner(DStr,coin,HFaCo,HBRS1,HBRS2,
OFaCo,ori,op1,op2,radius);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch , t_chfikpartcompdata);//result perf ChFiKPart_ComputeData
#endif
}
p2da2 = sd2->Interference(IFaArc2).PCurveOnSurf()->Value(uPCArc2);
p2df2 = sd2->Interference(IFaCo2).PCurveOnSurf()->Value(uPCArc2);
sd2->Interference(IFaCo2).PCurveOnFace()->D1(uPCArc2,p2dfac2,v2dfac2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch ); // init perf filling
#endif
B1 = ChFi3d_mkbound(surf1,p2df1,p2da1,tolesp,2.e-4);
HFaCo,PCurveOnFace,
HFaPiv,PCurveOnPiv,OFaCo,1,
0,0,0,0);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch , t_remplissage);// result perf filling
#endif
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch); // init perf update DS
#endif
if (done){
sd2->ChangeInterference(IFaCo2).SetParameter(par2,isfirst2);
if (IFaCo2 == 2) st2->SetOrientation(TopAbs_REVERSED,isfirst2);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch , t_t2cornerDS);// result perf update DS
#endif
}
("TwoCorner : No common face to loop the contour");
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch ); // init perf filling
#endif
Handle(GeomFill_Boundary) Bsam,Bdif,Bfac;
Hsurfsam,pcsurfsam,
HBRFopsam,pcnul,Osurfsam,1,
0,0,0,0);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch , t_remplissage);// result perf filling
#endif
if(!done) Standard_Failure::Raise("concavites inverted : fail");
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch); // init perf update DS
#endif
// Update 3 CornerData and the DS
sddif->ChangeVertex(isfirstdif,ifacodif) = Pl1;
sddif->ChangeInterference(ifacodif).SetParameter(uintpcdif,isfirstdif);
if (ifaopdif == 1) stdif->SetOrientation(TopAbs_REVERSED,isfirstdif);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch , t_t2cornerDS);// result perf update DS
#endif
}
#ifdef DRAW
#include <DrawTrSurf.hxx>
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <Geom_TrimmedCurve.hxx>
extern Standard_Boolean ChFi3d_GettraceDRAWSPINE();
extern Standard_Boolean ChFi3d_GetcontextSPINEBEZIER();
void ChFi3d_FilBuilder::PerformThreeCorner(const Standard_Integer Jndex)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OSD_Chronometer ch;
ChFi3d_InitChron(ch); // init perf initialisation
#endif
// 3 concavities identic.
pivot = SearchPivot(sens,p,tol2d);
if(pivot < 0){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"pivot not found, plate is called"<<endl;
#endif
PerformMoreThreeCorner(Jndex, 3);
ifacdeb = CD[deb]->ChangeSetOfSurfData()->Value(i[deb][pivot])->Index(3-jf[deb][pivot]);
ifacfin = CD[fin]->ChangeSetOfSurfData()->Value(i[fin][pivot])->Index(3-jf[fin][pivot]);
if(ifacfin != ifacdeb){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"several base faces, plate is called"<<endl;
#endif
PerformMoreThreeCorner(Jndex, 3);
return;
}
if(i[pivot][deb] != i[pivot][fin]){
-#ifdef CHFI3D_DEB
+#ifdef OCCT_DEBUG
cout<<"load surfdata on the pivot, plate is called"<<endl;
#endif
PerformMoreThreeCorner(Jndex, 3);
Interference(jf[pivot][fin]).PCurveOnSurf()->Value(p[pivot][fin]);
done = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(ChFi3d_GetcontextFORCEFILLING()) c1spheric = c1toric = 0;
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch , t_t3cornerinit); // result perf initialisations
#endif
if (c1toric){
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch); // init perf case torus
#endif
done = ChFiKPart_ComputeData::ComputeCorner
(DStr,coin,Fac,Surf,oo1,oo2,o1,o2,Rdeb,Rdp,pfac1,pfac2,psurf1,psurf2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch , t_torique); // result perf case torus
#endif
}
else if(c1spheric){
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch); //init perf case sphere
#endif
done = ChFiKPart_ComputeData::ComputeCorner
(DStr,coin,Fac,Surf,oo1,oo2,o1,o2,Rdp,pfac1,psurf1,psurf2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch , t_spherique);// result perf cas sphere
#endif
if(!done){
if(!filling) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch);// init perf not filling
#endif
done = ComputeData(coin,cornerspine,NullSpine,lin,Fac,IFac,Surf,ISurf,
func,finv,ffi,pasmax,locfleche,TolGuide,ffi,lla,
0,0,1,Soldep,intf,intl,Gd1,Gd2,Gf1,Gf2,0,1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(ChFi3d_GetcontextFORCEFILLING()) done = 0;
#endif
if(done && Gf2){
done = ComputeData(coin,cornerspine,NullSpine,lin,Fac,IFac,Surf,ISurf,
func,finv,ffi,pasmax,locfleche,TolGuide,ffi,lla,
0,0,1,Soldep,intf,intl,Gd1,Gd2,Gf1,Gf2,0,1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(ChFi3d_GetcontextFORCEFILLING()) done = 0;
#endif
if(done && Gf2){
else filling = 1;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch , t_notfilling);// result perf not filling
#endif
if(filling) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch); // init perf filling
#endif
Surf,PCurveOnPiv,fdpiv->Orientation(),0,
0,0,0,0);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch , t_filling);// result perf filling
#endif
// Update of 4 Stripes and the DS
// -------------------------------------
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_InitChron(ch);// init perf update DS
#endif
corner->SetSolidIndex(CD[pivot]->SolidIndex());
myListStripe.Append(corner);
-#ifdef DEB
+#ifdef OCCT_DEBUG
ChFi3d_ResultChron(ch , t_t3cornerDS);// result perf update DS
#endif
}
void ChFiDS_Spine::SetFirstParameter(const Standard_Real Par)
{
-#ifdef CHFIDS_DEB
+#ifdef OCCT_DEBUG
if(Par >= Precision::Confusion())
cout<<"Interior extension at the start of guideline"<<endl;
if(IsPeriodic())
void ChFiDS_Spine::SetLastParameter(const Standard_Real Par)
{
-#ifdef CHFIDS_DEB
+#ifdef OCCT_DEBUG
Standard_Real lll = abscissa->Value(abscissa->Upper());
if((Par - lll) <= -Precision::Confusion())
cout<<"Interior extension at the end of guideline"<<endl;
{
if(IsPeriodic()) Standard_Failure::Raise
("No extension by tangent on periodic contours");
-#ifdef CHFIDS_DEB
+#ifdef OCCT_DEBUG
if(W >= Precision::Confusion())
cout<<"Interior extension at start of the guideline"<<endl;
#endif
if(IsPeriodic()) Standard_Failure::Raise
("No extension by tangent periodic contours");
-#ifdef CHFIDS_DEB
+#ifdef OCCT_DEBUG
Standard_Real L = W - abscissa->Value(abscissa->Upper());
if(L <= -Precision::Confusion())
cout<<"Interior extension at the end of guideline"<<endl;
void ChFiDS_Spine::Load()
{
if(!abscissa.IsNull()){
-#ifdef CHFIDS_DEB
+#ifdef OCCT_DEBUG
cout<<"new load of CE"<<endl;
#endif
}
ChamfRad = Spine.Radius() - Dis;
if ( Abs(ChamfRad) < Precision::Confusion() ) pointu = Standard_True;
if( ChamfRad < 0 ) {
-#ifdef CHFIKPART_DEB
+#ifdef OCCT_DEBUG
cout<<"the chamfer can't pass"<<endl;
#endif
return Standard_False;
if (ouvert) {
if (Abs(angCon) - Abs(SemiAngl) > -Precision::Confusion() ) {
-#ifdef CHFIKPART_DEB
+#ifdef OCCT_DEBUG
cout<<"wrong choice of angle for the chamfer"<<endl;
#endif
return Standard_False;
SemiAngl = Abs(angCon) + Angle;
if ( (M_PI / 2. - SemiAngl) < Precision::Confusion() ) {
-#ifdef CHFIKPART_DEB
+#ifdef OCCT_DEBUG
cout <<"wrong choice of angle for the chamfer"<<endl;
#endif
return Standard_False;
if ( Abs(ChamfRad) < Precision::Confusion() ) pointu = Standard_True;
if( ChamfRad < 0 ) {
-#ifdef CHFIKPART_DEB
+#ifdef OCCT_DEBUG
cout<<"the chamfer can't pass"<<endl;
#endif
return Standard_False;
Rad = Cyl.Radius() - dis1;
if ( Abs(Rad) <= Precision::Confusion() ) pointu = Standard_True;
if(Rad < 0 ) {
-#ifdef CHFIKPART_DEB
+#ifdef OCCT_DEBUG
cout<<"the chamfer can't pass"<<endl;
#endif
return Standard_False;
dis2 = temp2 + temp1 * (cosAhOC - temp1);
if (dis2 < -1.E-09) {
-#ifdef CHFIKPART_DEB
+#ifdef OCCT_DEBUG
cout<<"too great angle of chamfer"<<endl;
#endif
return Standard_False;
gp_Pnt Or = Con.Location();
Standard_Real u,v;
ElSLib::PlaneParameters(PosPl,Or,u,v);
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Pnt2d pt2dPln(u,v);
#endif
ElSLib::PlaneD0(u,v,PosPl,Or);
gp_Pnt PtSp;
gp_Vec DSp;
ElCLib::D1(First,Spine,PtSp,DSp);
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Dir Dx(gp_Vec(Or,PtSp));
#endif
//compute the normal to the cone in PtSp
ChamfRad = Spine.Radius() - Dis1;
if ( Abs(ChamfRad)<=Precision::Confusion() ) pointu = Standard_True;
if( ChamfRad < 0 ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
cout<<"le chanfrein ne passe pas"<<endl;
#endif
return Standard_False;
Rad = Cyl.Radius()- Dis1;
if ( Abs(Rad) <= Precision::Confusion() ) pointu = Standard_True;
if(Rad < 0 ) {
-#ifdef CHFIKPART_DEB
+#ifdef OCCT_DEBUG
cout<<"the chamfer can't pass"<<endl;
#endif
return Standard_False;
Rad = Maxrad - Rabio;
if(Abs(Rad) <= Precision::Confusion()){ c1sphere = Standard_True; }
else if(Rad < 0){
-#ifdef CHFIKPART_DEB
+#ifdef OCCT_DEBUG
cout<<"the fillet does not pass"<<endl;
#endif
return Standard_False;
ROff-=Radius;
}
else {
-#ifdef CHFIKPART_DEB
+#ifdef OCCT_DEBUG
cout<<"the fillet does not pass"<<endl;
#endif
return Standard_False;
Rad = cylrad - Radius;
if(Abs(Rad) <= Precision::Confusion()){ c1sphere = Standard_True; }
else if(Rad < 0){
-#ifdef CHFIKPART_DEB
+#ifdef OCCT_DEBUG
cout<<"the fillet can't pass"<<endl;
#endif
return Standard_False;
pp.Z()-delta*di.Z());
dz = gp_Dir(gp_Vec(p1,cen));
if(Abs(ds1.Dot(dz)-1.)>ptol){
-#ifdef CHFIKPART_DEB
+#ifdef OCCT_DEBUG
cout<<"center of the spherical corner not found"<<endl;
#endif
return Standard_False;
if (n == 1) {
disptriangles = !disptriangles;
-#ifdef DBREP_DEB
+#ifdef OCCT_DEBUG
if (disptriangles) cout <<"Triangulations are always displayed"<<endl;
else cout <<"Triangulations are displayed only if there is no geometric representation"<<endl;
#endif
if (n == 1) {
disppolygons = !disppolygons;
-#ifdef DBREP_DEB
+#ifdef OCCT_DEBUG
if (disppolygons) cout <<"Polygons are always displayed"<<endl;
else cout <<"Polygons are displayed only if there is no geometric representation"<<endl;
#endif
GeomAbs_SurfaceType SurfType = S.GetType();
// If the type of the surface is GeomAbs_SurfaceOfExtrusion or GeomAbs_SurfaceOfRevolution
-#ifdef DEB
+#ifdef OCCT_DEBUG
GeomAbs_CurveType CurvType;
#else
GeomAbs_CurveType CurvType = GeomAbs_OtherCurve;
if (PCurve.IsNull())
{
-#ifdef DBREP_DEB
+#ifdef OCCT_DEBUG
cout << "DBRep_IsoBuilder : PCurve is null\n";
#endif
return;
}
else if (U1 == U2)
{
-#ifdef DBREP_DEB
+#ifdef OCCT_DEBUG
cout << "DBRep_IsoBuilder PCurve : U1==U2\n";
#endif
return;
U2 - TrimPCurve->BasisCurve()->LastParameter() > Precision::PConfusion())
{
AddElement (PCurve, TopologicalEdge.Orientation());
-#ifdef DBREP_DEB
+#ifdef OCCT_DEBUG
cout << "DBRep_IsoBuilder TrimPCurve : parameters out of range\n";
cout << " U1(" << U1 << "), Umin(" << PCurve->FirstParameter()
<< "), U2(" << U2 << "), Umax(" << PCurve->LastParameter() << ")\n";
{
if (PCurve->FirstParameter() - U1 > Precision::PConfusion())
{
-#ifdef DBREP_DEB
+#ifdef OCCT_DEBUG
cout << "DBRep_IsoBuilder PCurve : parameters out of range\n";
cout << " U1(" << U1 << "), Umin(" << PCurve->FirstParameter() << ")\n";
#endif
}
if (PCurve->FirstParameter() - U2 > Precision::PConfusion())
{
-#ifdef DBREP_DEB
+#ifdef OCCT_DEBUG
cout << "DBRep_IsoBuilder PCurve : parameters out of range\n";
cout << " U2(" << U2 << "), Umin(" << PCurve->FirstParameter() << ")\n";
#endif
}
if (U1 - PCurve->LastParameter() > Precision::PConfusion())
{
-#ifdef DBREP_DEB
+#ifdef OCCT_DEBUG
cout << "DBRep_IsoBuilder PCurve : parameters out of range\n";
cout << " U1(" << U1 << "), Umax(" << PCurve->LastParameter() << ")\n";
#endif
}
if (U2 - PCurve->LastParameter() > Precision::PConfusion())
{
-#ifdef DBREP_DEB
+#ifdef OCCT_DEBUG
cout << "DBRep_IsoBuilder PCurve : parameters out of range\n";
cout << " U2(" << U2 << "), Umax(" << PCurve->LastParameter() << ")\n";
#endif
aTclScript.AssignCat ( "/dftree.tcl" );
OSD_File aTclScriptFile (aTclScript);
if (aTclScriptFile.Exists()) {
-#ifdef DDF_DEB
+#ifdef OCCT_DEBUG
cout << "Load " << aTclScript << endl;
#endif
di.EvalFile( aTclScript.ToCString() );
ReadChar(l,len);
if (strncmp(DDF_IOStream::MagicNumber(),l.ToCString(),len) != 0) {
-#ifdef DDF_DEB
+#ifdef OCCT_DEBUG
cout<<"BeginReadInfoSection: format error"<<endl;
#endif
s = Storage_VSFormatError;
f.Close();
if (strncmp(DDF_IOStream::MagicNumber(),l.ToCString(),len) != 0) {
-#ifdef DDF_DEB
+#ifdef OCCT_DEBUG
cout<<"IsGoodFileType: format error"<<endl;
#endif
s = Storage_VSFormatError;
#endif
if (!anOS) {
// A problem with the stream
-#ifdef DDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << "Error: problem with the file stream, rdstate = " <<anOS.rdstate() <<endl;
#endif
}
#include <DDataStd_DrawPresentation.hxx>
-// Unused :
-#ifdef BLABLA_DEB
-static void Location (Standard_Integer nb, const char** arg, gp_Ax2& Loc) {
-
- if (nb == 9) {
- Standard_Real X = Draw::Atof(arg[3]);
- Standard_Real Y = Draw::Atof(arg[4]);
- Standard_Real Z = Draw::Atof(arg[5]);
- Standard_Real DX = Draw::Atof(arg[6]);
- Standard_Real DY = Draw::Atof(arg[7]);
- Standard_Real DZ = Draw::Atof(arg[8]);
- Loc = gp_Ax2 (gp_Pnt(X,Y,Z), gp_Dir(DX,DY,DZ));
- }
-}
-#endif
-
-
//=======================================================================
//function : DDataStd_SetPoint
//purpose : SetPoint (DF, entry, [drawpoint])
}
-//=======================================================================
-//function : DDataStd_SetMove
-//purpose :
-//=======================================================================
-
-// static Standard_Integer DDataStd_SetMove (Draw_Interpretor&,
-// Standard_Integer nb,
-// const char** arg)
-// {
-// if (nb < 3) return 1;
-// TDF_Label L;
-// Handle(TDF_Data) DF;
-// if (!DDF::GetDF (arg[1], DF)) return 1;
-// if (!DDF::FindLabel(DF, arg[2], L)) return 1;
-
-// TopLoc_Location Loc;
-// if (nb == 4) {
-// TopoDS_Shape S = DBRep::Get(arg[3]);
-// if (S.IsNull()) return 1;
-// Loc = S.Location();
-// }
-
-// else {
-// if (nb < 6) return 1;
-
-// gp_Trsf T;
-// Standard_Real x = Draw::Atof(arg[3]);
-// Standard_Real y = Draw::Atof(arg[4]);
-// Standard_Real z = Draw::Atof(arg[5]);
-
-// if (nb == 6) {
-// T.SetTranslation(gp_Vec(x,y,z));
-// }
-// else if (nb < 10)
-// return 1;
-// else {
-// Standard_Real dx = Draw::Atof(arg[6]);
-// Standard_Real dy = Draw::Atof(arg[7]);
-// Standard_Real dz = Draw::Atof(arg[8]);
-// Standard_Real ang = Draw::Atof(arg[9]);
-// T.SetRotation(gp_Ax1(gp_Pnt(x,y,z),
-// gp_Vec(dx,dy,dz)),
-// ang * (M_PI / 180.0));
-// }
-// Loc = T;
-// }
-// TDataStd_CoordSys::Move(L,Loc);
-// return 0;
-// }
-
-
-
//=======================================================================
//function : DDataStd_GetPoint
//purpose : GetPoint (DF, entry, [drawname])
// str.Remove(str.Length()); //remove last ":"
// di << str.ToCString();
// }
-// #ifndef DEB
+// #ifndef OCCT_DEBUG
// return 0 ;
// #endif
// }
}
child = TDataStd_TreeNode::Set(L,ID);
if (!father->Append(child)) return 1;
-#ifdef DEB
+#ifdef OCCT_DEBUG
di<<"AppendNode: OK"<<"\n";
#endif
return 0;
}
child = TDataStd_TreeNode::Set(L,ID);
if (!father->Prepend(child)) return 1;
-#ifdef DEB
+#ifdef OCCT_DEBUG
di<<"PrependNode: OK"<<"\n";
#endif
return 0;
TDF_Label Label;
Standard_Boolean Found = DDF::AddLabel (DF, LabelName, Label);
if (!Found) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout <<"no labels"<<endl;
#endif
return S;
Label.FindAttribute(TNaming_NamedShape::GetID(),NS);
S = TNaming_Tool::CurrentShape(NS);
if (S.IsNull())
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout <<"current shape from "<< LabelName <<" is deleted"<<endl;
#endif
return S;
if (theShape.ShapeType() == TopAbs_FACE) {
Handle(Geom_Surface) aSurf = BRep_Tool::Surface(TopoDS::Face(theShape));
-#ifdef OCC_DEB
+#ifdef OCCT_DEBUG
Standard_CString s = aSurf->DynamicType()->Name();
cout<<"Surface Dynamic TYPE = "<<s<<endl;
#endif
Handle(TNaming_NamedShape) anObjectNS;
aLab.FindAttribute(TNaming_NamedShape::GetID(), anObjectNS);
if (anObjectNS.IsNull() || anObjectNS->IsEmpty()) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"BooleanOperationDriver:: Object is empty"<<endl;
#endif
aFunction->SetFailure(WRONG_ARGUMENT);
Handle(TNaming_NamedShape) aToolNS = DNaming::GetObjectValue(aToolObj);
if (aToolNS.IsNull() || aToolNS->IsEmpty()) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"BooleanOperationDriver:: Tool is empty"<<endl;
#endif
aFunction->SetFailure(WRONG_ARGUMENT);
TopoDS_Shape aTOOL = aToolNS->Get();
TopoDS_Shape anOBJECT = anObjectNS->Get();
if (aTOOL.IsNull() || anOBJECT.IsNull()) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"BooleanOperationDriver:: Tool is null"<<endl;
#endif
aFunction->SetFailure(WRONG_ARGUMENT);
return Standard_True;
}
*/
-#ifdef DEB
+#ifdef OCCT_DEBUG
//ModDbgTools_Write(theFace, "Surf");
#endif
return Standard_False;
const TopoDS_Shape& ObjSh = MS.Shape1();
const TopoDS_Shape& ToolSh = MS.Shape2();
if (ResSh.IsNull()) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"LoadFuseNamingDS: The result of the boolean operation is null"<<endl;
#endif
return;
const TopoDS_Shape& ObjSh = MS.Shape1();
const TopoDS_Shape& ToolSh = MS.Shape2();
if (ResSh.IsNull()) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"LoadSectionNamingDS: The result of the boolean operation is null"<<endl;
#endif
return;
{
if (theMkOpe.IsDone() && !theMkOpe.Shape().IsNull()) {
-#ifdef MDTV_DEB
- Standard_CString aFileName = "BoolOp.brep";
- Write(theMkOpe.Shape(), aFileName);
-#endif
if (theMkOpe.Shape().ShapeType() == TopAbs_COMPOUND) {
TopoDS_Iterator anItr(theMkOpe.Shape());
if(!anItr.More()) {
Handle(TDataStd_UAttribute) anObject = DNaming::GetObjectArg(aFunction,CYL_AXIS);
Handle(TNaming_NamedShape) aNSAxis = DNaming::GetObjectValue(anObject);
if (aNSAxis->IsEmpty()) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"CylinderDriver:: Axis is empty"<<endl;
#endif
aFunction->SetFailure(WRONG_AXIS);
}
TopoDS_Shape aTopoDSAxis = aNSAxis->Get();
if (aTopoDSAxis.IsNull()) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"CylinderDriver:: Axis is null"<<endl;
#endif
aFunction->SetFailure(WRONG_AXIS);
}
// Creation of gp axis (gp_Ax2):
if (aTopoDSAxis.ShapeType() != TopAbs_EDGE && aTopoDSAxis.ShapeType() != TopAbs_WIRE) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"CylinderDriver:: Wrong axis, ShapeType = " << aTopoDSAxis.ShapeType() <<endl;
#endif
aFunction->SetFailure(WRONG_AXIS);
anAxis.SetLocation(aP1);
}
} else {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"CylinderDriver:: I don't support wires for a while"<<endl;
#endif
aFunction->SetFailure(WRONG_AXIS);
Handle(TNaming_NamedShape) aContextNS;
aLab.FindAttribute(TNaming_NamedShape::GetID(), aContextNS);
if (aContextNS.IsNull() || aContextNS->IsEmpty()) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"FilletDriver:: Context is empty"<<endl;
#endif
aFunction->SetFailure(WRONG_ARGUMENT);
if(aRadius < Precision::Confusion()) {
aFunction->SetFailure(WRONG_ARGUMENT);
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "FilletDriver:: Radius < Precision::Confusion" << endl;
#endif
return -1;
Handle(TDataStd_UAttribute) aPathObj = DNaming::GetObjectArg(aFunction,FILLET_PATH);
Handle(TNaming_NamedShape) aPathNS = DNaming::GetObjectValue(aPathObj);
if (aPathNS.IsNull() || aPathNS->IsEmpty()) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"FilletDriver:: Path is empty"<<endl;
#endif
aFunction->SetFailure(WRONG_ARGUMENT);
TopoDS_Shape aPATH = aPathNS->Get();
TopoDS_Shape aCONTEXT = aContextNS->Get();
if (aPATH.IsNull() || aCONTEXT.IsNull()) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"FilletDriver:: Path or Context is null"<<endl;
#endif
aFunction->SetFailure(WRONG_ARGUMENT);
#include <TFunction_Function.hxx>
#include <DNaming.hxx>
#include <ModelDefinitions.hxx>
-
-#ifdef WNT
-#define EXCEPTION ...
-#else
-#define EXCEPTION Standard_Failure
-#endif
-//#define MDTV_DEB 1
-
-#ifdef MDTV_DEB
-#include <TDF_Tool.hxx>
-#include <BRepTools.hxx>
-static void Write(const TopoDS_Shape& shape,
- const Standard_CString filename)
-{
- ofstream save;
- save.open(filename);
- save << "DBRep_DrawableShape" << endl << endl;
- if(!shape.IsNull()) BRepTools::Write(shape, save);
- save.close();
-}
-#endif
+#include <TDataStd_Name.hxx>
//=======================================================================
//function : DNaming_Line3DDriver
aNS1 = DNaming::GetObjectValue(aRefP1);
Handle(TDataStd_UAttribute) aRefP2 = DNaming::GetObjectArg(aFunction, (LINE3D_TYPE + aCounter +1));
aNS2 = DNaming::GetObjectValue(aRefP2);
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
if(!aNS1->IsEmpty()) {
aShape1 = aNS1->Get();
gp_Pnt aDebPoint = BRep_Tool::Pnt(TopoDS::Vertex(aShape1));
}
aShape1 = aNS1->Get();
aShape2 = aNS2->Get();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
gp_Pnt aDebPoint = BRep_Tool::Pnt(TopoDS::Vertex(aShape1));
// cout << aCounter << " X = " << aDebPoint.X() << " Y = " << aDebPoint.Y() << " Z = " << aDebPoint.Z() << endl;
aDebPoint = BRep_Tool::Pnt(TopoDS::Vertex(aShape2));
try {
LoadNamingDS(aResultLabel, aWire, anArV, isClosed);
- } catch (EXCEPTION) {
+ } catch (Standard_Failure) {
aFunction->SetFailure(NAMING_FAILED);
return -1;
}
//Wire
TNaming_Builder aWBuilder(theResultLabel);
aWBuilder.Generated(theWire);
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(theResultLabel, "Line3DCurve");
#endif
Standard_Integer aLength = theArV.Length();
Standard_GUID drvGUID;
if(!GetFuncGUID(theArg[i],drvGUID)) continue;
aFunctionDrvTable->AddDriver(drvGUID, GetDriver(theArg[i]));
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "DNaming_AddDriver : " << theArg[i] << " driver is added" <<endl;
#endif
}
return 0;
}
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "DNaming_AddDriver : Error" << endl;
#endif
return 1;
goto ERR;
TCollection_AsciiString entry;
TDF_Tool::Entry(FatherLab, entry);
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "DNaming_SolveFlatFrom: Father label = " << entry << endl;
#endif
Standard_Boolean found(Standard_False);
cout << "DNaming_SolveFlatFrom: Driver failed at label = " << entry << endl;
return 1;
}
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout <<"DNaming_SolveFlatFrom : function from label " << entry << " is recomputed" << endl;
#endif
} catch (EXCEPTION) {
Standard_CString aDocS(theArg[1]);
if (!DDocStd::GetDocument(aDocS, aDoc)) return 1;
if(GetLogBook().IsEmpty()) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "DNaming_InitLogBook : is empty" <<endl;
#endif
}
else {
GetLogBook().Clear();
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "DNaming_InitLogBook : cleaned" <<endl;
#endif
}
cout << "DNaming_ComputeFun : No Driver or Driver failed" << endl;
return 1;
}
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout <<"DNaming_ComputeFun : function from label " << theArg[2] << " is recomputed" << endl;
#endif
return 0;
if (nb == 7)
aGeometry = (Standard_Boolean) Draw::Atoi(a[6]);
Handle(TNaming_NamedShape) aCont = DNaming::GetObjectValue(aContext);
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
if(aCont.IsNull() || aCont->IsEmpty())
cout <<"Wrong Context ..." <<endl;
#endif
}
if(!aCont.IsNull()) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
TCollection_AsciiString entry;
TDF_Tool::Entry(aCont->Label(), entry);
cout << "ContextNS Label = " << entry <<endl;
const char** a)
{
if (nb > 3) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "NB = " << nb <<endl;
#endif
Handle(TDocStd_Document) aDocument;
const char** a)
{
if (nb > 4) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "NB = " << nb <<endl;
#endif
Handle(TDocStd_Document) aDocument;
isFirst = Standard_False;
TCollection_AsciiString entry;
TDF_Tool::Entry(FirstAuxObj->Label(), entry);
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "First Selection function at " << entry <<endl;
#endif
}
if(isFirst) {
FirstAuxObj = auxObj;
isFirst = Standard_False;
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
TCollection_AsciiString entry;
TDF_Tool::Entry(FirstAuxObj->Label(), entry);
cout << "First Selection function at " << entry <<endl;
Handle(TDataStd_UAttribute) aRefPnt = DNaming::GetObjectArg(aFunction,PNTRLT_REF);
Handle(TNaming_NamedShape) aRefPntNS = DNaming::GetObjectValue(aRefPnt);
if (aRefPntNS.IsNull() || aRefPntNS->IsEmpty()) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"PointDriver:: Ref Point is empty"<<endl;
#endif
aFunction->SetFailure(WRONG_ARGUMENT);
return Standard_True;
}
-#ifdef OCC_DEB
+#ifdef OCCT_DEBUG
#include <BRepTools.hxx>
static void Write(const TopoDS_Shape& shape,
const Standard_CString filename)
BRepCheck_Analyzer aCheck(aResult);
if (!aCheck.IsValid(aResult)) {
aFunction->SetFailure(RESULT_NOT_VALID);
-#ifdef OCC_DEB
+#ifdef OCCT_DEBUG
Standard_CString aFileName = "PrismResult.brep";
Write(aResult, aFileName);
#endif
return Standard_True;
}
-#ifdef OCC_DEB
-#include <BRepTools.hxx>
-static void Write(const TopoDS_Shape& shape,
- const Standard_CString filename)
-{
- ofstream save;
- save.open(filename);
- save << "DBRep_DrawableShape" << endl << endl;
- if(!shape.IsNull()) BRepTools::Write(shape, save);
- save.close();
-}
-#endif
//=======================================================================
//function : Execute
//purpose : Executes the function
}
}
if(!anAxisOK) {
-#ifdef OCC_DEB
+#ifdef OCCT_DEBUG
cout<<"RevolutionDriver:: Axis is not correct"<<endl;
#endif
aFunction->SetFailure(WRONG_ARGUMENT);
TNaming_Builder aBuilder(theResultLabel.NewChild());
aBuilder.Generated (Vfirst, it.Value());
}
-#ifdef OCC_DEB
+#ifdef OCCT_DEBUG
else {
if(MS.HasDegenerated())
cout <<"mkRevol has degenerated" <<endl;
TNaming_Builder aBuilder(theResultLabel.NewChild());
aBuilder.Generated (Vlast, it.Value());
}
-#ifdef OCC_DEB
+#ifdef OCCT_DEBUG
else {
if(MS.HasDegenerated())
cout <<"mkRevol has degenerated" <<endl;
TNaming_Builder aBuilder(theResultLabel.NewChild());
aBuilder.Generated (Vfirst, it.Value());
}
-#ifdef OCC_DEB
+#ifdef OCCT_DEBUG
else {
if(MS.HasDegenerated())
cout <<"mkRevol has degenerated" <<endl;
TNaming_Builder aBuilder(theResultLabel.NewChild());
aBuilder.Generated (Vlast, it.Value());
}
-#ifdef OCC_DEB
+#ifdef OCCT_DEBUG
else {
if(MS.HasDegenerated())
cout <<"mkRevol has degenerated" <<endl;
{
Standard_Boolean extRefFound = Standard_False;
TDF_AttributeMap anExtMap;
-#ifdef DEB_SELN
+#ifdef OCCT_DEBUG_SELN
TCollection_AsciiString entr1;
TDF_Tool::Entry(theLabel, entr1);
cout<<"\tNaming Attribute at = "<< entr1 <<endl;
if(!aLabel.IsNull())
aLabel.FindAttribute(TNaming_Naming::GetID(), aNaming);
if(aNaming.IsNull()) continue;
-#ifdef DEB_SELN
+#ifdef OCCT_DEBUG_SELN
TDF_Tool::Entry(aLabel, entr1);
cout<<"\tNaming Attribute at = "<< entr1 <<endl;
#endif
TDF_Tool::OutReferences(aLabel,anExtMap);
for (TDF_MapIteratorOfAttributeMap attMItr(anExtMap);attMItr.More(); attMItr.Next()) {
Handle(TDF_Attribute) att = attMItr.Key();
-#ifdef DEB_SELN
+#ifdef OCCT_DEBUG_SELN
TDF_Tool::Entry(att->Label(), entr1);
cout<<"## References attribute dynamic type = "<<att->DynamicType()<<" at Label = "<<entr1 <<endl;
#endif
TDF_LabelMap aValidMap;
if(!FillValidMap(L,aValidMap))
di << "Valid map is empty" << "\n";
-#ifdef DEB_SELN
+#ifdef OCCT_DEBUG_SELN
cout<<"== Valid Label map =="<<endl;
for (TDF_MapIteratorOfLabelMap mapItr(aValidMap);mapItr.More(); mapItr.Next()) {
const TDF_Label& aLab = mapItr.Key();
#include <ModelDefinitions.hxx>
//#define SEL_DEB 1
-#ifdef SEL_DEB
+#ifdef OCCT_DEBUG
#include <TDF_Tool.hxx>
#include <TDF_MapIteratorOfLabelMap.hxx>
#endif
return Standard_True;
}
-#ifdef SEL_DEB
+#ifdef OCCT_DEBUG
#include <BRepTools.hxx>
static void Write(const TopoDS_Shape& shape,
const Standard_CString filename)
TDF_LabelMap aMap;
aMap = theLog.ChangeValid();
-#ifdef SEL_DEB
+#ifdef OCCT_DEBUG
cout <<"#E_DNaming_SelectionDriver:: Valid Label Map:"<<endl;
TDF_MapIteratorOfLabelMap anItr(aMap);
for (; anItr.More(); anItr.Next()) {
aNS->Label().EntryDump(cout); cout << endl;
} else {
-#ifdef SEL_DEB
+#ifdef OCCT_DEBUG
Write(aNS->Get(), "Selection_Result.brep");
Handle(TopoDS_TShape) aTS = aNS->Get().TShape();
cout << "TShape = " << (Standard_Address)aTS <<endl;
if(aPrevShapeType == aNS->Get().ShapeType()) {
aFunction->SetFailure(DONE);
} else {
-#ifdef SEL_DEB
+#ifdef OCCT_DEBUG
cout <<"%%%WARNING: DNaming_SelectionDriver::Execute: The Shape after solving changed type = "<<aNS->Get().ShapeType()<< endl;
#endif
aFunction->SetFailure(DONE);
Handle(TDataStd_UAttribute) anObject = DNaming::GetObjectArg(aFunction,SPHERE_CENTER);
Handle(TNaming_NamedShape) aNSCnt = DNaming::GetObjectValue(anObject);
if (aNSCnt.IsNull() || aNSCnt->IsEmpty()) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"SphereDriver:: Center point is null or empty"<<endl;
#endif
aFunction->SetFailure(WRONG_ARGUMENT);
TopoDS_Shape aCntShape = aNSCnt->Get();
if(aCntShape.IsNull()) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"SphereDriver:: Center point is null"<<endl;
#endif
aFunction->SetFailure(WRONG_ARGUMENT);
#define VERTEX_TAG 3
//#define MDTV_DEB_TRSF
-#ifdef MDTV_DEB_TRSF
+#ifdef OCCT_DEBUG_TRSF
#include <TCollection_AsciiString.hxx>
#include <BRepTools.hxx>
#include <TDF_Tool.hxx>
Handle(TNaming_NamedShape) aContextNS;
aLab.FindAttribute(TNaming_NamedShape::GetID(), aContextNS);
if (aContextNS.IsNull() || aContextNS->IsEmpty()) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"TransformationDriver:: Context is empty"<<endl;
#endif
aFunction->SetFailure(WRONG_CONTEXT);
return;
const TopoDS_Shape& aSrcShape = theSourceNS->Get();
if (aSrcShape.IsNull()) {
-#ifdef DNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"DNaming_TransformationDriver::LoadNamingDS: The result of the Transform operation is null"<<endl;
#endif
return;
Standard_Boolean isPrimitive(Standard_False);
if(theSourceNS->Evolution() == TNaming_PRIMITIVE) isPrimitive = Standard_True;
const TDF_Label& aSrcLabel = theSourceNS->Label();
-#ifdef MDTV_DEB_TRSF
+#ifdef OCCT_DEBUG_TRSF
cout <<"TransformationDriver: ";
PrintE(aSrcLabel);
#endif
DDataStd::AllCommands(theDI);
DPrsStd::AllCommands(theDI);
DDocStd::AllCommands(theDI);
-#ifdef DPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "Draw Plugin : All DF commands are loaded" << endl;
#endif
}
if (!DDF::FindLabel(D->GetData(),arg[2],L)) return 1;
Standard_GUID guid;
TCollection_ExtendedString str = arg[3];
-#ifdef DPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "Inputed parameter > " << str << endl;
#endif
if ( str == "A" ) //axis
// guid = TSketchStd_Edge::GetID(); //"b3aac90a-5b78-11d1-8940-080009dc3333"
Handle(TPrsStd_AISPresentation) prs= TPrsStd_AISPresentation::Set(L, guid);
-#ifdef DPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "Driver GUID = ";
prs->GetDriverGUID().ShallowDump(cout);
cout << "\n";
}
else {
TCollection_ExtendedString str = arg[3];
-#ifdef DPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "Inputed parameter > " << str << endl;
#endif
if ( str == "A" ) //axis
GeomAPI_ProjectPointOnCurve Projector( vtori, Einf1.Geometry() ); //patch
pvt = Projector.NearestPoint();
-#ifdef DRAFT_DEB
+#ifdef OCCT_DEBUG
static Standard_Integer VertexRecomp = 1;
if (VertexRecomp!=0) {
cout << "pori :" << vtori.X() << " " << vtori.Y() << " " << vtori.Z() << endl;
gp_Pnt opvt;
Einf2.Geometry()->D0(Vinf.Parameter(Edg2), opvt);
-#ifdef DRAFT_DEB
+#ifdef OCCT_DEBUG
if (VertexRecomp!=0) {
cout << " Edg 2 :" << Vinf.Parameter(Vinf.Edge()) << endl;
cout << "opvt " << opvt.X() << " " << opvt.Y() << " " << opvt.Z() << endl;
else if (TypeS == STANDARD_TYPE(Geom_CylindricalSurface)) {
Standard_Real testdir = Direction.Dot(NeutralPlane.Axis().Direction());
if (Abs(testdir) <= 1.-Precision::Angular()) {
-#ifdef DRAFT_DEB
+#ifdef OCCT_DEBUG
cout << "NewSurfaceCyl:Draft_Direction_and_Neutral_Perpendicular" << endl;
#endif
return NewS;
gp_Cylinder Cy = Handle(Geom_CylindricalSurface)::DownCast(S)->Cylinder();
testdir = Direction.Dot(Cy.Axis().Direction());
if (Abs(testdir) <= 1.-Precision::Angular()) {
-#ifdef DRAFT_DEB
+#ifdef OCCT_DEBUG
cout << "NewSurfaceCyl:Draft_Direction_and_Cylinder_Perpendicular" << endl;
#endif
return NewS;
}
if (!isIntDone || i2s.TypeInter() != IntAna_Circle) {
-#ifdef DRAFT_DEB
+#ifdef OCCT_DEBUG
cout << "NewSurfaceCyl:Draft_Intersection_Neutral_Cylinder_NotDone" << endl;
#endif
return NewS;
Standard_Real testdir = Direction.Dot(NeutralPlane.Axis().Direction());
if (Abs(testdir) <= 1.-Precision::Angular()) {
-#ifdef DRAFT_DEB
+#ifdef OCCT_DEBUG
cout << "NewSurfaceCone:Draft_Direction_and_Neutral_Perpendicular" << endl;
#endif
return NewS;
testdir = Direction.Dot(Co1.Axis().Direction());
if (Abs(testdir) <= 1.-Precision::Angular()) {
-#ifdef DRAFT_DEB
+#ifdef OCCT_DEBUG
cout << "NewSurfaceCone:Draft_Direction_and_Cone_Perpendicular" << endl;
#endif
return NewS;
IntAna_QuadQuadGeo i2s;
i2s.Perform(NeutralPlane,Co1,Precision::Angular(),Precision::Confusion());
if (!i2s.IsDone() || i2s.TypeInter() != IntAna_Circle) {
-#ifdef DRAFT_DEB
+#ifdef OCCT_DEBUG
cout << "NewSurfaceCone:Draft_Intersection_Neutral_Conical_NotDone" << endl;
#endif
return NewS;
}
}
else {
-#ifdef DRAFT_DEB
+#ifdef OCCT_DEBUG
cout << "NewSurface:Draft_SurfNotYetImplemented" << endl;
#endif
}
aMsg << aPluginResource->Value(theKey.ToCString());
aMsg << "; reason: ";
aMsg << error.ToCString();
-#ifdef DRAW_DEB
+#ifdef OCCT_DEBUG
cout << "could not open: " << aPluginResource->Value(theKey.ToCString())<< " ; reason: "<< error.ToCString() << endl;
#endif
Draw_Failure::Raise(aMsg);
{
// print OCCT version and OCCTY-specific macros used
di << "Open CASCADE Technology " << OCC_VERSION_STRING_EXT << "\n";
-#if defined(DEB) || defined(_DEBUG)
+#ifdef OCCT_DEBUG
+ di << "Extended debug mode\n";
+#elif defined(_DEBUG)
di << "Debug mode\n";
#endif
#ifdef HAVE_TBB
Tcl_Exit(0);
}
catch (Standard_Failure) {
-#ifdef DRAW_DEB
+#ifdef OCCT_DEBUG
cout <<"Tcl_Exit have an exeption" << endl;
#endif
}
// check if the file name has been specified and use default value if not
if (thePluginName.IsEmpty()) {
thePluginName += "DrawPlugin";
-#ifdef DRAW_DEB
+#ifdef OCCT_DEBUG
cout << "Plugin file name has not been specified. Defaults to " << thePluginName.ToCString() << endl;
#endif
}
if (aToSetCSFVariable) {
OSD_Environment aCSFVarEnv ( aCSFVariable, aPluginDir );
aCSFVarEnv.Build();
-#ifdef DRAW_DEB
+#ifdef OCCT_DEBUG
cout << "Variable " << aCSFVariable.ToCString() << " has not been explicitly defined. Set to " << aPluginDir.ToCString() << endl;
#endif
if ( aCSFVarEnv.Failed() ) {
const TCollection_AsciiString& aKey = theMap.FindKey(j);
TCollection_AsciiString aResource = aKey;
if(myResources->Find(aResource.ToCString())) {
-#ifdef DRAW_DEB
+#ifdef OCCT_DEBUG
cout << "Parse Value ==> " << myResources->Value(aResource.ToCString()) << endl;
#endif
TCollection_AsciiString aValue(myResources->Value(aResource.ToCString()));
Standard_Integer i=1;
for(;;) {
TCollection_AsciiString aCurKey = aValue.Token(" \t,", i++);
-#ifdef DRAW_DEB
+#ifdef OCCT_DEBUG
cout << "Parse aCurKey = " << aCurKey.ToCString() << endl;
#endif
if(aCurKey.IsEmpty()) break;
for(j = 1; j <= aMapExtent; j++) {
const TCollection_AsciiString& aKey = aMap.FindKey(j);
TCollection_AsciiString aResource = aKey;
-#ifdef DRAW_DEB
+#ifdef OCCT_DEBUG
cout << "aResource = " << aResource << endl;
#endif
if(myResources->Find(aResource.ToCString())) {
const TCollection_AsciiString& aValue = myResources->Value(aResource.ToCString());
-#ifdef DRAW_DEB
+#ifdef OCCT_DEBUG
cout << "Value ==> " << aValue << endl;
#endif
OSD_File aTclScriptFile ( aTclScriptFileName );
OSD_File aTclScriptFileDefaults ( aTclScriptFileNameDefaults );
if (!aTclScriptDir.IsEmpty() && aTclScriptFile.Exists()) {
-#ifdef DRAW_DEB
+#ifdef OCCT_DEBUG
cout << "Load " << aTclScriptFileName << " TclScript" << endl;
#endif
di.EvalFile( aTclScriptFileName.ToCString() );
} else if (!aPluginDir.IsEmpty() && aTclScriptFileDefaults.Exists()) {
-#ifdef DRAW_DEB
+#ifdef OCCT_DEBUG
cout << "Load " << aTclScriptFileNameDefaults << " TclScript" << endl;
#endif
di.EvalFile( aTclScriptFileNameDefaults.ToCString() );
return;
}
}
-#ifdef DRAWDIM_DEB
+#ifdef OCCT_DEBUG
cout << " DrawDim_PlanarDiameter::DrawOn : dimension error" << endl;
#endif
}
}
}
}
-#ifdef DRAWDIM_DEB
+#ifdef OCCT_DEBUG
cout << " DrawDim_PlanarDistance::DrawOn : dimension error" << endl;
#endif
}
return;
}
}
-#ifdef DRAWDIM_DEB
+#ifdef OCCT_DEBUG
cout << " DrawDim_PlanarRadius::DrawOn : dimension error" << endl;
#endif
}
//void AIS_RadiusDimension::ComputeOneFaceRadius(const Handle(Prs3d_Presentation)& aPresentation)
//{
-#ifdef DRAWDIM_DEB
+#ifdef OCCT_DEBUG
cout << "entree dans computeonefaceradius"<< endl;
#endif
BRepAdaptor_Surface surfAlgo (TopoDS::Face(myFShape));
FilletCirc.SetRadius( Center.Distance( FirstPoint ) ); //***
gp_Vec vec1( dir1 );
vec1 *= FilletCirc.Radius();
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Pnt p1 =
#endif
Center.Translated( vec1 );
gp_Vec vec2( dir2 );
vec2 *= FilletCirc.Radius();
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Pnt p2 =
#endif
Center.Translated( vec2 );
FirstParCirc = ElCLib::Parameter( FilletCirc, FirstPoint );
LastParCirc = ElCLib::Parameter( FilletCirc, SecondPoint );
-#ifdef DEB
+#ifdef OCCT_DEBUG
#endif
}
else //Angle equal 0 or PI or R = 0
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
#include <Expr_NumericValue.ixx>
#include <Standard_OutOfRange.hxx>
-//#if defined (WNT) || !defined (DEB)
# include <stdio.h>
-//#endif // WNT || !DEB
Expr_NumericValue::Expr_NumericValue(const Standard_Real val)
{
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
//function : GetU
//purpose :
//=======================================================================
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
//static Standard_Real GetU(const gp_Vec& vec,
// const gp_Pnt& P,
// const Handle(Adaptor3d_HCurve)& C)
{
IsSolved = H->Decompose();
-#if FEMTOOL_DEB
+#ifdef OCCT_DEBUG
if (!IsSolved) {
cout << "Solve Echec H = " << endl;
H->OutM();
realbuffer[0] = '\0';
if (!(myStream >> realbuffer)) {
-#ifdef FSD_DEB
+#ifdef OCCT_DEBUG
cerr << "%%%ERROR: read error of double at offset " << myStream.tellg() << endl;
cerr << "\t buffer is" << realbuffer<< endl;
#endif
Storage_StreamTypeMismatchError::Raise();
}
if (!OSD::CStringToReal(realbuffer,aValue)) {
-#ifdef FSD_DEB
+#ifdef OCCT_DEBUG
cerr << "%%%ERROR: read error of double at offset " << myStream.tellg() << endl;
cerr << "\t buffer is" << realbuffer<< endl;
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
// 01-04-1996 : PMN Version originale
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
// 09-02-1996 : PMN Version originale
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
// 30-01-1996 : PMN Version originale
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
Standard_Integer L = 2 + NewConstraintOrder1 + NewConstraintOrder2,
kk, ii;
// NbP1 = Poles->Length()-1, kk, ii;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer NbP1 =
#endif
Poles->Length() ;
-#ifdef DEB
+#ifdef OCCT_DEBUG
NbP1 = NbP1 - 1 ;
#endif
TColStd_Array1OfReal knots (1,2);
#include <TColgp_Array1OfPnt.hxx>
#include <gp_Pnt.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
//#include <DrawTrSurf.hxx>
//static Standard_Integer compteur = 0;
myParams = new TColStd_HArray1OfReal(1,myNbPoints);
for( i = 1 ; i <= myNbPoints ; i++ )
myParams->SetValue(i,UA.Parameter(i));
-#ifdef DEB
+#ifdef OCCT_DEBUG
// char name [100];
// for( i = 1 ; i <= NbPoints ; i++ ) {
gp_Ax2d axe(Center,dirx);
cirsol(NbrSol) = gp_Circ2d(axe,Radius);
// ======================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Dir2d dc1(center1.XY()-Center.XY());
#endif
gp_Dir2d dc2(origin2.XY()-Center.XY());
else { qualifier1(NbrSol) = GccEnt_enclosing; }
qualifier2(NbrSol) = GccEnt_noqualifier;
dir1 = gp_Dir2d(Center.XY()-center1.XY());
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Dir2d dir2(Center.XY()-Point2.XY());
#endif
if ((Center.Distance(center1) > C1.Radius()) &&
Standard_Real R1 = C1.Radius();
Standard_Real R2 = C2.Radius();
gp_Pnt2d center1(C1.Location());
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Pnt2d center2(C2.Location());
#else
C2.Location() ;
Standard_Integer nbsolution1 = Bis1.NbSolutions();
Handle(GccInt_Bisec) Sol2 = Bis2.ThisSolution();
for (Standard_Integer i = 1 ; i <= nbsolution1; i++) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Lin2d Sol1(Bis1.ThisSolution(i));
#else
Bis1.ThisSolution(i) ;
gp_Lin2d linint1(Bis1.ThisSolution());
Handle(GccInt_Bisec) Sol2 = Bis2.ThisSolution();
GccInt_IType typ2 = Sol2->ArcType();
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Lin2d linintb(Bis1.ThisSolution());
#else
Bis1.ThisSolution() ;
myAlong.SetValue(2,IsQPunctual(BS,V2,GeomAbs_IsoV,TolMin,Tol));
myAlong.SetValue(3,IsQPunctual(BS,U1,GeomAbs_IsoU,TolMin,Tol));
myAlong.SetValue(4,IsQPunctual(BS,U2,GeomAbs_IsoU,TolMin,Tol));
-#if defined(DEB) && defined(OCCT_DEVELOPMENT)
+#ifdef OCCT_DEBUG
cout<<myAlong(1)<<endl<<myAlong(2)<<endl<<myAlong(3)<<endl<<myAlong(4)<<endl;
#endif
if (myAlong(1) || myAlong(2) || myAlong(3) || myAlong(4))
{
InitSurf = Handle(Geom_BSplineSurface)::DownCast(myBasisSurf);
}
-#if defined(DEB) && defined(OCCT_DEVELOPMENT)
+#ifdef OCCT_DEBUG
cout<<"UDEG: "<<InitSurf->UDegree()<<endl;
cout<<"VDEG: "<<InitSurf->VDegree()<<endl;
#endif
OsculSurf = BuildOsculatingSurface(V1,UKnot,VKnot,S,L);
if(!OsculSurf) break;
k++;
-#if defined(DEB) && defined(OCCT_DEVELOPMENT)
+#ifdef OCCT_DEBUG
cout<<"1.k = "<<k<<endl;
#endif
IsQPunc=IsQPunctual(L,V1,GeomAbs_IsoV,0.,Tol);
OsculSurf = BuildOsculatingSurface(V2,UKnot,VKnot,S,L);
if(!OsculSurf) break;
k++;
-#if defined(DEB) && defined(OCCT_DEVELOPMENT)
+#ifdef OCCT_DEBUG
cout<<"2.k = "<<k<<endl;
#endif
IsQPunc=IsQPunctual(L,V2,GeomAbs_IsoV,0.,Tol);
OsculSurf = BuildOsculatingSurface(V2,UKnot,VKnot,S,L);
if(!OsculSurf) break;
k++;
-#if defined(DEB) && defined(OCCT_DEVELOPMENT)
+#ifdef OCCT_DEBUG
cout<<"2.k = "<<k<<endl;
#endif
IsQPunc=IsQPunctual(L,V2,GeomAbs_IsoV,0.,Tol);
OsculSurf = BuildOsculatingSurface(U1,UKnot,VKnot,S,L);
if(!OsculSurf) break;
k++;
-#if defined(DEB) && defined(OCCT_DEVELOPMENT)
+#ifdef OCCT_DEBUG
cout<<"1.k = "<<k<<endl;
#endif
IsQPunc=IsQPunctual(L,U1,GeomAbs_IsoU,0.,Tol);
OsculSurf = BuildOsculatingSurface(U2,UKnot,VKnot,S,L);
if(!OsculSurf) break;
k++;
-#if defined(DEB) && defined(OCCT_DEVELOPMENT)
+#ifdef OCCT_DEBUG
cout<<"2.k = "<<k<<endl;
#endif
IsQPunc=IsQPunctual(L,U2,GeomAbs_IsoU,0.,Tol);
OsculSurf = BuildOsculatingSurface(U2,UKnot,VKnot,S,L);
if(!OsculSurf) break;
k++;
-#if defined(DEB) && defined(OCCT_DEVELOPMENT)
+#ifdef OCCT_DEBUG
cout<<"2.k = "<<k<<endl;
#endif
IsQPunc=IsQPunctual(L,U2,GeomAbs_IsoU,0.,Tol);
{
Standard_Integer i, j;
Standard_Boolean OsculSurf=Standard_True;
-#if defined(DEB) && defined(OCCT_DEVELOPMENT)
+#ifdef OCCT_DEBUG
cout<<"t = "<<Param<<endl;
cout<<"======================================"<<endl<<endl;
#endif
vdeg = BS->VDegree();
if( (IsAlongU() && vdeg <=1) || (IsAlongV() && udeg <=1))
{
-#if defined(DEB) && defined(OCCT_DEVELOPMENT)
+#ifdef OCCT_DEBUG
cout<<" surface osculatrice nulle "<<endl;
#endif
//Standard_ConstructionError::Raise("Geom_OsculatingSurface");
Standard_Integer OscUNumCoeff=0, OscVNumCoeff=0;
if (IsAlongU())
{
-#if defined(DEB) && defined(OCCT_DEVELOPMENT)
+#ifdef OCCT_DEBUG
cout<<">>>>>>>>>>> AlongU"<<endl;
#endif
OscUNumCoeff = (Standard_Integer ) udeg + 1;
}
if (IsAlongV())
{
-#if defined(DEB) && defined(OCCT_DEVELOPMENT)
+#ifdef OCCT_DEBUG
cout<<">>>>>>>>>>> AlongV"<<endl;
#endif
OscUNumCoeff = (Standard_Integer ) udeg;
Data.UDegree(),
Data.VDegree(),
0, 0);
-#if defined(DEB) && defined(OCCT_DEVELOPMENT)
+#ifdef OCCT_DEBUG
cout<<"^====================================^"<<endl<<endl;
#endif
D1NormMax=Max(D1NormMax,D1U.Magnitude());
}
-#if defined(DEB) && defined(OCCT_DEVELOPMENT)
+#ifdef OCCT_DEBUG
cout << " D1NormMax = " << D1NormMax << endl;
#endif
if (D1NormMax >TolMax || D1NormMax < TolMin )
S->D1(Param,T,P,D1U,D1V);
D1NormMax=Max(D1NormMax,D1V.Magnitude());
}
-#if defined(DEB) && defined(OCCT_DEVELOPMENT)
+#ifdef OCCT_DEBUG
cout << " D1NormMax = " << D1NormMax << endl;
#endif
if (D1NormMax >TolMax || D1NormMax < TolMin )
NbrSol++;
cirsol(NbrSol) = gp_Circ2d(gp_Ax2d(Center,dirx),Radius);
// =======================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Dir2d dc1(center1.XY()-Center.XY());
#endif
gp_Dir2d dc2(origin2.XY()-Center.XY());
gp_Vec2d Tan1,Tan2,Nor2;
ElCLib::D2(Ufirst(1),C1,point1,Tan1,Nor2);
Geom2dGcc_CurveTool::D1(Cu2,Ufirst(2),point2,Tan2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Vec2d Tan3(OnLine.Direction().XY());
#else
OnLine.Direction().XY();
gp_Vec2d Tan1,Tan2;
ElCLib::D1(Ufirst(1),C1,point1,Tan1);
Geom2dGcc_CurveTool::D1(Cu2,Ufirst(2),point2,Tan2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Vec2d Tan3(-Sin(Ufirst(3)),Cos(Ufirst(3)));
#endif
point3 = ElCLib::Value(Ufirst(3),OnCirc);
gp_Vec2d Tan1,Tan2;
ElCLib::D1(Ufirst(1),L1,point1,Tan1);
Geom2dGcc_CurveTool::D1(Cu2,Ufirst(2),point2,Tan2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Vec2d Tan3(-Sin(Ufirst(3)),Cos(Ufirst(3)));
#endif
point3 = ElCLib::Value(Ufirst(3),OnCirc);
gp_Vec2d Tan1,Tan2;
Geom2dGcc_CurveTool::D1(Cu1,Ufirst(1),point1,Tan1);
Geom2dGcc_CurveTool::D1(Cu2,Ufirst(2),point2,Tan2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Vec2d Tan3(-Sin(Ufirst(3)),Cos(Ufirst(3)));
#endif
point3 = gp_Pnt2d(OnCirc.Location().XY()+
gp_Pnt2d Center(Intp.Point(i).Value());
cirsol(NbrSol) = gp_Circ2d(gp_Ax2d(Center,dirx),Radius);
// =======================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Dir2d dir1(Center.XY()-center1.XY());
#else
Center.XY() ;
Adaptor3d_OffsetCurve C1(HCu1,cote1(jcote1));
firstparam = Max(Geom2dGcc_CurveToolGeo::FirstParameter(C1),thefirst);
lastparam = Min(Geom2dGcc_CurveToolGeo::LastParameter(C1),thelast);
-#ifdef DEB
+#ifdef OCCT_DEBUG
IntRes2d_Domain D2(Geom2dGcc_CurveToolGeo::Value(C1,firstparam),firstparam,Tol,
Geom2dGcc_CurveToolGeo::Value(C1,lastparam),lastparam,Tol);
#else
Adaptor3d_OffsetCurve C2(HCu2,cote2(jcote2));
firstparam = Max(Geom2dGcc_CurveToolGeo::FirstParameter(C2),thefirst);
lastparam = Min(Geom2dGcc_CurveToolGeo::LastParameter(C2),thelast);
-#ifdef DEB
+#ifdef OCCT_DEBUG
IntRes2d_Domain D2(Geom2dGcc_CurveToolGeo::Value(C2,firstparam),firstparam,Tol,
Geom2dGcc_CurveToolGeo::Value(C2,lastparam),lastparam,Tol);
#else
InitDerivative(X,Point1,Point2,Vect11,Vect21,Vect12,Vect22);
Standard_Real NormeD11 = Vect11.Magnitude();
Standard_Real NormeD21 = Vect21.Magnitude();
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Vec2d V2V1(Vect11.XY(),Vect21.XY());
#else
Vect11.XY();
InitDerivative(X,Point1,Point2,Vect11,Vect21,Vect12,Vect22);
Standard_Real NormeD11 = Vect11.Magnitude();
Standard_Real NormeD21 = Vect21.Magnitude();
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Vec2d V2V1(Vect11.XY(),Vect21.XY());
#else
Vect11.XY();
Geom2dHatch_Elements::Geom2dHatch_Elements(const Geom2dHatch_Elements& )
{
-#ifdef GEOM2DHATCH_DEB
+#ifdef OCCT_DEBUG
cout<<" Magic Constructor in Geom2dHatch_Elements:: "<<endl;
#endif
}
static Standard_Boolean dodraw = 0;
static Standard_Real drawfac = 0.1;
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_IMPORT void Law_draw1dcurve(const TColStd_Array1OfReal& pol,
const TColStd_Array1OfReal& knots,
const TColStd_Array1OfInteger& mults,
if(scal1 > tolang) {
Standard_Real killfactor = tolang/scal1;
stat[i].DoKill(killfactor);
-#ifdef GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout<<"pb coons cnd coin : "<<i<<" fact = "<<killfactor<<endl;
#endif
}
fnul = stat[inext].IsToKill(fscal);
}
if(fnul || lnul){
-#ifdef DEB
+#ifdef OCCT_DEBUG
parclock.Start();
#endif
bound[i]->Reparametrize(0.,1.,fnul,lnul,fscal,lscal,rev[i]);
-#ifdef DEB
+#ifdef OCCT_DEBUG
parclock.Stop();
#endif
if(bound[i]->HasNormals() && tga[i]->IsScalable()) {
const Handle(GeomFill_Boundary)& B3,
const Standard_Boolean NoCheck)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
totclock.Reset();
parclock.Reset();
appclock.Reset();
rev[2] = !rev[2];
// on reparamettre tout le monde entre 0. et 1.
-#ifdef DEB
+#ifdef OCCT_DEBUG
parclock.Start();
#endif
for (i = 0; i <= 2; i++){
bound[i]->Reparametrize(0.,1.,0,0,1.,1.,rev[i]);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
parclock.Stop();
#endif
const Handle(GeomFill_Boundary)& B4,
const Standard_Boolean NoCheck)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
totclock.Reset();
parclock.Reset();
appclock.Reset();
rev[3] = !rev[3];
// on reparamettre tout le monde entre 0. et 1.
-#ifdef DEB
+#ifdef OCCT_DEBUG
parclock.Start();
#endif
for (i = 0; i <= 3; i++){
bound[i]->Reparametrize(0.,1.,0,0,1.,1.,rev[i]);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
parclock.Stop();
#endif
}
nbd3 += ctr[ii];
}
-#ifdef GEOMFILL_DEB
+#ifdef OCCT_DEBUG
appclock.Start();
#endif
if(nbd3) PerformApprox();
-#ifdef GEOMFILL_DEB
+#ifdef OCCT_DEBUG
appclock.Stop();
#endif
}
appdone = Standard_True;
-#ifdef GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cstclock.Start();
#endif
MatchKnots();
PerformS0();
PerformS1();
PerformSurface();
-#ifdef GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cstclock.Stop();
totclock.Stop();
Standard_Real tottime, apptime, partime, csttime;
Standard_Integer NPolU = W1.Length();
Standard_Integer NPolV = W2.Length();
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
Standard_Real NU = NPolU - 1;
Standard_Real NV = NPolV - 1;
//#endif
#include <TColgp_HArray1OfPnt.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_Boolean Affich=0;
#endif
if (Ok)
tol = (Tol-tol)/2;
else {
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout << "smooth law echec" << endl;
#endif
return; // Echec
Ok = (tol <= Tol);
}
if (!Ok) {
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout << "smooth law echec" << endl;
#endif
}
}
if (Ok) Law = BS;
-#if DEB
+#ifdef OCCT_DEBUG
if (Affich) {
cout << "Knots Law : " << endl;
for (ii=1; ii<=BS->NbKnots(); ii++) {
angleATarr->ChangeValue(i) = EvolAT(i);
}
-#if DEB
+#ifdef OCCT_DEBUG
if (Affich) {
cout<<"NormalEvolution"<<endl;
for (i = 1; i <= Length; i++) {
NStatus,Normal,OrderU,OrderV);
if (NStatus != CSLib_Defined) {
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout << U << ", " << V<< endl;
for(i=0;i<=MaxOrder;i++)
for(j=0;j<=MaxOrder;j++){
mySnglLen->ChangeValue(i) = Min(Sqrt(2*NullTol/norm), MaxSingular);
else mySnglLen->ChangeValue(i) = MaxSingular;
}
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
for(i = 1; i <= mySngl->Length(); i++) {
cout<<"Sngl("<<i<<") = "<<mySngl->Value(i)<<" Length = "<<mySnglLen->Value(i)<<endl;
}
mySnglLen->ChangeValue(i) = tmpSeq(i).Y();
}
}
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout<<"After merging"<<endl;
for(i = 1; i <= mySngl->Length(); i++) {
cout<<"Sngl("<<i<<") = "<<mySngl->Value(i)<<" Length = "<<mySnglLen->Value(i)<<endl;
if(RotateTrihedron(Tangent,Normal,BiNormal,aTn) == Standard_False)
{
-#ifdef GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout << "Cannot coincide two tangents." << endl;
#endif
return Standard_False;
Standard_Real Norm = n.Magnitude();
if (Norm < 1.e-12) {
Norm = 1;
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout << "GuideTrihedronAC : Normal indefinie" << endl;
#endif
}
//derivee seconde du triedre
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Vec DTDN = DTo.Crossed(DNormal);
#else
DTo.Crossed(DNormal);
#include <DrawTrSurf.hxx>
#endif
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
static void TracePlan(const Handle(Geom_Surface)& /*Plan*/)
{
cout << "Pas d'intersection Guide/Plan" << endl;
Int.Perform(myTrimG, Pl); // intersection plan / guide
if (Int.NbPoints() == 0) {
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
TracePlan(Plan);
#endif
w = (fabs(myGuide->LastParameter() -w) > fabs(myGuide->FirstParameter()-w) ? myGuide->FirstParameter() : myGuide->LastParameter());
}
}
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
if (Abs(Diff) > DeltaG) {
cout << "Trihedron Plan Diff on Guide : " <<
Diff << endl;
BiNormal.Normalized();
}
else { // Erreur...
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout << "D0 :";
// plan ortho a la trajectoire pour determiner Pprime
Handle(Geom_Plane) Plan = new (Geom_Plane)(P, Tangent);
DTangent.Crossed(Normal));
}
else {// Erreur...
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout << "D1 :";
// plan ortho a la trajectoire
Handle(Geom_Plane) Plan = new (Geom_Plane)(P, Tangent);
Tangent.Crossed(D2Normal));
}
else {// Erreur...
-#if DEB
+#ifdef OCCT_DEBUG
cout << "D2 :";
TracePlan(Plan);
#endif
//function : TraceRevol
//purpose : Trace la surface de revolution (Debug)
//=======================================================================
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
static void TraceRevol(const Standard_Real t,
const Standard_Real s,
const Handle(GeomFill_TrihedronWithGuide)& Law,
Standard_Real theU = 0., theV = 0.;
if (!DistMini.IsDone() || DistMini.NbExt() == 0) {
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout <<"LocationGuide : Pas d'intersection"<<endl;
TraceRevol(t, U, myLaw, mySec, myCurve, Trans);
#endif
if (Result.IsDone() &&
(Result.FunctionSetErrors().Norm() < TolRes(1)*TolRes(1)) ) {
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout << "Ratrappage Reussi !" << endl;
#endif
SOS = Standard_True;
theV = PInt.V();
}
else {
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout << "Echec du Ratrappage !" << endl;
#endif
}
}
}
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
if (Abs(Diff) > DeltaG) {
cout << "Location :: Diff on Guide : " <<
Diff << endl;
InGoodPeriod (OldAngle, 2*M_PI, Angle);
Diff = Angle - OldAngle;
}
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
if (Abs(Diff) > M_PI/4) {
cout << "Diff d'angle trop grand !!" << endl;
}
InGoodPeriod (myPoles2d->Value(2, ii-1).Y(), UPeriod, v);
}
Diff = v - myPoles2d->Value(2, ii-1).Y();
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
if (Abs(Diff) > (Ul-Uf)/(2+NbKnots)) {
cout << "Diff sur section trop grand !!" << endl;
}
M.SetCols(n, b, t);
}
else {
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout << "LocationGuide::D0 : No Result !"<<endl;
TraceRevol(Param, U, myLaw, mySec, myCurve, Trans);
#endif
M.SetCols(n, b, t);
}
else {
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
Standard_Real U = myFirstS + ratio*(Param-myCurve->FirstParameter());
cout << "LocationGuide::D0 : No Result !"<<endl;
TraceRevol(Param, U, myLaw, mySec, myCurve, Trans);
if (rotation) {
return Standard_False;
/*
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Real U = myFirstS + ratio*(Param-myCurve->FirstParameter());
#else
myCurve->FirstParameter() ;
Ga.Solve (DEDT.Opposite(), DSDT);// resolution du syst.
}//if
else {
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout << "DEDX = " << DEDX << endl;
cout << "DEDT = " << DEDT << endl;
#endif
Standard_Real A = R(2);
Standard_Real Aprim = DSDT(2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Mat M2 (Cos(A), -Sin(A),0, // rotation autour de T
Sin(A), Cos(A),0,
0,0,1);
}//if_Result
else {
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout << "LocationGuide::D1 : No Result !!"<<endl;
TraceRevol(Param, U, myLaw, mySec, myCurve, Trans);
#endif
}//if_result
else {
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout << "LocationGuide::D2 : No Result !!" <<endl;
TraceRevol(Param, U, myLaw, mySec, myCurve, Trans);
#endif
#include <gp_Lin.hxx>
#include <gp_Circ.hxx>
-#ifdef GEOMFILL_DEB
+#ifdef OCCT_DEBUG
# ifdef DRAW
# include <DrawTrSurf.hxx>
# endif
static Standard_Integer NbSurf = 0;
#endif
-#ifdef GEOMFILL_DEB
+#ifdef OCCT_DEBUG
// verification des fonctions de derivation D1 et D2 par differences finies
Standard_Boolean verifD1(const TColgp_Array1OfPnt& P1,
const TColStd_Array1OfReal& W1,
if (NullWeight) return Standard_False;
// verif par diff finies sous debug sauf pour les surfaces periodiques
-#ifdef GEOMFILL_DEB
+#ifdef OCCT_DEBUG
if (!mySurface->IsVPeriodic()) {
Standard_Real pas = 1.e-6, wTol = 1.e-4, pTol = 1.e-3;
Standard_Real V1,V2;
if (NullWeight) return Standard_False;
// verif par diff finies sous debug sauf pour les surfaces periodiques
-#ifdef GEOMFILL_DEB
+#ifdef OCCT_DEBUG
if (!mySurface->IsVPeriodic()) {
Standard_Real V1,V2;
Standard_Boolean ok1,ok2;
if (mySurface->VDegree()<2) {
mySurface->IncreaseDegree(mySurface->UDegree(),2);
}
-#ifdef GEOMFILL_DEB
+#ifdef OCCT_DEBUG
NbSurf++;
if (Affich) {
#ifdef DRAW
#include <TColgp_Array1OfPnt.hxx>
#include <TColGeom_SequenceOfCurve.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_Boolean Affich = Standard_False;
static Standard_Integer NbSections = 0;
#endif
}
case GeomFill_IsDarboux :
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
{
cout << "Option Darboux: non realisable" << endl;
}
myAdpPath->LastParameter(),
Tol, Tol, 0., 0.01,
TheConti, DegMax, NbMaxSegment);
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout << "Tuyau : ";
App.Dump(cout);
cout << endl;
Section.Perform(myPolynomial);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( Affich) {
Standard_Integer NbPoles,NbKnots,Degree,NbPoles2d;
Section.GetShape(NbPoles,NbKnots,Degree,NbPoles2d);
App.Perform( Line, Section, 30);
if ( !App.IsDone()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
// on affiche les sections sous debug
Standard_Integer NbPoles,NbKnots,Degree,NbPoles2d;
Section.GetShape(NbPoles,NbKnots,Degree,NbPoles2d);
}
}
*/
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
if (Intersector.NbPoints() == 0) {
Intersector.Dump();
}
if (Approx.IsDone()) {
Ok = Standard_True;
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
Approx.Dump(cout);
#endif
Segmax,
eval,
Preferentiel);
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
Approx.Dump(cout);
#endif
mySurface = new (Geom_RectangularTrimmedSurface)
(S,UFirst, ULast, Standard_True);
-#if GEOMFILL_DEB
+#ifdef OCCT_DEBUG
if (isUPeriodic && !mySurface->IsUPeriodic())
cout<<"Pb de periodicite en U" << endl;
if (isUPeriodic && !mySurface->IsUClosed())
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
}
else
if (D1Ref.IsOpposite(D1, Precision::Angular()))
-#ifdef GEOMFILL_DEB
+#ifdef OCCT_DEBUG
cout <<"Que fais-je ???? " << endl;
#endif
gp_Vec(PPath,P1));
Angle = ElCLib::CircleParameter(Axis,P2);
}
-#ifdef GF_DEB
+#ifdef OCCT_DEBUG
+/*
if (Standard_False) {
gp_Vec dummyD1 = myAdpPath->DN(U,1);
gp_Vec dummyTg = Axis.Direction();
if ( Cos > 0.) cout << "+" ;
else cout << "-" ;
}
+*/
#endif
if ( Angle < Precision::Angular()) {
for ( Standard_Integer i = 1; i <= Poles.Upper(); i++) {
}
if (NullWeight) {
-#if GEOMLIB_DEB
+#ifdef OCCT_DEBUG
cout << "Echec de l'Extension rationnelle" << endl;
#endif
lambmin /= 3.;
math_Jacobi J(M);
if (!J.IsDone()) {
-#if GEOMLIB_DEB
+#ifdef OCCT_DEBUG
cout << "Erreur dans Jacobbi" << endl;
M.Dump(cout);
#endif
return Standard_False;
Cross.Normalize();
-#if DEB
- GeomPlate_Aij A1( 1, 2, Cross );
-#endif
Bset.Append( GeomPlate_Aij( 1, 2, Cross ) );
Bset.Append( GeomPlate_Aij( 2, 1, -Cross) );
Normals.Append( NewNormals(1) );
#include <GeomPlate_SequenceOfAij.hxx>
#include <GeomPlate_MakeApprox.hxx>
-// pour mes tests
-#ifdef PLATE_DEB
-#include <OSD_Chronometer.hxx>
-#endif
-
#ifdef DRAW
#include <DrawTrSurf.hxx>
#include <Draw_Marker3D.hxx>
#include <Draw_Marker2D.hxx>
#include <Draw.hxx>
-static Standard_Integer Affich=0;
// 0 : Pas de display
// 1 : Display des Geometries et controle intermediaire
// 2 : Display du nombre de contrainte par courbe + Intersection
static Standard_Integer NbProj = 0;
#endif
+// pour mes tests
+#ifdef OCCT_DEBUG
+#include <OSD_Chronometer.hxx>
+static Standard_Integer Affich=0;
+#endif
+
//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//\\//
// =========================================================
// C O N S T R U C T E U R S
else
{
Curve2d.Nullify(); // Pas de solution continue
-#if PLATE_DEB
+#ifdef OCCT_DEBUG
cout << "BuildPlateSurace :: Pas de projection continue" << endl;
#endif
}
if (Projector.NbCurves() != 1) {
HProjector.Nullify(); // Pas de solution continue
-#if PLATE_DEB
+#ifdef OCCT_DEBUG
cout << "BuildPlateSurace :: Pas de projection continue" << endl;
#endif
}
else
{
HProjector.Nullify(); // Pas de solution continue
-#if PLATE_DEB
+#ifdef OCCT_DEBUG
cout << "BuildPlateSurace :: Pas de projection complete" << endl;
#endif
}
//---------------------------------------------------------
void GeomPlate_BuildPlateSurface::Perform()
{
-#ifdef PLATE_DEB
+#ifdef OCCT_DEBUG
// Chronmetrage
OSD_Chronometer Chrono;
Chrono.Reset();
myInitOrder->SetValue(l,l);
if (!CourbeJointive(myTol3d))
{// Standard_Failure::Raise("Curves are not joined");
-#ifdef PLATE_DEB
+#ifdef OCCT_DEBUG
cout<<"WARNING : Courbes non jointives a "<<myTol3d<<" pres"<<endl;
#endif
}
do
{
-#if PLATE_DEB
+#ifdef OCCT_DEBUG
if (Affich && NbBoucle) {
cout<<"Resultats boucle"<< NbBoucle << endl;
cout<<"DistMax="<<myG0Error<<endl;
Fini = VerifSurface(NbBoucle);
if ((NbBoucle >= myNbIter)&&(!Fini))
{
-#ifdef PLATE_DEB
+#ifdef OCCT_DEBUG
cout<<"Warning objectif non atteint"<<endl;
#endif
Fini = Standard_True;
VerifPoints(di,an,cu);
}
} while (!Fini); // Fin boucle pour meilleur surface
-#ifdef PLATE_DEB
+#ifdef OCCT_DEBUG
if (NTLinCont != 0)
{ cout<<"======== Resultats globaux ==========="<<endl;
cout<<"DistMax="<<myG0Error<<endl;
Disc2dContour ( const Standard_Integer /*nbp*/,
TColgp_SequenceOfXY& Seq2d)
{
-#ifdef PLATE_DEB
- if (nbp!=4)
+#ifdef OCCT_DEBUG
+ if (Seq2d.Length()!=4)
cout<<"nbp doit etre egal a 4 pour Disc2dContour"<<endl;
#endif
// initialisation
const Standard_Integer iordre,
TColgp_SequenceOfXYZ& Seq3d)
{
-#ifdef PLATE_DEB
- if (nbp!=4)
+#ifdef OCCT_DEBUG
+ if (Seq3d.Length()!=4)
cout<<"nbp doit etre egal a 4 pour Disc3dContour"<<endl;
if (iordre!=0&&iordre!=1)
cout<<"iordre incorrect pour Disc3dContour"<<endl;
} //if (isHalfSpace)
if (!isHalfSpace)
{
-#ifdef PLATE_DEB
+#ifdef OCCT_DEBUG
cout<<endl<<"Normals are not in half space"<<endl<<endl;
#endif
myIsLinear = Standard_False;
nopt = 1; //Calcul par la methode du plan d'inertie
else if (!CourbeJoint || NTLinCont != myNbBounds)
{// Standard_Failure::Raise("Curves are not joined");
-#ifdef PLATE_DEB
+#ifdef OCCT_DEBUG
cout<<"WARNING : Courbes non jointives a "<<myTol3d<<" pres"<<endl;
#endif
nopt = 1;
Handle( Geom_Surface ) InitPlane =
(Handle( Geom_RectangularTrimmedSurface )::DownCast(mySurfInit))->BasisSurface();
- Standard_Real Ratio, R1 = 2., R2 = 0.6; //R1 = 3, R2 = 0.5;//R1 = 1.4, R2 = 0.8; //R1 = 5., R2 = 0.2;
+ Standard_Real Ratio = 0., R1 = 2., R2 = 0.6; //R1 = 3, R2 = 0.5;//R1 = 1.4, R2 = 0.8; //R1 = 5., R2 = 0.2;
Handle( GeomAdaptor_HSurface ) hsur =
new GeomAdaptor_HSurface( InitPlane );
Standard_Integer NbPoint = 20;
}
}
}
-#if PLATE_DEB
+#ifdef OCCT_DEBUG
if (! myIsLinear)
cout <<"Metrics are too different :"<< Ratio<<endl;
#endif
{ int2d = Intersection.Point(k);
myLinCont->Value(i)->D0(int2d.ParamOnFirst(),P1);
myLinCont->Value(j)->D0(int2d.ParamOnSecond(),P2);
-#if PLATE_DEB
+#ifdef OCCT_DEBUG
if (Affich> 1)
{
cout << " Intersection "<< k << " entre " << i
if (A1>(M_PI/2))
A1= M_PI - A1;
if (Abs(Abs(A1)-M_PI)<myTolAng) Tol = 100000 * myTol3d;
-#if PLATE_DEB
+#ifdef OCCT_DEBUG
if (Affich) cout <<"Angle entre Courbe "<<i<<","<<j
<<" "<<Abs(Abs(A1)-M_PI)<<endl;
#endif
if (A1 > M_PI/2)
A1= M_PI - A1;
if (Abs(Abs(A1) - M_PI) < myTolAng) Tol = 100000 * myTol3d;
-#if PLATE_DEB
+#ifdef OCCT_DEBUG
if (Affich) cout <<"Angle entre Courbe "<<i<<","<<j
<<" "<<Abs(Abs(A1)-M_PI)<<endl;
#endif
{
coin = Ci.Resolution(Tol);
coin *= Angle / myTolAng * 10.;
-#if PLATE_DEB
+#ifdef OCCT_DEBUG
cout<<endl<<"coin = "<<coin<<endl;
#endif
Standard_Real Par1 = int2d.ParamOnFirst() - coin;
{
coin = Cj.Resolution(Tol);
coin *= Angle / myTolAng * 10.;
-#if PLATE_DEB
+#ifdef OCCT_DEBUG
cout<<endl<<"coin = "<<coin<<endl;
#endif
Standard_Real Par1 = int2d.ParamOnSecond() - coin;
Append( int2d.ParamOnSecond() + tolint);
}
-#ifdef PLATE_DEB
+#ifdef OCCT_DEBUG
cout<<"Attention: Deux points 3d ont la meme projection dist="
<<Dist<<endl;
#endif
NbPtInter= PntInter->Value(i).Length();
NbPtG1G1= PntG1G1->Value(i).Length();
-#if PLATE_DEB
+#ifdef OCCT_DEBUG
if (Affich > 1) {
cout << "Courbe : " << i << endl;
cout << " NbPnt, NbPtInter, NbPtG1G1 :" << NbPnt_i << ", "
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-// PMN : 7/07/1997 : cout en #if DEB ... #endif
-
-
#include <GeomPlate_MakeApprox.ixx>
#include <GeomPlate_Surface.hxx>
#include <GeomPlate_PlateG0Criterion.hxx>
mySurface = AppPlate.Surface(1);
myAppError = AppPlate.MaxError(3,1);
myCritError = AppPlate.CritError(3,1);
-#if PLATE_DEB
+#ifdef OCCT_DEBUG
cout<<"Approximation results"<<endl;
cout<<" Approximation error : "<<myAppError<<endl;
cout<<" Criterium error : "<<myCritError<<endl;
Standard_Real seuil = Tol3d;
if (CritOrder==0&&Tol3d<10*dmax) {
seuil=10*dmax;
-#if PLATE_DEB
+#ifdef OCCT_DEBUG
cout<<"Seuil G0 choisi trop faible par rapport au contour. On prend "<<seuil<<endl;
#endif
}
if (CritOrder==1&&Tol3d<10*dmax) {
seuil=10*dmax;
-#if PLATE_DEB
+#ifdef OCCT_DEBUG
cout<<"Seuil G1 choisi trop faible par rapport au contour. On prend "<<seuil<<endl;
#endif
}
mySurface = AppPlate.Surface(1);
myAppError = AppPlate.MaxError(3,1);
myCritError = 0.;
-#if PLATE_DEB
+#ifdef OCCT_DEBUG
cout<<"Approximation results"<<endl;
cout<<" Approximation error : "<<myAppError<<endl;
#endif
mySurface = AppPlate.Surface(1);
myAppError = AppPlate.MaxError(3,1);
myCritError = AppPlate.CritError(3,1);
-#if PLATE_DEB
+#ifdef OCCT_DEBUG
cout<<"Approximation results"<<endl;
cout<<" Approximation error : "<<myAppError<<endl;
cout<<" Criterium error : "<<myCritError<<endl;
mySurface = AppPlate.Surface(1);
myAppError = AppPlate.MaxError(3,1);
myCritError = AppPlate.CritError(3,1);
-#if PLATE_DEB
+#ifdef OCCT_DEBUG
cout<<"Approximation results"<<endl;
cout<<" Approximation error : "<<myAppError<<endl;
cout<<" Criterium error : "<<myCritError<<endl;
}
}
catch ( Standard_Failure ) {
-#ifdef GEOMTOIGES_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: GeomToIGES_GeomCurve: can't trim bspline" << endl;
cout << "Warning: Exception in Segment(): " ;
Standard_Failure::Caught()->Print(cout);
return res;
}
catch(Standard_Failure){
-#ifdef GEOMTOIGES_DEB
+#ifdef OCCT_DEBUG
cout << "writing non-planar offset curve."<<endl;
cout << "Warning: GeomConvert::CurveToBSplineCurve raised an exception: ";
Standard_Failure::Caught()->Print(cout);
}
}
else {
-#ifdef GEOMTOSTEP_DEB
+#ifdef OCCT_DEBUG
cout<<"MakeBoundedCurve, type : "<<C->DynamicType()->Name()<<" not processed"<<endl;
#endif
done = Standard_False;
theConic = MkParabola.Value();
}
else {
-#ifdef GEOMTOSTEP_DEB
+#ifdef OCCT_DEBUG
cout << "3D Curve Type : " << C->DynamicType() << endl;
#endif
done = Standard_False;
else {
// Attention : Other 2d conics shall be implemented ...
// To be performed later !
-#ifdef GEOMTOSTEP_DEB
+#ifdef OCCT_DEBUG
cout << "2D conic not yet implemented" << endl;
#endif
done = Standard_False;
B = BZ;
}
else {
-#ifdef GEOMTOSTEP_DEB
+#ifdef OCCT_DEBUG
cout<<"GeomToStep_MakeCurve, TrimmedCurve, BasisCurve is transferred not trimmed"<<endl;
cout<<"BasisCurve Type : "<<B->DynamicType()->Name()<<endl;
#endif
Handle(Geom2d_Circle) theC2d = Handle(Geom2d_Circle)::DownCast(C);
gp_Circ2d C2d = theC2d->Circ2d();
if (!C2d.IsDirect()) {
-#ifdef GEOMTOSTEP_DEB
+#ifdef OCCT_DEBUG
cout << "Warning : Circle converted to BSpline." << endl;
#endif
Handle(Geom2d_BSplineCurve) aBSplineCurve2d =
Handle(Geom2d_Ellipse) theE2d = Handle(Geom2d_Ellipse)::DownCast(C);
gp_Elips2d E2d = theE2d->Elips2d();
if (!E2d.IsDirect()) {
-#ifdef GEOMTOSTEP_DEB
+#ifdef OCCT_DEBUG
cout << "Warning : Ellipse converted to BSpline." << endl;
#endif
Handle(Geom2d_BSplineCurve) aBSplineCurve2d =
}
else {
done = Standard_False;
-#ifdef GEOMTOSTEP_DEB
+#ifdef OCCT_DEBUG
cout << " unknown type " << S->DynamicType()->Name() << endl;
#endif
}
}
}
catch(Standard_Failure) {
-#ifdef GEOMTOOLS_DEB
+#ifdef OCCT_DEBUG
Handle(Standard_Failure) anExc = Standard_Failure::Caught();
cout <<"EXCEPTION in GeomTools_Curve2dSet::ReadCurve2d(..)!!!" << endl;
cout << anExc << endl;
}
}
catch(Standard_Failure) {
-#ifdef GEOMTOOLS_DEB
+#ifdef OCCT_DEBUG
Handle(Standard_Failure) anExc = Standard_Failure::Caught();
cout <<"EXCEPTION in GeomTools_CurveSet::ReadCurve(..)!!!" << endl;
cout << anExc << endl;
}
}
catch(Standard_Failure) {
-#ifdef GEOMTOOLS_DEB
+#ifdef OCCT_DEBUG
Handle(Standard_Failure) anExc = Standard_Failure::Caught();
cout <<"EXCEPTION in GeomTools_SurfaceSet::ReadSurface(..)!!!" << endl;
cout << anExc << endl;
{
if( n < 2)
{
-#ifdef GEOMLITETEST_DEB
+#ifdef OCCT_DEBUG
cout<< "2dintersect curve curve [Tol]"<<endl;
#endif
return 1;
if (VarName.IsEmpty())
{
-#ifdef GRAPHIC3D_DEB
+#ifdef OCCT_DEBUG
std::cerr << "Both environment variables CSF_MDTVTexturesDirectory and CASROOT are undefined!\n"
<< "At least one should be defined to use standard Textures.\n";
#endif
OSD_File aTextureFile (aTexture);
if (!aDir.Exists() || !aTextureFile.Exists())
{
-#ifdef GRAPHIC3D_DEB
+#ifdef OCCT_DEBUG
std::cerr << " CSF_MDTVTexturesDirectory or CASROOT not correctly setted\n";
std::cerr << " not all files are found in : "<< VarName.ToCString() << std::endl;
#endif
#define MinSeg ((Standard_Integer*)Indices)[7]
#define MaxSeg ((Standard_Integer*)Indices)[8]
#define SegFlags ((Standard_Integer*)Indices)[9]
-#ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_Integer ERROR = Standard_False;
#endif
//=======================================================================
o[npi] = n1 == -1;
m[npi] = Multiple;
}
-#ifdef HLRALGO_DEB
+#ifdef OCCT_DEBUG
else if (ERROR) {
cout << " error : HLRAlgo_PolyData::HideByOneTriangle " << endl;
cout << " ( more than 2 points )." << endl;
o[npi] = n1 == -1;
m[npi] = Multiple;
}
-#ifdef HLRALGO_DEB
+#ifdef OCCT_DEBUG
else if (ERROR) {
cout << " error : HLRAlgo_PolyData::HideByOneTriangle " << endl;
cout << " ( more than 2 points )." << endl;
o[npi] = n1 == -1;
m[npi] = Multiple;
}
-#ifdef HLRALGO_DEB
+#ifdef OCCT_DEBUG
else if (ERROR) {
cout << " error : HLRAlgo_PolyData::HideByOneTriangle " << endl;
cout << " ( more than 2 points )." << endl;
#define Nod4PCu1 ((Standard_Real*)Nod4RValues)[ 8]
#define Nod4PCu2 ((Standard_Real*)Nod4RValues)[ 9]
#define Nod4Scal ((Standard_Real*)Nod4RValues)[10]
-#ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_Integer TRACE = Standard_False;
static Standard_Integer ERROR = Standard_False;
#endif
Nod3NrmX = 1;
Nod3NrmY = 0;
Nod3NrmZ = 0;
-#ifdef HLRALGO_DEB
+#ifdef OCCT_DEBUG
if (ERROR)
cout << "HLRAlgo_PolyInternalData::AddNode" << endl;
#endif
}
if (find == 0) {
myNbPISeg--;
-#ifdef HLRALGO_DEB
+#ifdef OCCT_DEBUG
if (ERROR) {
cout << "HLRAlgo_PolyInternalData::UpdateLinks : segment error";
cout << endl;
Nod3NdSg = myNbPISeg;
Nod4NdSg = myNbPISeg;
}
-#ifdef HLRALGO_DEB
+#ifdef OCCT_DEBUG
else if (ERROR) {
cout << "HLRAlgo_PolyInternalData::UpdateLinks : triangle error ";
cout << endl;
Standard_Address& TData2)
{
if (myNbTData >= myMxTData) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRACE)
cout << "HLRAlgo_PolyInternalData::IncTData : " << myMxTData << endl;
#endif
Standard_Address& PISeg2)
{
if (myNbPISeg >= myMxPISeg) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRACE)
cout << "HLRAlgo_PolyInternalData::IncPISeg : " << myMxPISeg << endl;
#endif
Standard_Address& PINod2)
{
if (myNbPINod >= myMxPINod) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRACE)
cout << "HLRAlgo_PolyInternalData::IncPINod : " << myMxPINod << endl;
#endif
inline Handle(Geom2d_BezierCurve)
HLRBRep_CurveTool::Bezier (const Standard_Address /*C*/)
{
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
cout<<" HLRBRep_CurveTool::Bezier : Not Implemented "<<endl;
#endif
//-- return(((HLRBRep_Curve *)C)->Bezier());
inline Handle(Geom2d_BSplineCurve)
HLRBRep_CurveTool::BSpline (const Standard_Address /*C*/)
{
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
cout<<" HLRBRep_CurveTool::BSpline : Not Implemented "<<endl;
#endif
//-- return(((HLRBRep_Curve *)C)->BSpline());
long unsigned **TabBit;
Standard_Integer nTabBit;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer StNbLect,StNbEcr,StNbMax,StNbMoy,StNbMoyNonNul; //-- STAT
#endif
//-- ============================================================
TableauRejection() {
N=0; nTabBit=0; UV=NULL; nbUV=NULL; IndUV=NULL; TabBit=NULL;
-#ifdef DEB
+#ifdef OCCT_DEBUG
StNbLect=StNbEcr=StNbMax=StNbMoy=StNbMoyNonNul=0;
#endif
}
//-- ============================================================
void SetDim(const Standard_Integer n) {
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
cout<<"\n@#@#@#@#@# SetDim "<<n<<endl;
#endif
if(UV)
Destroy();
-#ifdef DEB
+#ifdef OCCT_DEBUG
StNbLect=StNbEcr=StNbMax=StNbMoy=0;
#endif
N=n;
}
//-- ============================================================
void Destroy() {
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
if(N) {
Standard_Integer nnn=0;
StNbMoy=StNbMoyNonNul=0;
free(IndUV[i]);
IndUV[i]=NULL;
}
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else
cout<<" IndUV ~~~~~~~~~~~~~~~~~~~~~~~~~~~~"<<endl;
#endif
free(UV[i]);
UV[i]=NULL;
}
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else { cout<<" UV ~~~~~~~~~~~~~~~~~~~~~~~~~~~~"<<endl; }
#endif
}
//-- ============================================================
void Set(Standard_Integer i0,Standard_Integer j0,const Standard_Real u) {
i0--; j0--;
-#ifdef DEB
+#ifdef OCCT_DEBUG
StNbEcr++;
#endif
Standard_Integer k=-1;
//-- ============================================================
Standard_Real Get(Standard_Integer i0,Standard_Integer j0) {
i0--; j0--;
-#ifdef DEB
+#ifdef OCCT_DEBUG
StNbLect++;
#endif
}
else {
myNbPoints = myNbSegments = 0;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
cout << "HLRBRep_Data::NextInterference : ";
if (myLE == myFE)
cout << "Edge " << myLE
else {
stbef = TopAbs_OUT;
staft = TopAbs_OUT;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
cout << "HLRBRep_Data::EdgeState : undefined" << endl;
#endif
}
else {
stbef = TopAbs_OUT;
staft = TopAbs_OUT;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
cout << "HLRBRep_Data::EdgeState : undefined" << endl;
#endif
}
else if (p > param + tolpar)
Loop = Standard_False;
else {
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
cout << "HLRBRep_Data::HidingStartLevel : ";
cout << "Bad Parameter." << endl;
#endif
(iFaceGeom,pu,pv,V);
gp_Vec Nm = mySLProps.Normal();
if (curv == 0) {
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
cout << "HLRBRep_Data::OrientOutLine " << I;
cout << " Edge " << myFE << " : ";
cout << "CurvatureValue == 0." << endl;
Nm.Transform(T);
Nm.Cross(Tg);
if (Tg.Magnitude() < gp::Resolution()) {
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
cout << "HLRBRep_Data::OrientOutLine " << I;
cout << " Edge " << myFE << " : ";
cout << "Tg.Magnitude() == 0." << endl;
eb1->Orientation(ie1,myFEOri);
}
else {
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
cout << "HLRBRep_Data::OrientOutLine " << I;
cout << " Edge " << myFE << " : ";
cout << "UVPoint not found, OutLine not Oriented" << endl;
eb1->Orientation(ie1,myFEOri);
}
}
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else {
cout << "HLRBRep_Data::OrientOthEdge " << I;
cout << " Edge " << myFE << " : ";
VertMax[15] = (Standard_Integer)((myDeca[15]+TotMax[15])*mySurD[15]);
TopAbs_State
-HLRBRep_Data::Classify (const Standard_Integer /*E*/,
+HLRBRep_Data::Classify (const Standard_Integer E,
const HLRBRep_EdgeData& ED,
const Standard_Boolean LevelFlag,
Standard_Integer& Level,
const Standard_Real param)
{
+ (void)E; // avoid compiler warning
+
nbClassification++;
Standard_Integer VertMin[16],VertMax[16],MinMaxVert[16];
Standard_Real TotMin[16],TotMax[16];
(Standard_Address)VertMax,
(Standard_Address)MinMaxVert);
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
{
Standard_Integer qwe,qwep8,q,q1,q2;
printf("\n E:%d -------\n",E);
//function : ProcessComplex
//purpose :
//=======================================================================
-#ifdef DEB_SI
+#ifdef OCCT_DEBUG_SI
static Standard_Boolean SimilarInterference(const HLRAlgo_Interference& I1,
const HLRAlgo_Interference& I2)
{
It2.Next();
if (It2.More()) {
if (T.SameInterferences(It1.Value(),It2.Value())
-#ifdef DEB_SI
+#ifdef OCCT_DEBUG_SI
|| SimilarInterference(It1.Value(),It2.Value())
#endif
)
while (It2.More()) {
if (!(T.SameInterferences(It1.Value(),It2.Value())
-#ifdef DEB_SI
+#ifdef OCCT_DEBUG_SI
|| SimilarInterference(It1.Value(),It2.Value())
#endif
)) break;
HLRBRep_EdgeIList::AddInterference(ILHidden,Int,EIT);
ILOn.Remove(It); break;
case TopAbs_UNKNOWN :
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
cout << "UNKNOWN state staft" << endl;
#endif
case TopAbs_ON :
HLRBRep_EdgeIList::AddInterference(ILHidden,Int,EIT);
ILOn.Remove(It); break;
case TopAbs_UNKNOWN :
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
cout << "UNKNOWN state stbef" << endl;
#endif
case TopAbs_ON :
HLRBRep_EdgeIList::AddInterference(ILHidden,Int,EIT);
ILOn.Remove(It); break;
case TopAbs_UNKNOWN :
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
cout << "UNKNOWN state after" << endl;
#endif
It.Next(); break;
case TopAbs_OUT :
Int.Transition(TopAbs_REVERSED); break;
case TopAbs_UNKNOWN :
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
cout << "UNKNOWN state after" << endl;
#endif
break;
case TopAbs_OUT :
ILOn.Remove(It); break;
case TopAbs_UNKNOWN :
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
cout << "UNKNOWN state after" << endl;
#endif
It.Next(); break;
} break;
case TopAbs_UNKNOWN :
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
cout << "UNKNOWN state stbef" << endl;
#endif
break;
}
catch(Standard_Failure) {
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
cout << "An exception was catched when hiding edge " << E;
cout << " by the face " << FI << endl;
Handle(Standard_Failure) fail = Standard_Failure::Caught();
Standard_Integer e,f,j,nbVisEdges,nbSelEdges,nbSelFaces,nbCache;
Standard_Integer nbFSide,nbFSimp;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (myDebug) {
nbPtIntersection = 0;
nbSegIntersection = 0;
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (myDebug) {
fd = &(myDS->FDataArray().ChangeValue(1));
nbFSimp = 0;
#define MinSeg ((Standard_Integer*)IndexPtr)[7]
#define MaxSeg ((Standard_Integer*)IndexPtr)[8]
#define SegFlags ((Standard_Integer*)IndexPtr)[9]
-#ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_Integer DoTrace = Standard_False;
static Standard_Integer DoError = Standard_False;
#endif
NN++;
}
}
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else if (DoError) {
cout << " HLRBRep_PolyAlgo::StoreShell : Face ";
cout << f << " non triangulated" << endl;
}
}
}
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else if (DoError) {
cout << "HLRBRep_PolyAlgo::StoreShell : Face ";
cout << f << " deja stockee" << endl;
Nod1NrmX = 1;
Nod1NrmY = 0;
Nod1NrmZ = 0;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
if (DoError) {
cout << "HLRBRep_PolyAlgo::Normal : AverageNormal error";
cout << endl;
Standard_Real d = sqrt (X * X + Y * Y + Z * Z);
if (OK && d < 1.e-10) {
OK = Standard_False;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
if (DoError) {
cout << "HLRAlgo_PolyInternalData:: inverted normals on ";
cout << "node " << iNode << endl;
ZTI2 = Z2 = Nod12PntZ;
if (Nod12Edg1 == (Standard_Boolean) e) U2 = Nod12PCu1;
else if (Nod12Edg2 == (Standard_Boolean) e) U2 = Nod12PCu2;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else {
cout << " HLRBRep_PolyAlgo::InitBiPointsWithConnexity : ";
cout << "Parameter error on Node " << i1p2 << endl;
&(((HLRAlgo_Array1OfPINod*)PINod1)->ChangeValue(Pol1(iPol)));
Nod12Indices = (*pi1p2)->Indices();
Nod12RValues = (*pi1p2)->RValues();
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
if (DoError) {
if (Nod11NrmX*Nod12NrmX +
Nod11NrmY*Nod12NrmY +
ZTI2 = Z2 = Nod12PntZ;
if (Nod12Edg1 == (Standard_Boolean) e) U2 = Nod12PCu1;
else if (Nod12Edg2 == (Standard_Boolean) e) U2 = Nod12PCu2;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else {
cout << " HLRBRep_PolyAlgo::InitBiPointsWithConnexity : ";
cout << "Parameter error on Node " << i1p2 << endl;
}
}
}
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else if (DoError) {
cout << "HLRBRep_PolyAlgo::InitBiPointsWithConnexity : Edge ";
cout << e << " connex 1 sans PolygonOnTriangulation" << endl;
ZTI2 = Z2 = Nod12PntZ;
if (Nod12Edg1 == (Standard_Boolean) e) U2 = Nod12PCu1;
else if (Nod12Edg2 == (Standard_Boolean) e) U2 = Nod12PCu2;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else {
cout << " HLRBRep_PolyAlgo::InitBiPointsWithConnexity : ";
cout << "Parameter error on Node " << i1p2 << endl;
&(((HLRAlgo_Array1OfPINod*)PINod2)->ChangeValue(Pol2(iPol)));
Nod22Indices = (*pi2p2)->Indices();
Nod22RValues = (*pi2p2)->RValues();
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
if (DoError) {
if (Nod11NrmX*Nod12NrmX +
Nod11NrmY*Nod12NrmY +
ZTI2 = Z2 = Nod12PntZ;
if (Nod12Edg1 == (Standard_Boolean) e) U2 = Nod12PCu1;
else if (Nod12Edg2 == (Standard_Boolean) e) U2 = Nod12PCu2;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else {
cout << " HLRBRep_PolyAlgo::InitBiPointsWithConnexity : ";
cout << "Parameter error on Node " << i1p2 << endl;
}
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
else if (DoError) {
cout << "HLRBRep_PolyAlgo::InitBiPointsWithConnexity : Edge ";
cout << e << " connect 2 without PolygonOnTriangulation" << endl;
0));
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
else if (DoError) {
cout << "HLRBRep_PolyAlgo::InitBiPointsWithConnexity : Edge ";
cout << e << " Isolated, without Polygone 3D" << endl;
Nod11PntZ = Z3;
if (Nod11Edg1 == (Standard_Boolean) e) Nod11PCu1 = U3;
else if (Nod11Edg2 == (Standard_Boolean) e) Nod11PCu2 = U3;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else {
cout << " HLRBRep_PolyAlgo::MoveOrInsertPoint : ";
cout << "Parameter error on Node " << i1p1 << endl;
Nod12PntZ = Z3;
if (Nod12Edg1 == (Standard_Boolean) e) Nod12PCu1 = U3;
else if (Nod12Edg2 == (Standard_Boolean) e) Nod12PCu2 = U3;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else {
cout << " HLRBRep_PolyAlgo::MoveOrInsertPoint : ";
cout << "Parameter error on Node " << i1p2 << endl;
Nod11PntZ = Z3;
if (Nod11Edg1 == (Standard_Boolean) e) Nod11PCu1 = U3;
else if (Nod11Edg2 == (Standard_Boolean) e) Nod11PCu2 = U3;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else {
cout << " HLRBRep_PolyAlgo::MoveOrInsertPoint : ";
cout << "Parameter error on Node " << i1p1 << endl;
Nod21PntZ = Z3;
if (Nod21Edg1 == (Standard_Boolean) e) Nod21PCu1 = U3;
else if (Nod21Edg2 == (Standard_Boolean) e) Nod21PCu2 = U3;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else {
cout << " HLRBRep_PolyAlgo::MoveOrInsertPoint : ";
cout << "Parameter error on Node " << i2p1 << endl;
Nod12PntZ = Z3;
if (Nod12Edg1 == (Standard_Boolean) e) Nod12PCu1 = U3;
else if (Nod12Edg2 == (Standard_Boolean) e) Nod12PCu2 = U3;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else {
cout << " HLRBRep_PolyAlgo::MoveOrInsertPoint : ";
cout << "Parameter error on Node " << i1p2 << endl;
Nod22PntZ = Z3;
if (Nod22Edg1 == (Standard_Boolean) e) Nod22PCu1 = U3;
else if (Nod22Edg2 == (Standard_Boolean) e) Nod22PCu2 = U3;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else {
cout << " HLRBRep_PolyAlgo::MoveOrInsertPoint : ";
cout << "Parameter error on Node " << i2p2 << endl;
Nod11PntZ = Z3;
if (Nod11Edg1 == (Standard_Boolean) e) Nod11PCu1 = U3;
else if (Nod11Edg2 == (Standard_Boolean) e) Nod11PCu2 = U3;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else {
cout << " HLRBRep_PolyAlgo::MoveOrInsertPoint : ";
cout << "Parameter error on Node " << i1p1 << endl;
Nod21PntZ = Z3;
if (Nod21Edg1 == (Standard_Boolean) e) Nod21PCu1 = U3;
else if (Nod21Edg2 == (Standard_Boolean) e) Nod21PCu2 = U3;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else {
cout << " HLRBRep_PolyAlgo::MoveOrInsertPoint : ";
cout << "Parameter error on Node " << i2p1 << endl;
Nod12PntZ = Z4;
if (Nod12Edg1 == (Standard_Boolean) e) Nod12PCu1 = U4;
else if (Nod12Edg2 == (Standard_Boolean) e) Nod12PCu2 = U4;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else {
cout << " HLRBRep_PolyAlgo::MoveOrInsertPoint : ";
cout << "Parameter error on Node " << i1p2 << endl;
Nod22PntZ = Z4;
if (Nod22Edg1 == (Standard_Boolean) e) Nod22PCu1 = U4;
else if (Nod22Edg2 == (Standard_Boolean) e) Nod22PCu2 = U4;
-#ifdef HLRBREP_DEB
+#ifdef OCCT_DEBUG
else {
cout << " HLRBRep_PolyAlgo::MoveOrInsertPoint : ";
cout << "Parameter error on Node " << i2p2 << endl;
TTMa[2][1] = ttma.Value(3,2);
TTMa[2][2] = ttma.Value(3,3);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoTrace) {
cout << " InsertOnOutLine : NbTData " << (*pid)->NbTData() << endl;
cout << " InsertOnOutLine : NbPISeg " << (*pid)->NbPISeg() << endl;
nbS = (*pid)->NbPISeg();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoTrace) {
cout << " InsertOnOutLine : NbTData " << (*pid)->NbTData() << endl;
cout << " InsertOnOutLine : NbPISeg " << (*pid)->NbPISeg() << endl;
Tri1Indices = tdata->Indices();
if ((Tri1Flags & FMskSide) == 0 &&
(Tri1Flags & FMskFrBack)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoTrace)
cout << " face : " << f << " , triangle " << i << endl;
#endif
Nod11Flag |= NMskMove;
UpdateAroundNode(Tri1Node1,Nod11Indices,TData,PISeg,PINod);
FrBackInList = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoTrace) {
cout << Tri1Node1 << " modifies : DX,DY ";
cout << X1 << " , " << Y1 << endl;
Nod12Flag |= NMskMove;
UpdateAroundNode(Tri1Node2,Nod12Indices,TData,PISeg,PINod);
FrBackInList = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoTrace) {
cout << Tri1Node2 << " modifies : DX,DY ";
cout << X2 << " , " << Y2 << endl;
Nod13Flag |= NMskMove;
UpdateAroundNode(Tri1Node3,Nod13Indices,TData,PISeg,PINod);
FrBackInList = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoTrace) {
cout << Tri1Node3 << " modifies : DX,DY ";
cout << X3 << " , " << Y3 << endl;
}
#endif
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
else if (DoTrace)
cout << "modification error" << endl;
#endif
Nod11Indices = (((HLRAlgo_Array1OfPINod*)PINod1)->
ChangeValue(F1Pt1Index))->Indices();
if (Nod11Flag & NMskMove) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoTrace)
cout << F1Pt1Index << " modifies 11" << endl;
#endif
Nod11Indices = (((HLRAlgo_Array1OfPINod*)PINod1)->
ChangeValue(F1Pt2Index))->Indices();
if (Nod11Flag & NMskMove) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoTrace)
cout << F1Pt2Index << " modifies 12" << endl;
#endif
Nod11Indices = (((HLRAlgo_Array1OfPINod*)PINod2)->
ChangeValue(F2Pt1Index))->Indices();
if (Nod11Flag & NMskMove) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoTrace)
cout << F2Pt1Index << " modifies 21" << endl;
#endif
Nod11Indices = (((HLRAlgo_Array1OfPINod*)PINod2)->
ChangeValue(F2Pt2Index))->Indices();
if (Nod11Flag & NMskMove) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoTrace)
cout << F2Pt2Index << " modifies 22" << endl;
#endif
Nod1NrmX = 1;
Nod1NrmY = 0;
Nod1NrmZ = 0;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoError) {
cout << "HLRBRep_PolyAlgo::ChangeNode between " << ip1;
cout << " and " << ip2 << endl;
Nod2NrmX = 1;
Nod2NrmY = 0;
Nod2NrmZ = 0;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoError) {
cout << "HLRBRep_PolyAlgo::ChangeNode between " << ip2;
cout << " and " << ip1 << endl;
//=======================================================================
void
-#ifdef DEB
+#ifdef OCCT_DEBUG
HLRBRep_PolyAlgo::OrientTriangle(const Standard_Integer iTri,
#else
HLRBRep_PolyAlgo::OrientTriangle(const Standard_Integer,
Tri1Flags |= FMskSide;
Tri1Flags &= ~FMskBack;
Tri1Flags |= FMskOnOutL;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoTrace) {
cout << "HLRBRep_PolyAlgo::OrientTriangle : OnOutL";
cout << " triangle " << iTri << endl;
Standard_Real dz12 = Nod2PntZ - Nod1PntZ;
Standard_Real d12 = sqrt(dx12 * dx12 + dy12 * dy12 + dz12 * dz12);
if (d12 <= 1.e-10) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoTrace) {
cout << "HLRBRep_PolyAlgo::OrientTriangle : Flat";
cout << " triangle " << iTri << endl;
Standard_Real dz23 = Nod3PntZ - Nod2PntZ;
Standard_Real d23 = sqrt(dx23 * dx23 + dy23 * dy23 + dz23 * dz23);
if (d23 < 1.e-10) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoTrace) {
cout << "HLRBRep_PolyAlgo::OrientTriangle : Flat";
cout << " triangle " << iTri << endl;
Standard_Real dz31 = Nod1PntZ - Nod3PntZ;
Standard_Real d31 = sqrt(dx31 * dx31 + dy31 * dy31 + dz31 * dz31);
if (d31 < 1.e-10) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoTrace) {
cout << "HLRBRep_PolyAlgo::OrientTriangle : Flat";
cout << " triangle " << iTri << endl;
Standard_Real dz = dx12 * dy23 - dy12 * dx23;
Standard_Real d = sqrt(dx * dx + dy * dy + dz * dz);
if (d < 1.e-5) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoTrace) {
cout << "HLRBRep_PolyAlgo::OrientTriangle : Flat";
cout << " triangle " << iTri << endl;
}
iTri1 = 0;
iTri2 = 0;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DoError) {
cout << "HLRBRep_PolyAlgo::Triangles : error";
cout << " between " << ip1 << " and " << ip2 << endl;
Tri1Flags |= EMskOutLin2;
else if ((tn3 == pd && tn1 == pf) || (tn3 == pf && tn1 == pd))
Tri1Flags |= EMskOutLin3;
-#ifdef DEB
+#ifdef OCCT_DEBUG
else if (DoError) {
cout << "HLRAlgo_PolyInternalData::UpdateOutLines";
cout << " : segment not found" << endl;
Tri2Flags |= EMskOutLin2;
else if ((tn3 == pd && tn1 == pf) || (tn3 == pf && tn1 == pd))
Tri2Flags |= EMskOutLin3;
-#ifdef DEB
+#ifdef OCCT_DEBUG
else if (DoError) {
cout << "HLRAlgo_PolyInternalData::UpdateOutLines";
cout << " : segment not found" << endl;
BP.OutLine(outl);
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
else if (DoError) {
cout << "HLRBRep_PolyAlgo::UpdateEdgesBiPoints : error ";
cout << " between " << F1Index << setw(6);
Tri1Indices = OT->Indices();
Tri2Indices = NT->Indices();
if (!(Tri1Flags & FMskSide)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ((Tri1Flags & FMskFrBack) && DoTrace) {
cout << "HLRBRep_PolyAlgo::ReverseBackTriangle :";
cout << " face " << f << setw(6);
if (Hatcher.TrimDone (IndH) && !Hatcher.TrimFailed (IndH))
Hatcher.ComputeDomains (IndH);
if (!Hatcher.IsDone (IndH)) {
-#ifdef HLRTOBREP_DEB
+#ifdef OCCT_DEBUG
cout << "HLRTopoBRep::MakeIsoLines : Face " << FI << endl;
cout << "U iso of parameter: " << UPrm;
switch (Hatcher.Status (IndH)) {
if (Hatcher.TrimDone (IndH) && !Hatcher.TrimFailed (IndH))
Hatcher.ComputeDomains (IndH);
if (!Hatcher.IsDone (IndH)) {
-#ifdef HLRTOBREP_DEB
+#ifdef OCCT_DEBUG
cout << "HLRTopoBRep::MakeIsoLines : Face " << FI << endl;
cout << "V iso of parameter: " << VPrm;
switch (Hatcher.Status (IndH)) {
complist.GetFromIter(Loaded());
// Interface_Graph G(Model());
Interface_Graph G(thegraph);
-#ifdef PRINTDEB
+#ifdef OCCT_DEBUG
cout<<" SCRoots:"<<endl;
#endif
G.ResetStatus();
for (complist.Start(); complist.More(); complist.Next()) {
Handle(Standard_Transient) ent = complist.FirstEntity();
Standard_Integer num = G.EntityNumber(ent);
-#ifdef PRINTDEB
+#ifdef OCCT_DEBUG
cout<<" Iteration,num="<<num<<(G.IsPresent(num) ? " Pris" : " A prendre")<<endl;
#endif
if (!G.IsPresent(num)) { // enregistrer pour suivants
GetFromEntity (G.Entity(i),Standard_False);
}
#else
-#ifdef PRINTDEB
+#ifdef OCCT_DEBUG
cout<<"StrongComponants :"<<endl;
#endif
for (IFGraph_SortedStrongs res(G); res.More(); res.Next()) {
Standard_Integer nb = res.NbVertices();
-#ifdef PRINTDEB
+#ifdef OCCT_DEBUG
cout<<" Iteration, Vertices:"<<nb<<" :";
#endif
if (nb == 0) continue;
AddPart();
for (Standard_Integer i = 1; i <= nb; i ++)
-#ifdef PRINTDEB
+#ifdef OCCT_DEBUG
{
Handle(Standard_Transient) oneres = res.Value(i);
cout<<" "<<G.EntityNumber(oneres);
if (thedico.IsNull()) thedico = new Dico_DictionaryOfInteger;
Standard_Integer& num = thedico->NewItem(command,deja,Standard_True);
if (deja) {
-#ifdef IFSELECT_DEB
+#ifdef OCCT_DEBUG
cout<<"**** XSTEP commands, name conflict on "<<command<<" first defined remains ****"<<endl;
// Standard_DomainError::Raise("IFSelect_Activator : Add");
#endif
else {
Handle(IGESGraph_Color) color = Handle(IGESGraph_Color)::DownCast ( ent->Color() );
if ( color.IsNull() ) {
-#ifdef IGESCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Error: Unrecognized type of color definition" << endl;
#endif
IsColor = Standard_False;
case IGESData_DefOne : {
TCollection_ExtendedString aLayerName ( ent->Level() );
LTool->SetLayer( L, aLayerName );
-#ifdef DEB
+#ifdef OCCT_DEBUG
// cout << "Added layer " << aLayerName << endl;
#endif
break;
for ( Standard_Integer ilev = 1; ilev <= layerNb; ilev++ ) {
TCollection_ExtendedString aLayerName ( aLevelList->LevelNumber(ilev) );
LTool->SetLayer( L, aLayerName );
-#ifdef DEB
+#ifdef OCCT_DEBUG
// cout << "Added layer " << aLayerName << endl;
#endif
}
if ( FP->FindTypedTransient ( mapper, STANDARD_TYPE(IGESData_IGESEntity), Igesent ) ) {
Igesent->InitLevel( 0, localIntName );
}
-#ifdef IGESCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
else cout << "Warning: Can't find entity for shape in mapper" << endl;
#endif
}
TopoDS_Edge edge3d = Lsewd3d->Edge (iedge), edge2d = Lsewd2d->Edge (iedge);
if (!IGESToBRep::TransferPCurve (edge2d, edge3d, myface)) continue;
if (sfe->FixReversed2d (edge3d, myface)) {
-#ifdef IGESCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: IGESToBRep_IGESBoundary: 2D curve of edge was reversed" << endl;
#endif
}
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 IGESCONTROL_DEB
+#ifdef OCCT_DEBUG
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 IGESCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: IGESToBRep_IGESBoundary: 3D and 2D curves are inconsistent; 2D is ignored" << endl;
#endif
}
else {
-#ifdef IGESCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: IGESToBRep_IGESBoundary: 3D and 2D curves are inconsistent; 3D is ignored" << endl;
#endif
Lsewd = Lsewd2d;
}
okCurve = okCurve && ShapeAlgo::AlgoContainer()->ConnectNextWire (saw, Lsewd, maxtol, distmin, revsewd, revnextsewd);
if (!okCurve) {
-#ifdef IGESCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: IGESToBRep_IGESBoundary: Curves " << i - 1 << " and " << i << " cannot be connected" << endl;
#endif
Gsewd3d = new ShapeExtend_WireData;
if (!S) return Standard_False;
ComputeModel();
Standard_Integer nbEnt = themod->NbEntities();
-#ifdef IGESCONTROL_DEB
+#ifdef OCCT_DEBUG
cout<<" IGES Write : "<<nbEnt<<" ent.s"<< flush;
#endif
if(!nbEnt)
IGESData_IGESWriter IW (themod);
// ne pas oublier le mode fnes ... a transmettre a IW
IW.SendModel (IGESSelect_WorkLibrary::DefineProtocol());
-#ifdef IGESCONTROL_DEB
+#ifdef OCCT_DEBUG
cout<<" ... ecriture ..."<<flush;
#endif
if (fnes) IW.WriteMode() = 10;
Standard_Boolean status = IW.Print(S);
-#ifdef IGESCONTROL_DEB
+#ifdef OCCT_DEBUG
cout<<" ... fichier ecrit ..."<<endl;
#endif
return status;
{
ofstream fout(file,ios::out);
if (!fout) return Standard_False;
-#ifdef IGESCONTROL_DEB
+#ifdef OCCT_DEBUG
cout<<" Ecriture fichier ("<< (fnes ? "fnes" : "IGES") <<"): "<<file<<endl;
#endif
Standard_Boolean res = Write (fout,fnes);
const Handle(Interface_FileReaderData)& , const Standard_Integer ,
Handle(Interface_Check)& , const Handle(Standard_Transient)& ) const
{
-#ifdef IGESDATA_DEB
+#ifdef OCCT_DEBUG
cout<<"IGESData_ReadWriteModule, Read called"<<endl;
#endif
}
Standard_Integer it = ent->TypeNumber();
if (it == 112 || it == 126) {
thefound = Standard_True;
-#ifdef IGESSELECT_DEB
+#ifdef OCCT_DEBUG
cout<<"IGESSelect_SplineToBSpline : n0."<<i
<< (it == 112 ? ", Curve" : ", Surface")<<" to convert"<<endl;
#endif
olda = a; oldb = b; oldpcurve = newpcurve;
}
else {
-#ifdef IGESTOBREP_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: IGESToBRep::TransferPCurve: pcurves are not SameRange" << endl;
#endif
result = Standard_False;
}
}
catch(Standard_Failure) {
-#ifdef IGESTOBREP_DEB
+#ifdef OCCT_DEBUG
cout << "\n**IGESToBRep::TransferPCurve: Exception in SameRange : ";
Standard_Failure::Caught()->Print(cout);
#endif
} //:36
catch(Standard_Failure) {
-#ifdef IGESTOBREP_DEB
+#ifdef OCCT_DEBUG
cout << "\n** Exception in IGESToBRep_BasicCurve::TransferBasicCurve : ";
Standard_Failure::Caught()->Print(cout);
#endif
}
} //:h8
catch(Standard_Failure) {
-#ifdef IGESTOBREP_DEB
+#ifdef OCCT_DEBUG
cout << "\n** Exception in IGESToBRep_BasicCurve::Transfer2dBasicCurve : ";
Standard_Failure::Caught()->Print(cout);
#endif
BSplineRes = new Geom_BSplineCurve(Poles, Weight, Knot, Mult, Degree);
}
catch(Standard_Failure) {
-#ifdef IGESTOBREP_DEB
+#ifdef OCCT_DEBUG
cout << "\n** Exception in IGESToBRep_BasicCurve::TransferBSplineCurve during creation of Geom_BSplineCurve : ";
Standard_Failure::Caught()->Print(cout);
#endif
} //:36
catch(Standard_Failure) {
-#ifdef IGESTOBREP_DEB
+#ifdef OCCT_DEBUG
cout << "\n** Exception in IGESToBRep_BasicSurface::TransferBasicSurface : ";
Standard_Failure::Caught()->Print(cout);
#endif
}
catch (Standard_Failure)
{
-#ifdef IGESTOBREP_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: IgesToBRep_TopoSurface::"
"TransferSurfaceOfRevolution(): exception by Geom: ";
Standard_Failure::Caught()->Print ( cout ); cout << endl;
}
}
catch (Standard_Failure) {
-#ifdef IGESTOBREP_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: IgesToBRep_TopoSurface::TransferTabulatedCylinder(): exception by Geom: ";
Standard_Failure::Caught()->Print ( cout ); cout << endl;
#endif
if (myshape.IsNull()) {
//#55 rln 24.12.98 UKI60878 entity D593
-#ifdef IGESTOBREP_DEB
+#ifdef OCCT_DEBUG
cout << "Fail: IGESToBRep_TopoSurface::TransferBoundedSurface UntrimmedSurface is translated into Null" << endl;
#endif
return res;
#endif
if (anImageFormat == FIF_UNKNOWN)
{
-#ifdef IMAGE_DEB
+#ifdef OCCT_DEBUG
std::cerr << "Image_PixMap, image format doesn't supported!\n";
#endif
return false;
{
return savePPM (theFileName);
}
-#ifdef IMAGE_DEB
+#ifdef OCCT_DEBUG
std::cerr << "Image_PixMap, no image library available! Image saved in PPM format.\n";
#endif
return savePPM (theFileName);
|| theImageRef->SizeY() != theImageNew->SizeY()
|| theImageRef->Format() != theImageNew->Format())
{
-#ifdef IMAGE_DEB
+#ifdef OCCT_DEBUG
std::cerr << "Images has different format or dimensions\n";
#endif
return Standard_False;
}
else if (!isSupportedFormat (theImageRef->Format()))
{
-#ifdef IMAGE_DEB
+#ifdef OCCT_DEBUG
std::cerr << "Images has unsupported pixel format\n";
#endif
return Standard_False;
else if (theImageRef->SizeX() >= 0xFFFF
|| theImageRef->SizeY() >= 0xFFFF)
{
-#ifdef IMAGE_DEB
+#ifdef OCCT_DEBUG
std::cerr << "Image too large\n";
#endif
return Standard_False;
if (!anImgRef->Load (theImgPathRef)
|| !anImgNew->Load (theImgPathNew))
{
-#ifdef IMAGE_DEB
+#ifdef OCCT_DEBUG
std::cerr << "Failed to load image(s) file(s)\n";
#endif
return Standard_False;
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
#include <Standard_Stream.hxx>
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
//-- If the intersection is not a conic,
//-- analytical methods must be called.
//----------------------------------------------------------------------
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
// Modified by skv - Tue Mar 1 14:22:09 2005 OCC8169
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
//#define No_Standard_RangeError
//#define No_Standard_OutOfRange
//#endif
Standard_Integer nbp = intlintorus.NbPoints();
Standard_Real fi,theta,w;
for(Standard_Integer i = 1; i<= nbp; i++) {
-#ifndef DEB
+#ifndef OCCT_DEBUG
gp_Pnt P;
P = intlintorus.Value(i);
#else
{
ProjLib_Plane aLineProj( thePln, theLine );
if (!aLineProj.IsDone()) {
-#ifdef INTCURVESURFACE_DEB
+#ifdef OCCT_DEBUG
cout
<< "Info: IntCurveSurface_Inter::ProjectIntersectAndEstLim(), !aLineProj.IsDone()"
<< endl;
return; // not infinite curve
}
if (!aBasCurvProj.IsDone()) {
-#ifdef INTCURVESURFACE_DEB
+#ifdef OCCT_DEBUG
cout << "Info: IntCurveSurface_Inter::EstLimForInfRevl(), !aBasCurvProj.IsDone()" << endl;
#endif
return;
{
//ddout << "IntCurveSurface_Polygon::ApproxParamOnCurve" << endl;
if(TheParamOnLine < 0.0 || TheParamOnLine >1.0) {
-#ifdef INTCURVESURFACE_DEB
+#ifdef OCCT_DEBUG
cout<<" ParamOnLine = "<<TheParamOnLine<<" avec Index = "
<<TheIndex<<" dans IntCurveSurface_Polygon::ApproxParamOnCurve"<<endl;
#endif
Standard_Integer Index = TheIndex;
Standard_Real ParamOnLine = TheParamOnLine;
-#ifdef INTCURVESURFACE_DEB
+#ifdef OCCT_DEBUG
if (Index > NbPntIn) {
cout << "OutOfRange Polygon::ApproxParamOnCurve " <<endl;
}
#include <Standard_ConstructionError.hxx>
-//#if defined (WNT) || !defined (DEB)
#include <stdio.h>
-//#endif
#define CHECKBOUNDS 0
// Modified by Sergey KHROMOV - Fri Dec 7 11:23:34 2001 End
- #ifdef DEBUGDUMP
+ #ifdef OCCT_DEBUG_DUMP
Dump();
#endif
}
// Modified by Sergey KHROMOV - Fri Dec 7 11:23:34 2001 End
- #ifdef DEBUGDUMP
+ #ifdef OCCT_DEBUG_DUMP
Dump();
#endif
}
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
#include <gp_Pnt.hxx>
#include <gp_Vec.hxx>
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
#define EpsAng2 1.e-16
#define Tolpetit 1.e-16
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
#include <gp_Pnt2d.hxx>
#include <gp_Vec2d.hxx>
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
const Standard_Real u1alin,
Standard_Real& actualdist) {
Standard_Real dtheta,theta;
-#ifdef DEB
+#ifdef OCCT_DEBUG
//Standard_Real u,v,A,B,C,cost,sint,sign;
#endif
//-- recherche bete du point le plus proche de thearc->Value(...)
//-- le point n a pas ete trouve par bete projection.
//-- on essaie l intersection avec la restriction en 2d
Standard_Real theparamonarc = theparameteronarc;
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
// Standard_Real anpara=para;
//#endif
gp_Pnt CopiePsurf=Psurf;
gp_Vec2d d2d;
gp_Vec d1u,d1v,tgrest,tgarc,norm;
IntSurf_Transition TRest,TArc;
-#ifndef DEB
+#ifndef OCCT_DEBUG
Standard_Real U =0.,V =0.;
#else
Standard_Real U,V;
#include <IntPatch_WLine.hxx>
#include <IntPatch_ArcFunction.hxx>
#include <IntPatch_RstInt.hxx>
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
break;
}
if(allon1==NbPnts || allon2==NbPnts) {
-#ifdef INTPATCH_DEB
+#ifdef OCCT_DEBUG
cout<<" IntPatch_LineConstructor.gxx : CC**ONS"<<(allon1==NbPnts?1:2)<<"** Traitement WLIne + ARC CLASS "<<endl;
#endif
Standard_Real tol2d = Max(tol2d1,tol2d2);
if (!arc1.IsNull() && arc1 == arc) iv2 = iv;
}
if (!iv1 || !iv2) {
-#ifdef INTPATCH_DEB
+#ifdef OCCT_DEBUG
cout<<" Pb getting vertices linked with arc"<<endl;
#endif
continue;
Standard_Real par2 = (arcsResolved(iv2).IsNull()
? (WLine->Vertex(iv2).*pParOnArc)()
: paramsResolved(iv2));
-#ifdef INTPATCH_DEB
+#ifdef OCCT_DEBUG
cout<<"****** Parameters on arc on S"<<is+1<<": "<<par1<<" "<<par2<<endl;
#endif
}
Standard_Real par,dist;
if (!ProjectOnArc(utst,vtst,arc,surf,TolArc,par,dist)) {
-#ifdef INTPATCH_DEB
+#ifdef OCCT_DEBUG
cout<<" Pb en projection ds IntPatch_LineConstructor"<<endl;
#endif
continue;
// Standard_Real nIncrement=Increment;
// if(MaxOscill>10) {
- // #ifdef DEB
+ // #ifdef OCCT_DEBUG
// cout<<"\n IntPatch_PrmPrmIntersection.gxx : Increment:"<<Increment<<" -> "<<Increment/(0.5*MaxOscill)<<endl;
// #endif
// nIncrement/=0.5*MaxOscill;
#include <IntPolyh_Couple.hxx>
#include <IntPolyh_Triangle.hxx>
-#ifdef DEB
- # define MYDEBUG DEB
-#else
- # define MYDEBUG 0
-#endif
-
Standard_Integer MYDISPLAY = 0;
Standard_Integer MYPRINT = 0;
-# if MYDEBUG
-// # include "visudebug.hxx"
-# endif
-
-
IntPolyh_Intersection::IntPolyh_Intersection(const Handle(Adaptor3d_HSurface)& S1,
const Handle(Adaptor3d_HSurface)& S2)
{
//purpose :
//=======================================================================
-// # ifdef DEB
-// #define BORNES1
-// # endif
-const IntPolyh_StartPoint& IntPolyh_SectionLine::Value(const Standard_Integer Index) const {
-// IntPolyh_StartPoint *ptrstpoint = (IntPolyh_StartPoint *)ptr;
-// #if BORNES
-// if(Index<0 || Index>=n) {
-// cerr<<" Erreur1 "<<endl;
-// printf("Value() from IntPolyh_SectionLine.cxx : ERROR : value out of array\n");
-// }
-// #endif
-// return(ptrstpoint[Index]);
+const IntPolyh_StartPoint& IntPolyh_SectionLine::Value(const Standard_Integer Index) const
+{
return mySeqOfSPoints(Index+1);
}
//purpose :
//=======================================================================
-IntPolyh_StartPoint& IntPolyh_SectionLine::ChangeValue(const Standard_Integer Index) {
-// IntPolyh_StartPoint *ptrstpoint = (IntPolyh_StartPoint *)ptr;
-// #if BORNES
-// if(Index<0 || Index>=n) {
-// cerr<<" Erreur1 "<<endl;
-// printf("ChangeValue() from IntPolyh_SectionLine.cxx : ERROR : value out of array\n");
-// }
-// #endif
-// return(ptrstpoint[Index]);
+IntPolyh_StartPoint& IntPolyh_SectionLine::ChangeValue(const Standard_Integer Index)
+{
return mySeqOfSPoints(Index+1);
}
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
vtx = Domain->Vertex();
dist= Abs(Para-TheSOBTool::Parameter(vtx,A));
toler = TheSOBTool::Tolerance(vtx,A);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(toler>0.1) {
cout<<"IntStart_SearchOnBoundaries_1.gxx : ** WARNING ** Tol Vertex="<<toler<<endl;
cout<<" Ou Edge degenere Ou Kro pointu"<<endl;
static
void RefineVector(gp_Vec2d& aV2D);
-#ifdef DEB_DUMPWLINE
+#ifdef OCCT_DEBUG_DUMPWLINE
static
void DumpWLine(const Handle(IntPatch_WLine)& aWLine);
#endif
}
return aIndex;
}
-#ifdef DEB_DUMPWLINE
+#ifdef OCCT_DEBUG_DUMPWLINE
//=======================================================================
//function : DumpWLine
//purpose :
//-- IntWalk_IWalking_2.gxx
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
}
Line->SetTangentVector(previousd3d,j-1);
}
-#ifdef INTWALK_DEB
+#ifdef OCCT_DEBUG
else {
cout<<" IntWalk_IWalking_2.gxx : bizarrerie 30 10 97 "<<endl;
}
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#endif
if(Arrive==Standard_False && Status==IntWalk_ArretSurPoint)
{
Arrive=Standard_True;
-#ifdef DEB
- cout << "Compile with option DEB : if problems with intersection : ";
- cout << "IntWalk_PWalking_1.gxx (lbr le 1erdec98)"<<endl;
+#ifdef OCCT_DEBUG
+ cout << "IntWalk_PWalking_1.gxx: Problems with intersection"<<endl;
#endif
}
nbIterWithoutAppend++;
if((nbIterWithoutAppend > 20) || (nbEqualPoints > 20)) {
-#ifdef DEB
- cout<<"Compile with option DEB:";
- cout<<"Infinite loop has detected. Stop iterations (IntWalk_PWalking_1.gxx)" << endl;
+#ifdef OCCT_DEBUG
+ cout<<"Infinite loop detected. Stop iterations (IntWalk_PWalking_1.gxx)" << endl;
#endif
bStop = Standard_True;
break;
(const Standard_Integer num, const Handle(Standard_Transient)& ent)
// { theents.SetValue(num,ent); }
{
-// #ifdef DEB
+// #ifdef OCCT_DEBUG
// if (ent.IsImmutable())
// cout << "Bind IMMUTABLE:"<<num<<endl;
// #endif
{
Handle(Interface_Static) item = Interface_Static::Static(name);
if (item.IsNull()) {
-#ifdef INTERFACE_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: Interface_Static::CVal: incorrect parameter " << name << endl;
#endif
return "";
{
Handle(Interface_Static) item = Interface_Static::Static(name);
if (item.IsNull()) {
-#ifdef INTERFACE_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: Interface_Static::IVal: incorrect parameter " << name << endl;
#endif
return 0;
{
Handle(Interface_Static) item = Interface_Static::Static(name);
if (item.IsNull()) {
-#ifdef INTERFACE_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: Interface_Static::RVal: incorrect parameter " << name << endl;
#endif
return 0.0;
return Standard_True;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
#ifndef WNT
//=======================================================================
// Debug Function for DBX: use "print -p <Variable> or pp <Variable>"
// Check attribute hash value against the current mask
const unsigned int anAttrMaskValue = aHash & (8*sizeof(myAttributeMask) - 1);
const unsigned long anAttributeMask = (1 << anAttrMaskValue);
-#ifdef DEBUG_MASK
+#ifdef OCCT_DEBUG_MASK
anAttributeMask = 0xffffffff;
#endif
if ((myAttributeMask & anAttributeMask) == 0) {
LDOM_MemManager::Hash (aNameStr, (Standard_Integer)strlen(aNameStr));
const unsigned int anAttrMaskValue = aHash & (8*sizeof(myAttributeMask) - 1);
const unsigned long anAttributeMask = (1 << anAttrMaskValue);
-#ifdef DEBUG_MASK
+#ifdef OCCT_DEBUG_MASK
anAttributeMask = 0xffffffff;
#endif
if ((myAttributeMask & anAttributeMask) == 0) {
return mySibling;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
#ifndef WNT
//=======================================================================
// Debug Function for DBX: use "print -p <Variable> or pp <Variable>"
LDOM_MemManager::~LDOM_MemManager ()
{
-#ifdef LDOM_DEB
+#ifdef OCCT_DEBUG
Standard_Integer aSomme = 0, aCount = 0;
MemBlock * aBlock = myFirstBlock;
//FILE * out = fopen ("/tmp/dump","w");
myError = "Improper element tag termination";
else {
myPtr += 2;
-#ifdef DEB
+#ifdef OCCT_DEBUG
theData.Clear();
theData << myElement->GetTagName();
#endif
return XML_UNKNOWN;
}
++ myPtr;
-#ifdef DEB
+#ifdef OCCT_DEBUG
theData.Clear();
theData << myElement->GetTagName();
#endif
#include <gp_Vec2d.hxx>
#include <Law_Interpolate.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#ifdef DRAW
// Pour le dessin.
Law_Interpolate inter(rad,par,Periodic,Precision::Confusion());
inter.Perform();
SetCurve(inter.Curve());
-#ifdef DEB
+#ifdef OCCT_DEBUG
#ifdef DRAW
if (Affich) {
gp_Vec2d veve(0.,0.);
Law_Interpolate inter(rad,par,Periodic,Precision::Confusion());
inter.Perform();
SetCurve(inter.Curve());
-#ifdef DEB
+#ifdef OCCT_DEBUG
#ifdef DRAW
if (Affich) {
gp_Vec2d veve(0.,0.);
return Standard_False;
}
}
-#ifdef LOCOPE_DEB
+#ifdef OCCT_DEBUG
cout << "Classification impossible sur vertex " << endl;
#endif
#include <BRepTools.hxx>
#include <Standard_ConstructionError.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean BRepFeat_GettraceFEAT();
#endif
Normale.Reverse();
}
if (mySpine.Orientation() == TopAbs_REVERSED) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = BRepFeat_GettraceFEAT();
if (trc) {
cout << "LocOpe_DPrism::BarycCurve()" << endl;
}
else {
// Cas non traite : on est a cheval
-#ifdef LOCOPE_DEB
+#ifdef OCCT_DEBUG
cout <<" cas a cheval."<< endl;
#endif
}
else {
// Cas non traite : on est a cheval
-#ifdef LOCOPE_DEB
+#ifdef OCCT_DEBUG
cout <<" cas a cheval."<< endl;
#endif
// myLFrom.Append(edgf);
}
if (IsSame) {
-#ifdef LOCOPE_DEB
+#ifdef OCCT_DEBUG
cout <<"memes bsplines."<< endl;
#endif
myLFrom.Append(edgf);
}
if (IsSame) {
-#ifdef LOCOPE_DEB
+#ifdef OCCT_DEBUG
cout <<"memes beziers."<< endl;
#endif
myLFrom.Append(edgf);
MapW(edg) = GenF;
}
else {
-#ifdef DEB
+#ifdef OCCT_DEBUG
cout << "Pb d'analyse" << endl;
#endif
return;
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;
}
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Real ptol = Precision::PConfusion();
if (prmf < imf - ptol || prmf > iml + ptol ||
prml < imf - ptol || prml > iml + ptol) {
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;
Rebuild(myShape);
myDone = Standard_True;
}
-#ifdef LOCOPE_DEB
+#ifdef OCCT_DEBUG
if (!myDblE.IsEmpty()) {
cout << "Le shape comporte des faces invalides" << endl;
}
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;
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();
}
theSubs.Substitute(ebase.Oriented(TopAbs_FORWARD),lsubs);
}
else {
-#ifdef LOCOPE_DEB
+#ifdef OCCT_DEBUG
cout << "Pb pour substitution" << endl;
#endif
}
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();
}
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;
Handle(MAT_ListOfBisector) BisectorList;
Standard_Real DistExt;
-#ifdef DEBUG_Graph
+#ifdef OCCT_DEBUG_Graph
cout<<"Construction Arc : Index"<<aBisector->IndexNumber()<<endl;
cout<<"Construction Arc : Bisector"<<aBisector->BisectorNumber()<<endl;
#endif
DistExt = aBisector->DistIssuePoint();
if (DistExt == Precision::Infinite()) {
DistExt = 1.0;
-#ifdef DEBUG_Graph
+#ifdef OCCT_DEBUG_Graph
cout<<"PB:RECUPERATION DISTANCE SUR ISSUEPOINT."<<endl;
#endif
}
NextArc ->SetNeighbour(MAT_Right,Extremite,CurrentArc);
}
-#ifdef DEBUG_Graph
+#ifdef OCCT_DEBUG_Graph
cout<<"IndTabArcs = "<<IndTabArcs<<endl;
cout<<"ArcIndex = "<<CurrentArc->ArcIndex()<<endl;
#endif
#include <DrawTrSurf_Curve2d.hxx>
#include <Draw_Marker2D.hxx>
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <GCE2d_MakeSegment.hxx>
#include <Geom2d_Curve.hxx>
#include <Geom2d_Parabola.hxx>
static Handle(DrawTrSurf_Curve2d) draw;
Standard_EXPORT Draw_Viewer dout;
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
static void MAT2d_DrawCurve(const Handle(Geom2d_Curve)& aCurve,
const Standard_Integer Indice);
static Standard_Boolean AffichCircuit = 0;
//------------------------
Road.RunOnConnexions();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (AffichCircuit) {
Standard_Integer NbConnexions = Road.Path().Length();
for (i = 1; i <= NbConnexions; i++) {
Geom2dInt_GInter Intersect;
Intersect.Perform(OC1,OC2,Tol,Tol);
-#ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_Boolean Affich = 0;
if (Affich) {
#ifdef DRAW
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (AffichCircuit) {
ILastItem = geomElements.Length();
for (i = 1; i <= ILastItem; i++) {
Corres(i) = Corres(2*NbItems - i);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (AffichCircuit) {
for (i = 1; i <= 2*NbItems - 2; i++) {
cout<< "Correspondance "<< i<<" -> "<<Corres(i)<<endl;
isuiv = (i == Line.Length()) ? 1 : i + 1;
Insert = IsSharpCorner(Line.Value(i),Line.Value(isuiv),direction);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (AffichCircuit) {
if (Insert) {
Curve = Handle(Geom2d_TrimmedCurve)::DownCast(Line.Value(isuiv));
-#ifdef DEB
+#ifdef OCCT_DEBUG
//==========================================================================
//function : MAT2d_DrawCurve
//purpose : Affichage d une courbe <aCurve> de Geom2d. dans une couleur
atool.CreateBisector(bisectormap(i));
thenumberofbisectors++;
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
atool.Dump(bisectormap(i)->BisectorNumber(),1);
#ifdef ICONTINUE
cin>>Icontinue;
for(;;){
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
atool.Dump(bisectortoremove->BisectorNumber(),0);
#endif
// ----------------------------------
currentedge->FirstBisector(currentbisector);
previousedge->SecondBisector(currentbisector);
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
atool.Dump(currentbisector->BisectorNumber(),0);
#endif
atool.TrimBisector(currentbisector);
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
atool.Dump(currentbisector->BisectorNumber(),1);
#endif
currentedge->Distance(-1.);
// lastarea[i] : indice dernier edge de la portion i.
//-----------------------------------------------------------------
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
cout <<" Test sur les parametres pour elimination"<<endl;
cout << " Edge number :"<<theedgelist->Current()->EdgeNumber()<<endl;
#endif
if(paramb[0] > 0 && parama[1] > 0) {
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
cout <<" A ELIMINER "<<endl;
#endif
if(narea < 0) {
edgetoremove->FirstBisector()->EndPoint(edgetoremove
->IntersectionPoint());
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
atool.Dump(edgetoremove->FirstBisector()->BisectorNumber(),0);
#endif
edgetoremove->FirstBisector()->FirstParameter
(edgetoremove->FirstBisector()->SecondParameter());
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
if(atool.TrimBisector(edgetoremove->FirstBisector()))
atool.Dump(edgetoremove->FirstBisector()->BisectorNumber(),1);
#else
theedgelist->Next();
shift++;
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
cout<<" Suppression de l'arete : "<<edgetoremove->EdgeNumber()<<endl;
#endif
edgetoremove->SecondBisector()->EndPoint(edgetoremove
->IntersectionPoint());
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
atool.Dump(edgetoremove->SecondBisector()->BisectorNumber(),0);
#endif
edgetoremove->SecondBisector()->SecondParameter
(edgetoremove->SecondBisector()->FirstParameter());
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
if(atool.TrimBisector(edgetoremove->SecondBisector()))
atool.Dump(edgetoremove->SecondBisector()->BisectorNumber(),1);
#else
atool.CreateBisector(bisectormap(i));
thenumberofbisectors++;
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
atool.Dump(bisectormap(i)->BisectorNumber(),1);
#ifdef ICONTINUE
cin>>Icontinue;
for(;;){
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
atool.Dump(bisectortoremove->BisectorNumber(),0);
#endif
// ----------------------------------
currentedge->FirstBisector(currentbisector);
previousedge->SecondBisector(currentbisector);
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
atool.Dump(currentbisector->BisectorNumber(),0);
#endif
atool.TrimBisector(currentbisector);
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
atool.Dump(currentbisector->BisectorNumber(),1);
#endif
currentedge->Distance(-1.);
// lastarea[i] : indice dernier edge de la portion i.
//-----------------------------------------------------------------
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
cout <<" Test sur les parametres pour elimination"<<endl;
cout << " Edge number :"<<theedgelist->Current()->EdgeNumber()<<endl;
#endif
if(paramb[0] > 0 && parama[1] > 0) {
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
cout <<" A ELIMINER "<<endl;
#endif
if(narea < 0) {
edgetoremove->FirstBisector()->EndPoint(edgetoremove
->IntersectionPoint());
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
atool.Dump(edgetoremove->FirstBisector()->BisectorNumber(),0);
#endif
edgetoremove->FirstBisector()->FirstParameter
(edgetoremove->FirstBisector()->SecondParameter());
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
if(atool.TrimBisector(edgetoremove->FirstBisector()))
atool.Dump(edgetoremove->FirstBisector()->BisectorNumber(),1);
#else
theedgelist->Next();
shift++;
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
cout<<" Suppression de l'arete : "<<edgetoremove->EdgeNumber()<<endl;
#endif
edgetoremove->SecondBisector()->EndPoint(edgetoremove
->IntersectionPoint());
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
atool.Dump(edgetoremove->SecondBisector()->BisectorNumber(),0);
#endif
edgetoremove->SecondBisector()->SecondParameter
(edgetoremove->SecondBisector()->FirstParameter());
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
if(atool.TrimBisector(edgetoremove->SecondBisector()))
atool.Dump(edgetoremove->SecondBisector()->BisectorNumber(),1);
#else
}
if(found != -1) {
-#ifdef DEBUG_Mat
+#ifdef OCCT_DEBUG_Mat
cout<<" first last bisector to remove :"<<
firstbisectortoremove[index]->BisectorNumber()<<" "<<
lastbisectortoremove[index]->BisectorNumber()<<endl;
#ifdef DRAW
static Handle(DrawTrSurf_Curve2d) draw;
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
static void MAT2d_DrawCurve(const Handle(Geom2d_Curve)& aCurve,
const Standard_Integer Indice);
static Standard_Boolean Store = Standard_False;
item2 = Handle(Geom2d_Curve)::DownCast(elt2);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean Affich = Standard_False;
if (Affich) {
cout<<endl;
abisector->BisectorNumber(theNumberOfBisectors);
abisector->Sense(1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean AffichDraw = Standard_False;
if (AffichDraw) Dump(abisector->BisectorNumber(),1);
if (Store) {
{
Standard_Real param = abisector->FirstParameter();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean Affich = Standard_False;
if (Affich) cout<<"TRIM de "<<abisector->BisectorNumber()<<endl;
#endif
if(Bisector->LastParameter() < Param)return Standard_False;
Bisector->SetTrim(Bisector->FirstParameter(),Param);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean Affich = Standard_False;
if (Affich) MAT2d_DrawCurve(Bisector,2);
#endif
else if (IEdge4 == IEdge2) Dist(4) = Dist(2);
else Projection(IEdge4,PCom,Dist(4));
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean Affich = Standard_False;
if (Affich)
for (Standard_Integer j = 1; j <= 4;j++){
if (Domain2.LastParameter() - Domain2.FirstParameter() < Tolerance)
return Precision::Infinite();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean Affich = Standard_False;
if (Affich) {
cout<<endl;
BisectorOne->SecondParameter(Param1);
BisectorTwo->FirstParameter (Param2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (Affich) {
cout<<" coordonnees : "<<GeomPnt (IntPnt).X()<<" "
<<GeomPnt (IntPnt).Y()<<endl;
//function : Dump
//purpose :
//=============================================================================
-#ifndef DEB
+#ifndef OCCT_DEBUG
void MAT2d_Tool2d::Dump(const Standard_Integer ,
const Standard_Integer ) const
{
return Domain1;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
//==========================================================================
//function : MAT2d_DrawCurve
//purpose : Affichage d une courbe <aCurve> de Geom2d. dans une couleur
#include <Standard_GUID.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <Standard_ConstructionError.hxx>
#endif
// Label array REsizing.
if (labAlloc < theLabels->Upper()) {
-#ifdef MDF_DEB
+#ifdef OCCT_DEBUG
cout<<"MDF_Tool::WriteLabels LABEL array resizing from "<<theLabels->Upper()<<" to "<<labAlloc<<endl;
#endif
Handle(PColStd_HArray1OfInteger) newLabels =
// Attribute array REsizing.
if (attAlloc < theAttributes->Upper()) {
-#ifdef MDF_DEB
+#ifdef OCCT_DEBUG
cout<<"MDF_Tool::WriteLabels ATTRIBUTES array resizing from "<<theAttributes->Upper()<<" to "<<attAlloc<<endl;
#endif
Handle(PDF_HAttributeArray1) newAttributes =
if (childLabIndex < labAlloc) ++count;
}
-#ifdef DEB_MDF_TOOL
+#ifdef OCCT_DEBUG_MDF_TOOL
aSourceLab.EntryDump(cout);
cout<<" Count="<<count<<" attIndex="<<attIndex<<" attAlloc="<<attAlloc;
#endif
else {
labAlloc -= 2;
theLabels->SetValue(labAlloc--,0); // To clean the tag value.
-#ifdef DEB_MDF_TOOL
+#ifdef OCCT_DEBUG_MDF_TOOL
cout<<" <== Cleared";
#endif
}
-#ifdef DEB_MDF_TOOL
+#ifdef OCCT_DEBUG_MDF_TOOL
cout<<endl;
#endif
}
const Handle(Standard_Type)& type = pAtt->DynamicType();
if(!strcmp (type->Name(), "PNaming_Naming_1") ) {
-#ifdef DEB_ORIENT
+#ifdef OCCT_DEBUG_ORIENT
cout << "TYPE = " << type->Name() << endl;
#endif
isName1 = Standard_True;
}
if (!noDeadLock) {
-#ifdef MDF_DEB
+#ifdef OCCT_DEBUG
cout<<"AfterRetrieval(): dead lock between these attributes:"<<endl;
for (itr2.Initialize(attList); itr2.More(); itr2.Next())
cout<<"Attribute type = "<<itr2.Value()->DynamicType()->Name()<<endl;;
Handle(TDataStd_NamedData) T = Handle(TDataStd_NamedData)::DownCast (Target);
if(S.IsNull() || T.IsNull()) return;
Standard_Integer i;
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout << "Start: " <<S->LowerI() << " " <<S->UpperI()<<"\t"<<S->LowerR() << " " <<S->UpperR();
cout << "\t"<<S->LowerS() << " " <<S->UpperS()<< "\t"<<S->LowerB() << " " <<S->UpperB();
cout << "\t"<<S->LowerAI() << " " <<S->UpperAI()<<"\t"<<S->LowerAR() << " " <<S->UpperAR()<<endl;
{
TCollection_AsciiString STR;
TDF_Tool::Entry(LabS,STR);
-#ifdef DEB
+#ifdef OCCT_DEBUG
cout << "Label to process: "<<STR<<endl;
#endif
Handle(TNaming_NamedShape) NS;
Handle(Standard_Transient) MDocStd::Factory(const Standard_GUID& aGUID) {
if(aGUID == StandardStorageDriver) {
-#ifdef MDOCSTD_DEB
+#ifdef OCCT_DEBUG
cout << "MDocStd : Storage Plugin" << endl;
#endif
static Handle(MDocStd_DocumentStorageDriver) standard_sd = new MDocStd_DocumentStorageDriver;
return standard_sd;
}
if(aGUID == StandardRetrievalDriver) {
-#ifdef MDOCSTD_DEB
+#ifdef OCCT_DEBUG
cout << "MDocStd : Retrieval Plugin" << endl;
#endif
static Handle (MDocStd_DocumentRetrievalDriver) standard_rd = new MDocStd_DocumentRetrievalDriver;
// Orientation processing
Handle(TNaming_NamedShape) aNS;
if(F->Label().FindAttribute(TNaming_NamedShape::GetID(), aNS)) {
-#ifdef DEB_ORIENT
+#ifdef OCCT_DEBUG_ORIENT
const TDF_Label& aLab = aNS->Label();
TCollection_AsciiString entry;
TDF_Tool::Entry(aLab, entry);
if (itL.More() && itL.NewShape().ShapeType() != TopAbs_VERTEX &&
!itL.OldShape().IsNull() && itL.OldShape().ShapeType() == TopAbs_VERTEX ) {//OR-N
TopAbs_Orientation OrientationToApply = itL.OldShape().Orientation();
-#ifdef DEB_ORIENT
+#ifdef OCCT_DEBUG_ORIENT
cout <<"Retrieved Orientation = " << OrientationToApply <<endl;
#endif
F->ChangeName().Orientation(OrientationToApply);
if( S->Width() != -1. ) T->SetWidth( S->Width() );
else T->UnsetWidth();
-#ifdef MPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "AISPresentationRetrievalDriver " << "retrieved DriverGUID ==> ";
guid.ShallowDump(cout);
cout << endl;
T->SetMode(S->Mode());
-#ifdef MPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "AISPresentationRetrievalDriver " << "retrieved DriverGUID ==> ";
guid.ShallowDump(cout);
cout << endl;
T->SetMode(S->Mode());
-#ifdef MPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "AISPresentationStorageDriver " << "storaged DriverGUID ==> " << guid->Convert() << endl;
#endif
}
#define ONETHIRD 0.333333333333333333333333333333333333333333333333333333333333
#define TWOTHIRD 0.666666666666666666666666666666666666666666666666666666666666
-#ifdef DEB_MESH_CHRONO
+#ifdef OCCT_DEBUG_MESH_CHRONO
#include <OSD_Chronometer.hxx>
Standard_Integer D0Control, D0Internal, D0Unif, D0Edges, NbControls;
OSD_Chronometer chTotal, chInternal, chControl, chUnif, chAddPoint;
di<<" " <<nbnodes <<" nodes."<<"\n";
di<<"Maximal deflection " <<MaxDeflection<<"\n";
di<<"\n";
-#ifdef DEB_MESH_CHRONO
+#ifdef OCCT_DEBUG_MESH_CHRONO
Standard_Real tot, addp, unif, contr, inter;
Standard_Real edges, mailledges, etuinter, lastcontrol, stock;
Standard_Real add11, add12, add2, upda, pointvalid;
Handle(Poly_PolygonOnTriangulation) aPoly1 =
BRep_Tool::PolygonOnTriangulation(aEdge, aT1, aLoc1);
if (aPoly1.IsNull() || aT1.IsNull()) {
-#ifdef MESHTEST_DEB
+#ifdef OCCT_DEBUG
cout<<"problem getting PolygonOnTriangulation of edge "<<ie<<endl;
#endif
continue;
Handle(Poly_PolygonOnTriangulation) aPoly2 =
BRep_Tool::PolygonOnTriangulation(aEdge, aT2, aLoc2);
if (aPoly2.IsNull() || aT2.IsNull()) {
-#ifdef MESHTEST_DEB
+#ifdef OCCT_DEBUG
cout<<"problem getting PolygonOnTriangulation of edge "<<ie<<endl;
#endif
continue;
// It is very important to call this parent method, because it check whether
// mySelectionPrs is created and if not, create it.
-#ifdef _DEBUG
+#ifdef OCCT_DEBUG
OSD_Timer gTimer;
gTimer.Reset();
gTimer.Start();
aSelectionPrs->Display();
}
-#ifdef _DEBUG
+#ifdef OCCT_DEBUG
Standard_Real sec, cpu;
Standard_Integer min, hour;
{
delete aFile;
myStream = &std::cout;
-#ifdef MESSAGE_DEB
+#ifdef OCCT_DEBUG
std::cerr << "Error opening " << theFileName << std::endl << std::flush;
#endif
}
return MgtGeom::Translate(TOffsetCurve);
}
else {
-#ifdef MGTGEOM_DEB
+#ifdef OCCT_DEBUG
cout << "MgtGeom : Unknown curve type ???? : " << endl;
#endif
Standard_NullObject::Raise("No mapping for the current Persistent Curve");
return MgtGeom::Translate(POffsetCurve);
}
else {
-#ifdef MGTGEOM_DEB
+#ifdef OCCT_DEBUG
cout << "MgtGeom : Unknown curve type ????"<<endl;
#endif
Standard_NullObject::Raise("No mapping for the current Transient Curve");
return MgtGeom::Translate(TOffsetSurface);
}
else {
-#ifdef MGTGEOM_DEB
+#ifdef OCCT_DEBUG
cout << "MgtGeom : Unknown surface type ????"<<endl;
#endif
Standard_NullObject::Raise("No mapping for the current Persistent Surface");
return MgtGeom::Translate(POffsetSurface);
}
else {
-#ifdef MGTGEOM_DEB
+#ifdef OCCT_DEBUG
cout << "MgtGeom : Unknown surface type ????"<<endl;
#endif
Standard_NullObject::Raise("No mapping for the current Transient Surface");
return MgtGeom2d::Translate(TOffsetCurve);
}
else {
-#ifdef MGTGEOM2D_DEB
+#ifdef OCCT_DEBUG
cout << "Unknown Geom2d curve type ???? " << endl;
#endif
Standard_NullObject::Raise("No mapping for the current Persistent Curve");
return MgtGeom2d::Translate(POffsetCurve);
}
else {
-#ifdef MGTGEOM2D_DEB
+#ifdef OCCT_DEBUG
cout << "Unknown Geom2d curve type ???? " << endl;
#endif
Standard_NullObject::Raise("No mapping for the current Transient Curve");
if (aHShape->TShape().IsNull()) return;
// Translate the top-level shape
-#ifndef DEB // Linux porting - to avoid warnings
+#ifndef OCCT_DEBUG // Linux porting - to avoid warnings
if ( aMap.IsBound(aHShape->TShape()) ) {
#else
Standard_Boolean translated = aMap.IsBound(aHShape->TShape());
// count the number of <sub-shape> of the Shape's TShape
// Is there any sub-shape
if (!aHShape->TShape()->Shapes().IsNull()) {
-#ifndef DEB // Linux porting - to avoid warnings
+#ifndef OCCT_DEBUG // Linux porting - to avoid warnings
for (Standard_Integer i = 1 ; i<= aHShape->TShape()->Shapes()->Length(); i++) {
#else
Standard_Integer nbElem = aHShape->TShape()->Shapes()->Length();
}
void* anAddress = aBlock->Allocate(aSize);
-#ifdef DEB_FINDBLOCK
+#ifdef OCCT_DEBUG_FINDBLOCK
Key aKey;
Standard_ASSERT_VOID(aBlock == findBlock(anAddress, aKey),
"improper work of NCollection_AccAllocator::findBlock");
mypLastBlock,
0};
mypLastBlock = myBlocks.Bound(getKey(anAddress), aBlock);
-#ifdef DEB_FINDBLOCK
+#ifdef OCCT_DEBUG_FINDBLOCK
Key aKey;
Standard_ASSERT_VOID(mypLastBlock == findBlock((Standard_Byte*)aBlock.allocStart-1, aKey),
"improper work of NCollection_AccAllocator::findBlock");
#define IMEM_FREE(p_bl) (size_t(p_bl->p_end_block - p_bl->p_free_space))
-#ifdef DEB
+#ifdef OCCT_DEBUG
// auxiliary dummy function used to get a place where break point can be set
inline void place_for_breakpoint() {}
#endif
IS_DEBUG = theDebug;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
//=======================================================================
/**
aMutex.Unlock();
}
-#endif /* DEB */
+#endif /* OCCT_DEBUG */
//=======================================================================
//function : IncAllocator_PrintAlive
#ifdef ALLOC_TRACK_USAGE
printf ("\n..NCollection_IncAllocator: Created (%x)\n",this);
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (IS_DEBUG)
Debug_Create(this);
#endif
NCollection_IncAllocator::~NCollection_IncAllocator ()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (IS_DEBUG)
Debug_Destroy(this);
#endif
~NCollection_UBTreeFiller ()
{
if (mySeqPtr.Length() > 0)
-#ifdef DEB_UBTREE
+#ifdef OCCT_DEBUG_UBTREE
cout << "~NCollection_UBTreeFiller: " << Fill()
<< " objects added to the tree" << endl;
#else
const NIS_DrawList&)
{
// Assertion for the type of the drawn object
-#ifdef _DEBUG
- static const Handle(Standard_Type) ThisType = STANDARD_TYPE(NIS_Surface);
- Standard_ProgramError_Raise_if (theObj->IsKind(ThisType) == Standard_False,
+ Standard_ProgramError_Raise_if (! theObj->IsKind(STANDARD_TYPE(NIS_Surface)),
"NIS_Surface::Draw: irrelevant object type");
-#endif
+
const NIS_Surface * pObject =
static_cast <const NIS_Surface *> (theObj.operator->());
glVertexPointer (3, GL_FLOAT, 0, pObject->Node(0));
#include <NIS_TriangulatedDrawer.hxx>
#include <NIS_InteractiveObject.hxx>
#include <NIS_Triangulated.hxx>
-#ifdef _DEBUG
#include <Standard_ProgramError.hxx>
-#endif
#include <OpenGl_GlCore11.hxx>
const NIS_DrawList&)
{
// Assertion for the type of the drawn object
-#ifdef _DEBUG
- static const Handle(Standard_Type) ThisType = STANDARD_TYPE(NIS_Triangulated);
- if (theObj->IsKind(ThisType) == Standard_False)
- Standard_ProgramError::Raise ("NIS_Triangulated::Draw: "
- "irrelevant object type");
-#endif
+ Standard_ProgramError_Raise_if (! theObj->IsKind(STANDARD_TYPE(NIS_Triangulated)),
+ "NIS_Triangulated::Draw: irrelevant object type");
+
const NIS_Triangulated * pObject =
static_cast <const NIS_Triangulated *> (theObj.operator->());
glVertexPointer (pObject->myNodeCoord, GL_FLOAT, 0, pObject->Node(0));
// you may divide by infinity
//
if (! finite(theDivisor)) return Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer aExp1, aExp2;
// Standard_Real aMant1 = frexp(theDividend, &aExp1);
// Standard_Real aMant2 = frexp(theDivisor, &aExp2);
) {
if ( OSD_File::KindOfFile ( ) == OSD_DIRECTORY ) {
-#ifdef OSD_DEB
+#ifdef OCCT_DEBUG
cout << " OSD_File::Read : it is a directory " << endl;
#endif
return ;
sprintf(full_name,"%s/%s",myPlace.ToCString(),
((struct dirent *)myEntry)->d_name); // LD debug
-#ifdef OSD_DEB
+#ifdef OCCT_DEBUG
cout << "Place : " << myPlace << endl;
cout << "FName : " << full_name << endl;
#endif
myPath.SystemName ( aBuffer );
status = copy_file(aBuffer.ToCString(), second_name.ToCString());
if (status != 0) myError.SetValue (-1, Iam, "Copy failed") ;// (LD)
-#ifdef DEBUG
+#ifdef OCCT_DEBUG
printf("Status %d : errno # %d\n",status,errno);
#endif
}
MacExtract(aDependentName,myDisk,myTrek,myName,myExtension);
break;
default:
-#ifdef OSD_DEB
+#ifdef OCCT_DEBUG
cout << " WARNING WARNING : OSD Path for an Unknown SYSTEM : " << (Standard_Integer)todo << endl;
#endif
break ;
if (aCurInfoHandle) {
// cout << "OSD::Handler: calling previous signal handler with info " << aCurInfoHandle << endl ;
(*aCurInfoHandle) (theSignal, aSigInfo, theContext);
-#ifdef OSD_DEB
+#ifdef OCCT_DEBUG
cerr << " previous signal handler return" << endl ;
#endif
return;
if(aCurHandler) {
// cout << "OSD::Handler: calling previous signal handler" << endl ;
(*aCurHandler) (theSignal);
-#ifdef OSD_DEB
+#ifdef OCCT_DEBUG
cerr << " previous signal handler return" << endl ;
#endif
return;
sigprocmask(SIG_UNBLOCK, &set, NULL) ;
#ifdef DECOSF1
// Pour DEC/OSF1 SIGFPE = Division par zero.
- // should be clarified why in debug mode only?
-#ifdef DEBUG
Standard_DivideByZero::NewInstance('')->Jump;
-#endif
break;
#endif
#if (!defined (__sun)) && (!defined(SOLARIS))
Standard_DivideByZero::NewInstance("SIGTRAP IntegerDivideByZero")->Jump(); break;
#endif
default:
-#ifdef OSD_DEB
+#ifdef OCCT_DEBUG
cout << "Unexpected signal " << theSignal << endl ;
#endif
break;
OSD_SIGSEGV::NewInstance(Msg)->Jump();
}
}
-#ifdef OSD_DEB
+#ifdef OCCT_DEBUG
else {
cout << "Wrong undefined address." << endl ;
}
// scp->sc_pcoq_tail = scp->sc_pcoq_tail + 0x4 ; l'intruction suivant le segv.
}
}
-#ifdef OSD_DEB
+#ifdef OCCT_DEBUG
else {
cout << "Wrong undefined address." << endl ;
}
//stat = ieee_handler("set", "inexact", PHandler) || stat;
if (stat) {
-#ifdef OSD_DEB
+#ifdef OCCT_DEBUG
cerr << "ieee_handler does not work !!! KO " << endl;
#endif
}
if ( first_time & 2 ) {
char *TRAP_FPE = getenv("TRAP_FPE") ;
if ( TRAP_FPE == NULL ) {
-#ifdef OSD_DEB
+#ifdef OCCT_DEBUG
cout << "On SGI you must set TRAP_FPE environment variable : " << endl ;
cout << "set env(TRAP_FPE) \"UNDERFL=FLUSH_ZERO;OVERFL=DEFAULT;DIVZERO=DEFAULT;INT_OVERFL=DEFAULT\" or" << endl ;
cout << "setenv TRAP_FPE \"UNDERFL=FLUSH_ZERO;OVERFL=DEFAULT;DIVZERO=DEFAULT;INT_OVERFL=DEFAULT\"" << endl ;
//==== Always detected the signal "SIGFPE" =================================
stat = sigaction(SIGFPE,&act,&oact); // ...... floating point exception
if (stat) {
-#ifdef OSD_DEB
+#ifdef OCCT_DEBUG
cerr << "sigaction does not work !!! KO " << endl;
#endif
perror("sigaction ");
#endif
buffersNoSwap (Standard_False),
contextStereo (Standard_False),
-#ifdef DEB
+#ifdef OCCT_DEBUG
contextDebug (Standard_True),
#else
contextDebug (Standard_False),
{
if (theExtName == NULL)
{
-#ifdef OPENGL_DEB
+#ifdef OCCT_DEBUG
std::cerr << "CheckExtension called with NULL string!\n";
#endif
return Standard_False;
{
// setup default callback
arbDbg->glDebugMessageCallbackARB (debugCallbackWrap, this);
- #ifdef DEB
+ #ifdef OCCT_DEBUG
glEnable (GL_DEBUG_OUTPUT_SYNCHRONOUS_ARB);
#endif
}
}
}
}
-#ifdef OPENGL_DEB
+#ifdef OCCT_DEBUG
if( !status )
printf(" *** OpenGl_TelGetPolygonNormal.has found confused or aligned points\n");
#endif
d = vecnrmd( norm, d );
status = (d > 0.) ? 1 : 0;
}
-#ifdef OPENGL_DEB
+#ifdef OCCT_DEBUG
if( !status )
printf(" *** OpenGl_TelGetNormal.has found confused or aligned points\n");
#endif
char line[100];
IS >> line;
if (strcmp(line,"Poly_Triangulation")) {
-#ifdef POLY_DEB
+#ifdef OCCT_DEBUG
cout << "Not a Triangulation in the file" << endl;
#endif
return Handle(Poly_Triangulation)();
char line[100];
IS >> line;
if (strcmp(line,"Poly_Polygon3D")) {
-#ifdef POLY_DEB
+#ifdef OCCT_DEBUG
cout << "Not a Polygon3D in the file" << endl;
#endif
return Handle(Poly_Polygon3D)();
char line[100];
IS >> line;
if (strcmp(line,"Poly_Polygon2D")) {
-#ifdef POLY_DEB
+#ifdef OCCT_DEBUG
cout << "Not a Polygon2D in the file" << endl;
#endif
return Handle(Poly_Polygon2D)();
#include <gp_Dir.hxx>
#include <gp_Dir2d.hxx>
-#ifdef _DEBUG
+#ifdef OCCT_DEBUG
static Standard_Integer doDebug = 0;
#endif
Standard_Integer aInd = myMapLink.Add(theLink);
Link& aLink = const_cast<Link&>(myMapLink(aInd));
aLink.flags |= theLink.flags;
-#ifdef _DEBUG
+#ifdef OCCT_DEBUG
myHelper->OnAddLink (aInd, aLink);
#endif
}
aLink = theNewLink;
// and now put there the final value of link
myMapLink.Substitute(aInd, aLink);
-#ifdef _DEBUG
+#ifdef OCCT_DEBUG
myHelper->OnAddLink (aInd, aLink);
#endif
}
Link& aLink = const_cast<Link&>(myMapLink(aInd));
aOri = (LinkFlag) (aLink.flags & LF_Both);
aLink.flags = theOrient;
-#ifdef _DEBUG
+#ifdef OCCT_DEBUG
myHelper->OnAddLink (aInd, aLink);
#endif
}
myStartIndices.Add(-i);
}
-#ifdef _DEBUG
+#ifdef OCCT_DEBUG
if (doDebug)
showBoundaryBreaks();
#endif
aTempAlloc->Reset();
NCollection_IndexedMap<Standard_Integer> aContour (100, aTempAlloc);
Standard_Integer aStartNumber = findContour (aIndexS, aContour, aTempAlloc, aTempAlloc1);
-#ifdef _DEBUG
+#ifdef OCCT_DEBUG
if (aStartNumber > 1)
if (doDebug)
{
myStartIndices.Add(it.Key());
}
}
-#ifdef _DEBUG
+#ifdef OCCT_DEBUG
if (doDebug && nbLoopsOnPass2)
cout << "MakeLoops: " << nbLoopsOnPass2
<< " contours accepted on the second pass" << endl;
//purpose :
//=======================================================================
-#ifdef _DEBUG
+#ifdef OCCT_DEBUG
void Poly_MakeLoops::showBoundaryBreaks() const
{
// collect nodes of boundary links
aLink.Reverse();
return aLink;
}
-#ifdef _DEBUG
+#ifdef OCCT_DEBUG
void showBoundaryBreaks() const;
#endif
#define FuncTol 1.e-10
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
#include <OSD_Timer.hxx>
static OSD_Chronometer chr_init_point, chr_dicho_bound;
const Handle(Adaptor3d_HCurve)& Curve,
const Handle(Adaptor3d_HSurface)& Surface)
{
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
InitChron(chr_dicho_bound);
#endif
}
else aNotSol = t;
}
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
ResultChron(chr_dicho_bound,t_dicho_bound);
dicho_bound_count++;
#endif
if (!initpoint)
{
myCurve->D0(t,CPoint);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
InitChron(chr_init_point);
#endif
initpoint=InitialPoint(CPoint, t,myCurve,mySurface, myTolU, myTolV, U, V);
-#ifdef __OCC_DEBUG_CHRONO
+#ifdef OCCT_DEBUG_CHRONO
ResultChron(chr_init_point,t_init_point);
init_point_count++;
#endif
if(!ExactBound(Triple, t - Step, Tol,
myTolU, myTolV, myCurve, mySurface))
{
-#if PROJLIB_DEB
+#ifdef OCCT_DEBUG
cout<<"There is a problem with ExactBound computation"<<endl;
#endif
DichExactBound(Triple, t - Step, Tol, myTolU, myTolV,
if(!ExactBound(Triple, t, Tol, myTolU, myTolV,
myCurve, mySurface))
{
-#if PROJLIB_DEB
+#ifdef OCCT_DEBUG
cout<<"There is a problem with ExactBound computation"<<endl;
#endif
DichExactBound(Triple, t, Tol, myTolU, myTolV,
#ifdef DRAW
#include <DrawTrSurf.hxx>
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_Boolean AffichValue = Standard_False;
#endif
else {
ProjLib_Function F( C, S);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( AffichValue) {
Standard_Integer Nb = 20;
Standard_Real U1, U2, dU, U;
//#include <GeomLib_IsIso.hxx>
//#include <GeomLib_CheckSameParameter.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#ifdef DRAW
#include <DrawTrSurf.hxx>
#endif
//////////////////////////////////////////
Geom2dAdaptor_Curve GAC(myBSpline);
Handle(Adaptor2d_HCurve2d) IC2d = new Geom2dAdaptor_HCurve(GAC);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// char name [100];
// sprintf(name,"%s_%d","build",compteur++);
// DrawTrSurf::Set(name,myBSpline);
ProjLib_PolarFunction F(Curve, Surf, InitCurve2d, Tol3d) ; //OCC217
//ProjLib_PolarFunction F(Curve, Surf, InitCurve2d, myTolerance) ;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer Nb = 50;
Standard_Real U, U1, U2;
OK = OK && Dummy->RemoveKnot(ij,MaxDeg-1,Tol3d); //OCC217
//OK = OK && Dummy->RemoveKnot(ij,MaxDeg-1,myTolerance);
}
-#ifdef PROJLIB_DEB
+#ifdef OCCT_DEBUG
if (!OK) {
cout << "ProjLib_ComputeApproxOnPolarSurface : Smoothing echoue"<<endl;
}
}
catch (Standard_Failure)
{
- #ifdef DEB
+ #ifdef OCCT_DEBUG
const TopoDS_Face& aFace = aSurface.Face();
std::cout << "Problem with the face " << (void* ) &(*(aFace).TShape()) << std::endl;
#endif
}
catch (Standard_Failure)
{
- #ifdef DEB
+ #ifdef OCCT_DEBUG
const TopoDS_Face& aFace = aSurface.Face();
std::cout << "Problem with the face " << (void* ) &(*(aFace).TShape()) << std::endl;
#endif
}
catch (Standard_Failure)
{
- #ifdef DEB
+ #ifdef OCCT_DEBUG
std::cout << "probleme sur aLocation'edge " << (void* ) &(*(anEdge).TShape()) << std::endl;
#endif
}
}
catch (Standard_Failure)
{
- #ifdef DEB
+ #ifdef OCCT_DEBUG
std::cout << "probleme sur aLocation'edge " << (void* ) &(*(anEdge).TShape()) << std::endl;
#endif
}
}
catch (Standard_Failure)
{
- #ifdef DEB
+ #ifdef OCCT_DEBUG
std::cout << "probleme sur aLocation'edge " << (void* ) &(*(anEdge).TShape()) << std::endl;
#endif
}
#include <QANewBRepNaming_Loader.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TDataStd_Name.hxx>
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TCollection_AsciiString.hxx>
#include <TDF_Tool.hxx>
#include <BRepTools.hxx>
//=======================================================================
TDF_Label QANewBRepNaming_BooleanOperationFeat::ModifiedFaces() const {
-#ifdef DEB
+#ifdef OCCT_DEBUG
const TDF_Label& ModifiedFacesLabel = ResultLabel().NewChild();
TDataStd_Name::Set(ModifiedFacesLabel, "ModifiedFaces");
return ModifiedFacesLabel;
//=======================================================================
TDF_Label QANewBRepNaming_BooleanOperationFeat::ModifiedEdges() const {
-#ifdef DEB
+#ifdef OCCT_DEBUG
const TDF_Label& ModifiedEdgesLabel = ResultLabel().NewChild();
TDataStd_Name::Set(ModifiedEdgesLabel, "ModifiedEdges");
return ModifiedEdgesLabel;
//=======================================================================
TDF_Label QANewBRepNaming_BooleanOperationFeat::DeletedFaces() const {
-#ifdef DEB
+#ifdef OCCT_DEBUG
const TDF_Label& DeletedFacesLabel = ResultLabel().NewChild();
TDataStd_Name::Set(DeletedFacesLabel, "DeletedFaces");
return DeletedFacesLabel;
//=======================================================================
TDF_Label QANewBRepNaming_BooleanOperationFeat::DeletedEdges() const {
-#ifdef DEB
+#ifdef OCCT_DEBUG
const TDF_Label& DeletedEdgesLabel = ResultLabel().NewChild();
TDataStd_Name::Set(DeletedEdgesLabel, "DeletedEdges");
return DeletedEdgesLabel;
//=======================================================================
TDF_Label QANewBRepNaming_BooleanOperationFeat::DeletedVertices() const {
-#ifdef DEB
+#ifdef OCCT_DEBUG
const TDF_Label& DeletedVerticesLabel = ResultLabel().NewChild();
TDataStd_Name::Set(DeletedVerticesLabel, "DeletedVertices");
return DeletedVerticesLabel;
//=======================================================================
TDF_Label QANewBRepNaming_BooleanOperationFeat::NewShapes() const {
-#ifdef DEB
+#ifdef OCCT_DEBUG
const TDF_Label& NewShapesLabel = ResultLabel().NewChild();
TDataStd_Name::Set(NewShapesLabel, "NewShapes");
return NewShapesLabel;
//=======================================================================
TDF_Label QANewBRepNaming_BooleanOperationFeat::Content() const {
-#ifdef DEB
+#ifdef OCCT_DEBUG
const TDF_Label& ContentLabel = ResultLabel().NewChild();
TDataStd_Name::Set(ContentLabel, "Content");
return ContentLabel;
//=======================================================================
TDF_Label QANewBRepNaming_BooleanOperationFeat::DeletedDegeneratedEdges() const {
-#ifdef DEB
+#ifdef OCCT_DEBUG
const TDF_Label& DegeneratedLabel = ResultLabel().NewChild();
TDataStd_Name::Set(DegeneratedLabel, "DeletedDegeneratedEdges");
return DegeneratedLabel;
if (MS.IsDeleted(allEdges.FindKey(i))) {
TNaming_Builder DegeneratedBuilder(DeletedDegeneratedEdges());
DegeneratedBuilder.Generated(allEdges.FindKey(i));
-#ifdef DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(DegeneratedBuilder.NamedShape()->Label(), "DeletedDegenerated");
#endif
}
if (aBasisCurve->GetType() == GeomAbs_Circle || aBasisCurve->GetType() == GeomAbs_Ellipse)
return Standard_True;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
ModDbgTools_Write(theFace, "Surf");
#endif
return Standard_False;
gp_Pnt aPoint = aGProp.CentreOfMass();
gp_Vec aV1(theAx.Direction());
gp_Vec aV2(theAx.Location(), aPoint);
-#ifdef QANEWBREPNAMING_DEB
+#ifdef OCCT_DEBUG
gp_Vec v1 = aV1.Crossed(aV2);
cout <<" Z of V1 = " << v1.XYZ().Z() << endl;
#endif
const TopoDS_Shape& newShape = ShapesIterator.Value ();
if (!Root.IsSame (newShape)) {
//put shapes with evolution 1:1 (may be Compound)
-#ifdef QANEWBREPNAMING_DEB
+#ifdef OCCT_DEBUG
TCollection_AsciiString entry;
TDF_Tool::Entry(Builder.NamedShape()->Label(), entry);
cout << "Add shape to Compound at Label = "<< entry <<endl;
Standard_Boolean isPositive;
gp_Vec aVec1(theAx.Direction());
gp_Vec aVec2(thePnt1, thePnt2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// gp_Vec v1 = aVec1.Crossed(aVec2);
// cout <<" Z of V1 = " << v1.XYZ().Z() << endl;
#endif
if(!IsDirectionPositive(theAx, aCP2, theArP.Value(i3))) {//first must be positive direction
// change i3 <=> i4
-#ifdef QANEWBREPNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "SortEdges4: i3 = "<<i3<< "i4 = "<< i4 << endl;
#endif
Standard_Integer aN = i4; i4 = i3;
}
// 4. final order i1, i2, i3, i4 - Ok
-#ifdef QANEWBREPNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "SortEdges4: i1 = " <<i1<<" i2 = "<<i2<< " i3 = "<<i3<< "i4 = "<< i4 << endl;
#endif
theArI.SetValue(1, i1);
const TopoDS_Shape& aV22 = TopExp::LastVertex(TopoDS::Edge(theArS.Value(j)));
if(aV12.IsSame(aV21) || aV12.IsSame(aV22)) {
aV2 = aV12; J2 = j;
-#ifdef QANEWBREPNAMING_DEB
+#ifdef OCCT_DEBUG
if(I != i) cout << "WARNING:: I != i, I = " << I << ", i = " << i <<endl;
#endif
found = Standard_True;
}
for(i=1;i<=ArI.Upper();i++) {
-#ifdef QANEWBREPNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "SortEdges: i = " <<i<<" ArI.Value(i) = " <<ArI.Value(i)<< endl;
#endif
theARS.SetValue(i, ArS.Value(ArI.Value(i)));
const TopoDS_Shape& aShape = It.Value (); //1-st solid/shell
TopTools_ListOfShape aList;
aList.Clear();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// ModDbgTools_Write(aShape, "S0");
#endif
if(aShape.ShapeType() != TopAbs_FACE) {
const TDF_Label& WRE2Label = ResultLabel().NewChild();
const TDF_Label& WRV1Label = ResultLabel().NewChild();
const TDF_Label& WRV2Label = ResultLabel().NewChild();
-#ifdef DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(WRE1Label, "WorkAroundEdge1");
TDataStd_Name::Set(WRE2Label, "WorkAroundEdge2");
TDataStd_Name::Set(WRV1Label, "WorkAroundVertex1");
if (Type == QANewBRepNaming_SOLID) Builder.Generated (MS.Solid());
else if (Type == QANewBRepNaming_SHELL) Builder.Generated (MS.Shell());
else {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout<<"QANewBRepNaming_Box::Load(): Unexpected type of result"<<endl;
Builder.Generated (MS.Shape());
#endif
void QANewBRepNaming_Common::Load(BRepAlgoAPI_BooleanOperation& MS) const {
TopoDS_Shape ResSh = MS.Shape();
if (ResSh.IsNull()) {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout<<"QANewBRepNaming_Common::Load(): The result of the Common is null"<<endl;
#endif
return;
// If the shapes are the same - select the result and exit:
if (IsResultChanged(MS)) {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout<<"QANewBRepNaming_Common::Load(): The object and the result of COMMON operation are the same"<<endl;
#endif
if (ResType == TopAbs_COMPOUND) {
if( anArg == UNEXPECTED)
{
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout <<"QANewBRepNaming_Common:: Unexpected Use Case" << endl;
#endif
return;
}
}
else { //Solid
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
// cout <<"Solid case - modified = " << MS.HasModified()<< endl;
#endif
TNaming_Builder ModBuilder(ModifiedFaces());
const TopAbs_ShapeEnum& TypeSh = ShapeType(ObjSh);
if (ResSh.IsNull()) {
-#ifdef QANEWBREPNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"QANewBRepNaming_Cut::Load(): The result of the boolean operation is null"<<endl;
#endif
return;
// If the shapes are the same - select the result and exit:
if (IsResultChanged(MS)) {
-#ifdef QANEWBREPNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"QANewBRepNaming_Cut::Load(): The object and the result of CUT operation are the same"<<endl;
#endif
if (MS.Shape().ShapeType() == TopAbs_COMPOUND) {
#include <TNaming_Builder.hxx>
#include <Standard_NullObject.hxx>
#include <TopoDS_Solid.hxx>
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
#include <TDataStd_Name.hxx>
#endif
//=======================================================================
TDF_Label QANewBRepNaming_Cylinder::Bottom() const {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(ResultLabel().FindChild(1, Standard_True), "Bottom");
#endif
return ResultLabel().FindChild(1, Standard_True);
//=======================================================================
TDF_Label QANewBRepNaming_Cylinder::Top() const {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(ResultLabel().FindChild(2, Standard_True), "Top");
#endif
return ResultLabel().FindChild(2, Standard_True);
//=======================================================================
TDF_Label QANewBRepNaming_Cylinder::Lateral() const {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(ResultLabel().FindChild(3, Standard_True), "Lateral");
#endif
return ResultLabel().FindChild(3, Standard_True);
//=======================================================================
TDF_Label QANewBRepNaming_Cylinder::StartSide() const {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(ResultLabel().FindChild(4, Standard_True), "StartSide");
#endif
return ResultLabel().FindChild(4, Standard_True);
//=======================================================================
TDF_Label QANewBRepNaming_Cylinder::EndSide() const {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(ResultLabel().FindChild(5, Standard_True), "EndSide");
#endif
return ResultLabel().FindChild(5, Standard_True);
if (Type == QANewBRepNaming_SOLID) Builder.Generated (mkCylinder.Solid());
else if (Type == QANewBRepNaming_SHELL) Builder.Generated (mkCylinder.Shell());
else {
-#ifdef QANEWBREPNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"QANewBRepNaming_Cylinder::Load(): Unexpected type of result"<<endl;
Builder.Generated (mkCylinder.Shape());
#endif
gp_Vec aMainVec(P1, P2);
gp_Vec aV1(P1, EP1);
gp_Vec aV2(P1, EP2);
-#ifdef QANEWBREPNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "P1=" << P1.X() << " " << P1.Y() << " " << P1.Z() << endl;
cout << "P2=" << P2.X() << " " << P2.Y() << " " << P2.Z() << endl;
cout << "EP1=" << EP1.X() << " " << EP1.Y() << " " << EP1.Z() << endl;
const TopoDS_Shape& ToolSh = MS.Shape2();
if (ResSh.IsNull()) {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout<<"QANewBRepNaming_Fuse::Load(): The result of the boolean operation is null"<<endl;
#endif
return;
#include <QANewModTopOpe_Glue.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TDataStd_Name.hxx>
#endif
const TopoDS_Shape& anObjShape = theMkGluing.Shape1();
if (aResShape.IsNull()) {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout<<"QANewBRepNaming_Gluing::Load(): The result of the Gluing operation is null"<<endl;
#endif
return;
}
// If the shapes are the same - select the result and exit:
if (IsResultChanged(theMkGluing)) {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout<<"QANewBRepNaming_Gluing::Load(): The object and the result of the operation are the same"<<endl;
#endif
if (aResShape.ShapeType() == TopAbs_COMPOUND) {
void QANewBRepNaming_Gluing::LoadModifiedShapes(QANewModTopOpe_Glue& theMkGluing) const {
const Standard_Integer aNumTypes = 1;
const TopAbs_ShapeEnum aTypes[] = {TopAbs_FACE/*,TopAbs_EDGE,TopAbs_VERTEX*/};
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
const char aNames[][20] = {"ModifiedFaces"/*,"ModifiedEdges","ModifiedVertexes"*/};
#endif
Standard_Integer aShapeNum;
aLabel = aLabel.Father().FindChild(aLabel.Tag()+1,Standard_True);
}
for(Standard_Integer a=0;a<aNumTypes;a++) { // argument-shapes types cycle
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(aLabel,TCollection_ExtendedString(Standard_CString(aNames[a])));
#endif
TNaming_Builder aBuilder(aLabel);
aNext--;
}
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout<<"QANewBRepNaming_Gluing::RecomputeUnique found "<<myUnique.Extent()<<" shapes"<<endl;
#endif
}
//purpose :
//=======================================================================
void QANewBRepNaming_Gluing::LoadSourceShapes(TopTools_DataMapOfShapeInteger& theSources) const {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout<<"********** QANewBRepNaming_Gluing::LoadSourceShapes the valid map:"<<endl;
TDF_MapIteratorOfLabelMap anIter(myLog);
for(;anIter.More();anIter.Next()) {
aShapes.Remove(aShape);
TNaming_Selector aSelector(aLabel);
if (!aSelector.Select(aShape,myContext)) {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout<<"Can't do naming"<<endl;
#endif
}
//purpose :
//=======================================================================
TDF_Label QANewBRepNaming_Gluing::Content() const {
-#ifdef DEB
+#ifdef OCCT_DEBUG
const TDF_Label& ContentLabel = ResultLabel().NewChild();
TDataStd_Name::Set(ContentLabel, "Content");
return ContentLabel;
#include <TopOpeBRepBuild_HBuilder.hxx>
#include <TopoDS_Iterator.hxx>
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
#include <TDataStd_Name.hxx>
#include <TNaming_NamedShape.hxx>
#endif
void QANewBRepNaming_Intersection::Load(BRepAlgoAPI_BooleanOperation& MS) const {
TopoDS_Shape ResSh = MS.Shape();
if (ResSh.IsNull()) {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout<<"QANewBRepNaming_Intersection::Load(): The result of the Intersection is null"<<endl;
#endif
return;
// If the shapes are the same - select the result and exit:
if (IsResultChanged(MS)) {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout<<"QANewBRepNaming_Intersection::Load(): The object and the result of INTERSECTION operation are the same"<<endl;
// Not modified!
#endif
}
if(anArg == UNEXPECTED) {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout <<"QANewBRepNaming_Intersection:: Unexpected Use Case" << endl;
#endif
return;
const TopAbs_ShapeEnum& ObjType = ShapeType(ObjSh);
if (ResSh.IsNull()) {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout<<"QANewBRepNaming_Limitation::Load(): The result of the boolean operation is null"<<endl;
#endif
return;
}
if(MS.Shape1().IsSame(ResSh)) {
// If the shapes are the same - select the result and exit:
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout<<"QANewBRepNaming_Limitation::Load(): The object and the result of LIMITATION operation are the same"<<endl;
#endif
TNaming_Builder aBuilder(ResultLabel());
if (MS.IsDeleted(allEdges.FindKey(i))) {
TNaming_Builder DegeneratedBuilder(DeletedDegeneratedEdges());
DegeneratedBuilder.Generated(allEdges.FindKey(i));
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(DegeneratedBuilder.NamedShape()->Label(), "DeletedDegenerated");
#endif
}
const TopoDS_Shape& aDangle = itr.Key();
if (ignored.Contains(aDangle)) continue;
TNaming_Builder aBuilder(theLabelGenerator.NewChild());
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(aBuilder.NamedShape()->Label(), "NewShapes");
#endif
aBuilder.Generated(aDangle);
#include <BRep_Tool.hxx>
#include <TopoDS.hxx>
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
#include <TDataStd_Name.hxx>
#endif
TDF_Label QANewBRepNaming_Prism::Bottom() const {
const TDF_Label& L = ResultLabel().NewChild();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(L, "Bottom");
#endif
return L;
TDF_Label QANewBRepNaming_Prism::Top() const {
const TDF_Label& L = ResultLabel().NewChild();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(L, "Top");
#endif
return L;
TDF_Label QANewBRepNaming_Prism::Lateral() const {
const TDF_Label& L = ResultLabel().NewChild();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(L, "Lateral");
#endif
return L;
TDF_Label QANewBRepNaming_Prism::Degenerated() const {
const TDF_Label& L = ResultLabel().NewChild();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(L, "Degenerated");
#endif
return L;
TDF_Label QANewBRepNaming_Prism::Dangle() const {
const TDF_Label& L = ResultLabel().NewChild();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(L, "Dangle");
#endif
return L;
TDF_Label QANewBRepNaming_Prism::Content() const {
const TDF_Label& L = ResultLabel().NewChild();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(L, "Content");
#endif
return L;
#include <BRep_Tool.hxx>
#include <TDF_Label.hxx>
+#include <TDataStd_Name.hxx>
#include <Standard_NullObject.hxx>
TDF_Label QANewBRepNaming_Revol::Degenerated() const {
//const TDF_Label& L = ResultLabel().NewChild();
const TDF_Label& L = ResultLabel().FindChild(4, Standard_True);
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(L, "Degenerated");
#endif
return L;
TDF_Label QANewBRepNaming_Revol::Content() const {
//const TDF_Label& L = ResultLabel().NewChild();
const TDF_Label& L = ResultLabel().FindChild(5, Standard_True);
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(L, "Content");
#endif
return L;
#include <BRep_Tool.hxx>
#include <TNaming_NamedShape.hxx>
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
#include <TDataStd_Name.hxx>
#endif
TDF_Label QANewBRepNaming_Sphere::Bottom() const {
const TDF_Label& BottomL = ResultLabel().NewChild();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(BottomL, "Bottom");
#endif
return BottomL;
TDF_Label QANewBRepNaming_Sphere::Top() const {
const TDF_Label& TopL = ResultLabel().NewChild();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(TopL, "Top");
#endif
return TopL;
TDF_Label QANewBRepNaming_Sphere::Lateral() const {
const TDF_Label& LateralL = ResultLabel().NewChild();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(LateralL, "Lateral");
#endif
return LateralL;
TDF_Label QANewBRepNaming_Sphere::StartSide() const {
const TDF_Label& StartSideL = ResultLabel().NewChild();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(StartSideL, "StartSide");
#endif
return StartSideL;
TDF_Label QANewBRepNaming_Sphere::EndSide() const {
const TDF_Label& EndSideL = ResultLabel().NewChild();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(EndSideL, "EndSide");
#endif
return EndSideL;
TDF_Label QANewBRepNaming_Sphere::Meridian() const {
const TDF_Label& MeridianL = ResultLabel().NewChild();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(MeridianL, "Meridian");
#endif
return MeridianL;
TDF_Label QANewBRepNaming_Sphere::Degenerated() const {
const TDF_Label& DegeneratedL = ResultLabel().NewChild();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TDataStd_Name::Set(DegeneratedL, "Degenerated");
#endif
return DegeneratedL;
if (Type == QANewBRepNaming_SOLID) Builder.Generated (mkSphere.Solid());
else if (Type == QANewBRepNaming_SHELL) Builder.Generated (mkSphere.Shell());
else {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout<<"QANewBRepNaming_Sphere::Load(): Unexpected type of result"<<endl;
Builder.Generated (mkSphere.Shape());
#endif
myMapGener(theFace).Append (aListGener);
}
}
-#ifdef QANEWODTOPOPE_DEB
+#ifdef OCCT_DEBUG
else if (!aListW.IsEmpty()) {
cout<<"QANewModTopOpe_Glue::SectionInsideFace : can't connect edges"<<endl;
}
}
// --- External Mapping Case Recognition ---
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer RWHeaderSection_ReadWriteModule::CaseStep (const TColStd_SequenceOfAsciiString& types) const
{
Standard_Integer NbComp = types.Length();
Standard_Integer NbComp = theTypes.Length();
if (NbComp < 2) {
-#ifdef RWSTEPAP214_DEB
+#ifdef OCCT_DEBUG
cout << "Not a Plex" << endl;
#endif
}
const Handle(Standard_Transient)&ent) const
{
if (CN == 0) {
-#ifdef RWSTEPAP214_DEB
+#ifdef OCCT_DEBUG
cout << "CN = 0 for num = " << num << endl;
#endif
return;
Standard_Boolean sharOE1 = aShto.IsShared(theOE1);
if(!sharOE1){
-#ifdef RWSTEPSHAPE_DEB
+#ifdef OCCT_DEBUG
cout << "OrientedEdge1 not shared" <<endl;
#endif
}
Handle(StepShape_EdgeLoop)::DownCast(myShRef.Value());
Standard_Boolean sharEL1 = aShto.IsShared(theEL1);
if(!sharEL1) {
-#ifdef RWSTEPSHAPE_DEB
+#ifdef OCCT_DEBUG
cout << "EdgeLoop1 not shared" <<endl;
#endif
}
else {
myShRef = aShto.Sharings(theEL1);
myShRef.SelectType (STANDARD_TYPE(StepShape_FaceBound),Standard_True);
-#ifdef DEB
+#ifdef OCCT_DEBUG
nbRef =
#endif
myShRef.NbEntities();
theFBOri1 = theFOB1->Orientation();
}
else {
-#ifdef RWSTEPSHAPE_DEB
+#ifdef OCCT_DEBUG
cout << "EdgeLoop not referenced by FaceBound" << endl;
#endif
}
}
else {
if (nbRef == 0) {
-#ifdef RWSTEPSHAPE_DEB
+#ifdef OCCT_DEBUG
cout << "OrientedEdge not referenced" << endl;
#endif
}
else {
if (aShto.NbTypedSharings(theOE1,
STANDARD_TYPE(StepShape_EdgeLoop)) > 1) {
-#ifdef RWSTEPSHAPE_DEB
+#ifdef OCCT_DEBUG
cout << "OrientedEdge referenced more than once" << endl;
#endif
}
Standard_Boolean sharOE2 = aShto.IsShared(theOE2);
if(!sharOE2){
-#ifdef RWSTEPSHAPE_DEB
+#ifdef OCCT_DEBUG
cout << "OrientedEdge2 not shared" <<endl;
#endif
}
else {
myShRef = aShto.Sharings(theOE2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nbRef =
#endif
// unused myShRef.NbEntities();
Handle(StepShape_EdgeLoop)::DownCast(myShRef.Value());
Standard_Boolean sharEL2 = aShto.IsShared(theEL2);
if(!sharEL2){
-#ifdef RWSTEPSHAPE_DEB
+#ifdef OCCT_DEBUG
cout << "EdgeLoop2 not shared" <<endl;
#endif
}
theFBOri2 = theFOB2->Orientation();
}
else {
-#ifdef RWSTEPSHAPE_DEB
+#ifdef OCCT_DEBUG
cout << "EdgeLoop not referenced by FaceBound" << endl;
#endif
}
Standard_Boolean sharOE2 = aShto.IsShared(theOE2);
if(!sharOE2){
-#ifdef RWSTEPSHAPE_DEB
+#ifdef OCCT_DEBUG
cout << "OrientedEdge2 not shared" <<endl;
#endif
}
Handle(StepShape_EdgeLoop)::DownCast(myShRef.Value());
Standard_Boolean sharEL2 = aShto.IsShared(theEL2);
if(!sharEL2){
-#ifdef RWSTEPSHAPE_DEB
+#ifdef OCCT_DEBUG
cout << "EdgeLoop2 not shared" <<endl;
#endif
}
theFBOri2 = theFB2->Orientation();
}
else {
-#ifdef RWSTEPSHAPE_DEB
+#ifdef OCCT_DEBUG
cout << "EdgeLoop not referenced by FaceBound" << endl;
#endif
}
} //end for(i=1; i<=nbEdg; ...)
} //end if(!theEL1.IsNull)
else {
-#ifdef RWSTEPSHAPE_DEB
+#ifdef OCCT_DEBUG
cout << "no EdgeLoop in FaceBound" << endl;
#endif
}
IsAscii = Standard_False;
}
}
-#ifdef RWSTL_DEB
+#ifdef OCCT_DEBUG
cout << (IsAscii ? "ascii\n" : "binary\n");
#endif
file.Close();
// skip header
while (getc(file) != '\n');
-#ifdef RWSTL_DEB
+#ifdef OCCT_DEBUG
cout << "start mesh\n";
#endif
ReadMesh = new StlMesh_Mesh();
if (++iTri % IND_THRESHOLD == 0)
aPS.Next();
}
-#ifdef RWSTL_DEB
+#ifdef OCCT_DEBUG
cout << "end mesh\n";
#endif
fclose(file);
#include <StepShape_HArray1OfOrientedEdge.hxx>
#include <StepShape_HArray1OfShell.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
//! Converts address of the passed shape (TShape) to string.
//! \param theShape [in] Shape to dump.
//! \return corresponding string.
static Handle(TCollection_HAsciiString) ap214 = new TCollection_HAsciiString ( "STEP AP214" );
if ( ! format->IsSameString ( ap203, Standard_False ) &&
! format->IsSameString ( ap214, Standard_False ) ) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: STEPCAFControl_Reader::Transfer: Extern document is neither STEP AP203 nor AP214" << endl;
#else
continue;
#endif
}
}
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
else cout << "Warning: STEPCAFControl_Reader::Transfer: Extern document format not defined" << endl;
#endif
// get and check filename of the current extern ref
const Standard_CString filename = ExtRefs.FileName(i);
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout<<"filename="<<filename<<endl;
#endif
if ( ! filename || ! filename[0] ) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: STEPCAFControl_Reader::Transfer: Extern reference file name is empty" << endl;
#endif
continue; // not a valid extern ref
return EF->GetLabel();
}
}
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
if ( ! EF->GetLabel().IsNull() )
cout << "Warning: STEPCAFControl_Reader::AddShape: Non-empty shape with external ref; ref is ignored" << endl;
else if ( nbComponents <=0 )
return myFiles->Item ( file );
}
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Reading extern file: " << fullname << endl;
#endif
{
STEPConstruct_Styles Styles ( WS );
if ( ! Styles.LoadStyles() ) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: no styles are found in the model" << endl;
#endif
return Standard_False;
Handle(Transfer_TransientProcess) TP = Tool.TransientProcess();
Handle(Transfer_Binder) binder = TP->Find(NAUO);
if ( binder.IsNull() || ! binder->HasResult() ) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Error: STEPCAFControl_Reader::FindInstance: NAUO is not mapped to shape" << endl;
#endif
return L;
TopoDS_Shape S = TransferBRep::ShapeResult ( TP, binder );
if ( S.IsNull() ) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Error: STEPCAFControl_Reader::FindInstance: NAUO is not mapped to shape" << endl;
#endif
return L;
TColStd_SequenceOfTransient props;
STEPConstruct_ValidationProps Props ( WS );
if ( ! Props.LoadProps ( props ) ) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: no validation props found in the model" << endl;
#endif
return Standard_False;
Interface_EntityIterator subs = WS->Graph().Sharings(SVPLA);
for (subs.Start(); subs.More(); subs.Next()) {
if ( ! subs.Value()->IsKind(STANDARD_TYPE(StepVisual_Invisibility)) ) continue;
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout<< "\tLayer \"" << aLayerName << "\" is invisible"<<endl;
#endif
//TDF_Label InvLayerLab = LTool->FindLayer(aLayerName);
Handle(StepRepr_NextAssemblyUsageOccurrence) NUNAUO =
Handle(StepRepr_NextAssemblyUsageOccurrence)::DownCast(SHUO->NextUsage());
if ( UUNAUO.IsNull() || NUNAUO.IsNull() ) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: " << __FILE__ <<": Upper_usage or Next_usage of styled SHUO is null. Skip it" << endl;
#endif
return aMainLabel;
STEPConstruct_Styles Styles ( WS );
if ( ! Styles.LoadStyles() ) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: no styles are found in the model" << endl;
#endif
return Standard_False;
if ( style != aHSeqOfInvisStyle->Value( si ) )
continue;
// found that current style is invisible.
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: item No " << i << "(" << style->Item()->DynamicType()->Name() << ") is invisible" << endl;
#endif
IsVisible = Standard_False;
// set the SHUO structure to the document
TDF_Label aLabelForStyle = setSHUOintoDoc( WS, SHUO, STool, PDFileMap, ShapeLabelMap );
if ( aLabelForStyle.IsNull() ) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: " << __FILE__ <<": coudnot create SHUO structure in the document" << endl;
#endif
continue;
// construct extern file name
TCollection_AsciiString fname = OSD_Path::AbsolutePath ( dpath, EF->GetName()->String() );
if ( fname.Length() <= 0 ) fname = EF->GetName()->String();
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Writing external file: " << fname.ToCString() << endl;
#endif
Handle(StepShape_ShapeDefinitionRepresentation) SDR;
Handle(TransferBRep_ShapeMapper) mapper = TransferBRep::ShapeMapper ( FP, S );
if ( ! FP->FindTypedTransient ( mapper, STANDARD_TYPE(StepShape_ShapeDefinitionRepresentation), SDR ) ) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: Cannot find SDR for " << S.TShape()->DynamicType()->Name() << endl;
#endif
continue;
StepRepr_RepresentedDefinition RD = SDR->Definition();
Handle(StepRepr_PropertyDefinition) aPropDef = RD.PropertyDefinition();
if (aPropDef.IsNull()) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: STEPCAFControl_Writer::WriteExternRefs StepRepr_PropertyDefinition is null for " << S.TShape()->DynamicType()->Name() << endl;
#endif
continue;
StepRepr_CharacterizedDefinition CharDef = aPropDef->Definition();
Handle(StepBasic_ProductDefinition) PD = CharDef.ProductDefinition();
if (PD.IsNull()) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: STEPCAFControl_Writer::WriteExternRefs StepBasic_ProductDefinition is null for " << S.TShape()->DynamicType()->Name() << endl;
#endif
continue;
TopLoc_Location L;
TColStd_SequenceOfTransient seqRI;
Standard_Integer nb = FindEntities ( Styles.FinderProcess(), S, L, seqRI );
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
if ( nb <=0 ) cout << "Warning: Cannot find RI for " << S.TShape()->DynamicType()->Name() << endl;
#endif
//Get overridden style gka 10.06.03
// Skip assemblies: colors assigned to assemblies and their instances
// are not supported (it is not clear how to encode that in STEP)
if ( XCAFDoc_ShapeTool::IsAssembly ( L ) ) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: Cannot write color for Assembly" << endl;
cout << "Info: Check for colors assigned to components in assembly" << endl;
#endif
if (!isComponent) {
if ( myMapCompMDGPR.IsBound( aTopSh )) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cerr << "Error: Current Top-Level shape have MDGPR already " << endl;
#endif
}
Handle(StepShape_ShapeDefinitionRepresentation) SDR;
Handle(TransferBRep_ShapeMapper) mapper = TransferBRep::ShapeMapper ( FP, S );
if ( ! FP->FindTypedTransient ( mapper, STANDARD_TYPE(StepShape_ShapeDefinitionRepresentation), SDR ) ) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: Cannot find SDR for " << S.TShape()->DynamicType()->Name() << endl;
#endif
continue;
Standard_Boolean isLinv = Standard_False;
if (L.FindAttribute(XCAFDoc::InvisibleGUID(), aUAttr)) {
descr = new TCollection_HAsciiString ("invisible");
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
FP->Messenger() << "\tLayer \"" << hName->String().ToCString() << "\" is invisible"<<endl;
#endif
isLinv = Standard_True;
// Handle(XCAFDoc_GraphNode) NuSHUO;
if ( aNextUsageLabs.Length() > 0) {
// store SHUO recursive
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
if ( aNextUsageLabs.Length() > 1 )
cout << "Warning: store only one next_usage of current SHUO" << endl;
#endif
Handle(StepRepr_NextAssemblyUsageOccurrence) UUNAUO, NUNAUO;
if (!getProDefinitionOfNAUO( WS, aUUSh, nullPD, UUNAUO, Standard_True ) ||
!getProDefinitionOfNAUO( WS, aNUSh, aRelatedPD, NUNAUO, Standard_False )) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: cannot get related or relating PD" << endl;
#endif
return Standard_False;
TopLoc_Location L;
TColStd_SequenceOfTransient seqRI;
FindEntities ( FP, Sh, L, seqRI );
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
if ( seqRI.Length() <=0 )
FP->Messenger() << "Warning: Cannot find RI for " << Sh.TShape()->DynamicType()->Name() << endl;
#endif
// do it by additing styled item to the MDGPR
if ( !aTopSh.IsNull() && !myMapCompMDGPR.IsBound( aTopSh ) ) {
// create MDGPR and record it in model
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: " << __FILE__ << ": Create new MDGPR for SHUO instance" << endl;
#endif
Handle(StepVisual_MechanicalDesignGeometricPresentationRepresentation) aMDGPR;
}
else {
WS->Model()->AddWithRefs ( STEPstyle ); // add as root to the model, but it is not good
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: " << __FILE__ << ": adds styled item of SHUO as root, casue cannot find MDGPR" << endl;
#endif
}
// check if it is styled SHUO
XCAFPrs_Style SHUOstyle;
if ( !getSHUOstyle ( aSHUOlab, CTool, SHUOstyle ) ) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: " << __FILE__ << ": do not store SHUO without any style to the STEP model" << endl;
#endif
continue;
// create the top SHUO and all other.
writeSHUO( aSHUO, CTool->ShapeTool(), WS, anEntOfSHUO, NAUOShape, aRelatingPD, isDeepest );
if ( anEntOfSHUO.IsNull() || NAUOShape.IsNull() ) {
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: " << __FILE__ << ": Cannot store SHUO" << endl;
#endif
continue;
}
// create new Product Definition Shape for TOP SHUO
-#ifdef STEPCAFCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Info: " << __FILE__ << ": Create NEW PDS for current SHUO " << endl;
#endif
Handle(StepRepr_ProductDefinitionShape) PDS = new StepRepr_ProductDefinitionShape;
#include <StepRepr_PropertyDefinition.hxx>
#include <StepRepr_ProductDefinitionShape.hxx>
-#ifdef DEBUG
-void DumpBinder (const Handle(Transfer_Binder) &binder)
-{
- Handle(Transfer_Binder) bbb = binder;
- while ( ! bbb.IsNull() ) {
- Handle(Transfer_SimpleBinderOfTransient) bx =
- Handle(Transfer_SimpleBinderOfTransient)::DownCast ( bbb );
- if ( ! bx.IsNull() ) {
- cout << "--> " << bx->ResultTypeName() << " " << *(void**)&bx->Result() << endl;
- }
- else cout << "--> ???" << endl;
- bbb = bbb->NextResult();
- }
- cout << endl;
-}
-#endif
-
//=======================================================================
//function : FindEntity
//purpose :
Handle(StepRepr_RepresentationItem) item;
Handle(TransferBRep_ShapeMapper) mapper = TransferBRep::ShapeMapper ( FinderProcess, Shape );
FinderProcess->FindTypedTransient (mapper,STANDARD_TYPE(StepRepr_RepresentationItem), item);
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
if ( item.IsNull() ) cout << Shape.TShape()->DynamicType()->Name() << ": RepItem not found" << endl;
else cout << Shape.TShape()->DynamicType()->Name() << ": RepItem found: " << item->DynamicType()->Name() << endl;
#endif
mapper = TransferBRep::ShapeMapper ( FinderProcess, S );
FinderProcess->FindTypedTransient (mapper,STANDARD_TYPE(StepRepr_RepresentationItem), item);
}
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
if ( item.IsNull() ) cout << Shape.TShape()->DynamicType()->Name() << ": RepItem not found" << endl;
else if ( Loc != Shape.Location() ) cout << Shape.TShape()->DynamicType()->Name() << ": RepItem found for shape without location: " << item->DynamicType()->Name() << endl;
else cout << Shape.TShape()->DynamicType()->Name() << ": RepItem found: " << item->DynamicType()->Name() << endl;
Handle(StepRepr_NextAssemblyUsageOccurrence)::DownCast
( CDSR->RepresentedProductRelation()->Definition().ProductDefinitionRelationship() );
if ( nauo.IsNull() ) {
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: No NAUO found in CDSR !" << endl;
#endif
return Standard_False;
return Standard_True;
}
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: SRR and NAUO are incompatible" << endl;
// cout << "NAUO = " << Model->StringLabel(nauo)->ToCString() <<
// ",\tCDSR = " << Model->StringLabel(CDSR)->ToCString() << endl;
Handle(TransferBRep_ShapeMapper) mapper = TransferBRep::ShapeMapper ( FinderProcess(), Shape );
Handle(StepShape_ShapeRepresentation) sr;
if ( FinderProcess()->FindTypedTransient (mapper,STANDARD_TYPE(StepShape_ShapeRepresentation), sr) ) {
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
// cout << "Context of " << Shape.TShape()->DynamicType()->Name() << ": SR found: " << sr->DynamicType()->Name() << endl;
#endif
Context = sr->ContextOfItems();
else {
Handle(StepGeom_GeometricRepresentationItem) item;
if ( FinderProcess()->FindTypedTransient (mapper,STANDARD_TYPE(StepGeom_GeometricRepresentationItem), item) ) {
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
// cout << "Context of " << Shape.TShape()->DynamicType()->Name() << ": GeomRepItem found: " << item->DynamicType()->Name() << endl;
#endif
Interface_EntityIterator subs = Graph().Sharings(item);
for (subs.Start(); Context.IsNull() && subs.More(); subs.Next()) {
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
// cout << "Parsing back refs: found " << subs.Value()->DynamicType()->Name() << endl;
#endif
if ( ! subs.Value()->IsKind(STANDARD_TYPE(StepShape_ShapeRepresentation)) ) continue;
}
}
}
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
if ( Context.IsNull() ) {
cout << Shape.TShape()->DynamicType()->Name() << ": Cannot find context" << endl;
}
}
if ( items.Length() <1 ) {
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Error: no color is supplied" << endl;
#endif
return PSA;
else if ( name.IsEqual ( "black" ) ) Col.SetValues ( Quantity_NOC_BLACK );
else if ( name.IsEqual ( "white" ) ) Col.SetValues ( Quantity_NOC_WHITE );
else {
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Error: color name \"" << name << "\" is not recognized" << endl;
#endif
return Standard_False;
lengthDone = planeAngleDone = solidAngleDone = Standard_False;
if (aContext.IsNull()) {
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout<<" -- STEPConstruct_UnitContext:ComputeFactor, Context undefined -> default"<<endl;
#endif
return 1;
for (Standard_Integer i = 1; i <= nbU; i++) {
Handle(StepBasic_NamedUnit) theNamedUnit = aContext->UnitsValue(i);
status = ComputeFactors(theNamedUnit);
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
if(status == -1)
cout << " -- STEPConstruct_UnitContext:ComputeFactor: Unit item no." << i << " is not recognized" << endl;
#endif
}
else {
status = 14;
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Error in the file : parameter double defined" << endl;
#endif
}
}
else {
status = 14;
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Error in the file : parameter double defined" << endl;
#endif
}
// Defining a type of unit
if(!parameterDone) {
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Unit Type not implemented" << endl;
#endif
return 0;
lengthDone = Standard_True;
else {
status = 14;
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Error in the file : LengthFactor double defined" << endl;
#endif
}
for (Standard_Integer un = 1 ; un <= nbUncertainty ; un ++) {
Handle(StepBasic_UncertaintyMeasureWithUnit) aUMWU = aContext->UncertaintyValue(un);
if (aUMWU.IsNull()) {
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout<<"BAD Uncertainty Measure with Units, n0."<<un<<endl;
#endif
continue;
}
}
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
if (hasUncertainty) cout << "UNCERTAINTY read as " << theUncertainty << endl;
#endif
return status;
Handle(TransferBRep_ShapeMapper) mapper = TransferBRep::ShapeMapper ( FinderProcess(), Shape );
Handle(Transfer_Binder) binder = FinderProcess()->Find ( mapper );
-#ifdef STEPCONSTRUCT_DEB
-// cout << "\n>========------" << endl;
-// cout << "Binders for " << Shape.TShape()->DynamicType()->Name() << " " << *(void**)&Shape.TShape() << ", Loc = " << *(void**)&Shape.Location() << endl;
-// cout << "mapper = " << *(void**)&mapper << ", binder = " << *(void**)&binder << endl;
-// DumpBinder ( binder );
-#endif
-
// if requested, try to find instance of assembly
if ( instance ) {
/*
target.SetValue ( CDSR->RepresentedProductRelation() );
Context = CDSR->RepresentationRelation()->Rep2()->ContextOfItems();
}
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
else cout << "INSTANCE: CDRS from NAUO NOT found" << endl;
#endif
}
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
else cout << "INSTANCE: NAUO NOT found" << endl;
#endif
*/
PDS = Handle(StepRepr_ProductDefinitionShape)::DownCast(subs1.Value());
}
target.SetValue ( PDS );
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
// cout << "COMPOUND: SDR found: " << sdr->DynamicType()->Name() << endl;
#endif
}
else {
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "COMPOUND: ProdDef NOT found" << endl;
#endif
Handle(StepShape_ShapeRepresentation) SR;
else {
Handle(StepGeom_GeometricRepresentationItem) item;
if ( FinderProcess()->FindTypedTransient (mapper,STANDARD_TYPE(StepGeom_GeometricRepresentationItem), item) ) {
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
// cout << Shape.TShape()->DynamicType()->Name() << ": GeomRepItem found: " << item->DynamicType()->Name() << endl;
#endif
// find PDS (GRI <- SR <- SDR -> PDS)
Handle(StepRepr_ProductDefinitionShape) PDS;
Interface_EntityIterator subs = Graph().Sharings(item);
for (subs.Start(); PDS.IsNull() && subs.More(); subs.Next()) {
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
// cout << "Parsing back refs: found " << subs.Value()->DynamicType()->Name() << endl;
#endif
if ( ! subs.Value()->IsKind(STANDARD_TYPE(StepShape_ShapeRepresentation)) ) continue;
if ( aspect.IsNull() ) {
// if ( ! FinderProcess()->FindTypedTransient (mapper,STANDARD_TYPE(StepRepr_ShapeAspect), aspect ) ||
// aspect->OfShape() != PDS )
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << Shape.TShape()->DynamicType()->Name() << ": SHAPE_ASPECT NOT found, creating" << endl;
#endif
// create aspect and all related data
}
// SHAPE_ASPECT found, but we also need context: FIND IT !!!!
else {
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << Shape.TShape()->DynamicType()->Name() << ": SHAPE_ASPECT found" << endl;
#endif
Handle(StepRepr_ProductDefinitionShape) aPDS = aspect->OfShape();
if ( ! aspect.IsNull() ) target.SetValue ( aspect );
}
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
else cout << Shape.TShape()->DynamicType()->Name() << ": PDS NOT found, fail to create SHAPE_ASPECT" << endl;
#endif
}
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
else cout << Shape.TShape()->DynamicType()->Name() << ": GeomRepItem NOT found" << endl;
#endif
}
if ( PDS.IsNull() ) {
Handle(StepRepr_ShapeAspect) SA = CD.ShapeAspect();
if ( SA.IsNull() ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Handle(Message_Messenger) sout = Message::DefaultMessenger();
sout << "Error: Cannot find target entity (SA) for geometric_validation_property ";
Model()->PrintLabel ( PD, sout );
ProdDef = Handle(StepBasic_ProductDefinition)::DownCast ( subs.Value() );
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( ProdDef.IsNull() ) {
Handle(Message_Messenger) sout = Message::DefaultMessenger();
sout << "Error: Cannot find target entity (SDR) for geometric_validation_property ";
// }
// }
//}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( S.IsNull() ) {
Handle(Message_Messenger) sout = Message::DefaultMessenger();
sout << "Warning: Entity ";
if ( Name == "AREA_MEASURE" ) isArea = Standard_True;
else if ( Name == "VOLUME_MEASURE" ) isArea = Standard_False;
else {
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: Measure " << Model()->StringLabel ( M ) << " is neither area not volume" << endl;
#endif
return Standard_False;
Handle(StepGeom_CartesianPoint) P = Handle(StepGeom_CartesianPoint)::DownCast ( item );
if ( P.IsNull() || P->NbCoordinates() != 3 ) {
-#ifdef STEPCONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: Point " << Model()->StringLabel ( P ) << " is not valid for centroid" << endl;
#endif
return Standard_False;;
// ============================================================================
// Function: DumpWhatIs
-// Purpose: Use it in DEB mode to dump your shapes
+// Purpose: Use it in debug mode to dump your shapes
// ============================================================================
-#ifdef STEPCONTROL_DEB
+#ifdef OCCT_DEBUG
static void DumpWhatIs(const TopoDS_Shape& S) {
TopTools_MapOfShape aMapOfShape;
Handle(TCollection_HAsciiString) aPPVersion = aFileNameEntity->PreprocessorVersion();
if(aPPVersion.IsNull())
continue;
- #ifdef STEPCONTROL_DEB
+ #ifdef OCCT_DEBUG
cout << "Preprocessor version detected: " << aPPVersion->ToCString() << endl;
#endif
Standard_Integer anIDeasResult = aPPVersion->Search("I-DEAS");
if (anIDeasResult != -1) {
- #ifdef STEPCONTROL_DEB
+ #ifdef OCCT_DEBUG
cout << "Recognized as I-DEAS STP" << endl;
#endif
myNMTool.SetIDEASCase(Standard_True);
if ( isNMMode && sr->IsKind(STANDARD_TYPE(StepShape_NonManifoldSurfaceShapeRepresentation)) ) {
isManifold = Standard_False;
NM_DETECTED = Standard_True;
- #ifdef STEPCONTROL_DEB
+ #ifdef OCCT_DEBUG
Standard_Integer NMSSRItemsLen = sr->Items()->Length();
cout << "NMSSR with " << NMSSRItemsLen << " items detected" << endl;
#endif
if (isNMMode && myNMTool.IsIDEASCase() && isIDeasMode) {
isManifold = Standard_False;
NM_DETECTED = Standard_True;
- #ifdef STEPCONTROL_DEB
+ #ifdef OCCT_DEBUG
cout << "I-DEAS post processing for non-manifold topology ENABLED" << endl;
#endif
}
- #ifdef STEPCONTROL_DEB
+ #ifdef OCCT_DEBUG
else if ( myNMTool.IsIDEASCase() )
cout << "I-DEAS post processing for non-manifold topology DISABLED" << endl;
#endif
TP->Bind(sr, shbinder);
- #ifdef STEPCONTROL_DEB
+ #ifdef OCCT_DEBUG
DumpWhatIs(comp);
#endif
if (subCheckStatus != BRepCheck_NoError)
brepBuilder.Add(result, currentFace);
else {
- #ifdef STEPCONTROL_DEB
+ #ifdef OCCT_DEBUG
cout << "Redundant closing face detected: REMOVED from shell";
#endif
}
// ============================================================================
// Function: DumpWhatIs
-// Purpose: Use it in DEB mode to dump your shapes
+// Purpose: Use it in debug mode to dump your shapes
// ============================================================================
-#ifdef STEPCONTROL_DEB
+#ifdef OCCT_DEBUG
static void DumpWhatIs(const TopoDS_Shape& S) {
TopTools_MapOfShape aMapOfShape;
aBrepBuilder.Add(aDirectShapes, aDirectChild);
}
- #ifdef STEPCONTROL_DEB
+ #ifdef OCCT_DEBUG
DumpWhatIs(aDirectShapes);
#endif
TopExp::MapShapesAndAncestors(aDirectShapes, TopAbs_EDGE, TopAbs_FACE, aMapEdgeFaces);
Standard_Integer aNbEdges = aMapEdgeFaces.Extent();
- #ifdef STEPCONTROL_DEB
+ #ifdef OCCT_DEBUG
cout << "Checking whether the topology passed is manifold..." << endl;
#endif
}
}
- #ifdef STEPCONTROL_DEB
+ #ifdef OCCT_DEBUG
cout << "Check result: "
<< (aResult ? "TRUE" : "FALSE") << endl;
#endif
return aResult;
}
-
-/* this is a start of a comment! */
-#ifdef DEB
-void DumpBinder (const Handle(Transfer_Binder) &binder)
-{
- Handle(Transfer_Binder) bbb = binder;
- while ( ! bbb.IsNull() ) {
- Handle(Transfer_SimpleBinderOfTransient) bx =
- Handle(Transfer_SimpleBinderOfTransient)::DownCast ( bbb );
- cout << (void*)&bx;
- if ( ! bx.IsNull() ) {
- cout << "--> " << bx->ResultTypeName() << " " << *(void**)&bx->Result() << endl;
- }
- else cout << "--> ???" << endl;
- bbb = bbb->NextResult();
- }
- cout << endl;
-}
-#endif
-/* this is a end of a comment */
//=======================================================================
//function : STEPControl_ActorWrite
}
if ( aResult.IsNull() ) {
- #ifdef STEPCONTROL_DEB
+ #ifdef OCCT_DEBUG
cout << "\nNew NMSSR created" << endl;
#endif
aResult = new StepShape_NonManifoldSurfaceShapeRepresentation;
isNMSSRCreated = Standard_True;
} else {
- #ifdef STEPCONTROL_DEB
+ #ifdef OCCT_DEBUG
cout << "\nExisting NMSSR is used" << endl;
#endif
isNMSSRCreated = Standard_False;
//:abv 20.05.02: writing box & face from it (shared) in one compound
// as assembly - while face already translated, it should be
// re-translated to break sharing
-#ifdef STEPCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: STEPControl_ActorWrite::TransferShape(): shape already translated" << endl;
#endif
// return binder;
BRep_Builder aB;
aB.MakeCompound(aCompOfVrtx);
- #ifdef STEPCONTROL_DEB
+ #ifdef OCCT_DEBUG
if (!isManifold)
cout << "Exploding Solids to Shells if any..." << endl;
#endif
break;
}
if (iSexclude) {
-#ifdef STEPCONTROL_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: STEPControl_Reader::NbRootsForTransfer exclude PDWAD from roots" << endl;
#endif
continue;
}
catch (Standard_Failure)
{
-#ifdef SHAPEANALYSIS_DEB
+#ifdef OCCT_DEBUG
cout << "Couldn't compute angle between derivative vectors" <<endl;
#endif
return Standard_False;
}
if (aHasChanged)
distmin = Sqrt (distmin2);
-#ifdef SHAPEANALYSIS_DEB
+#ifdef OCCT_DEBUG
cout<<"ShapeAnalysis_Geom:Project, param="<<param<<" -> distmin="<<distmin<<endl;
#endif
}
catch(Standard_Failure) {
OK = Standard_False;
-#ifdef SHAPEANALYSIS_DEB //:s5
+#ifdef OCCT_DEBUG //:s5
cout << "\nWarning: ShapeAnalysis_Curve::ProjectAct(): Exception in Extrema_ExtPC: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
if (theCurve->IsKind(STANDARD_TYPE(Geom_BoundedCurve)) && !theCurve->IsClosed()) {
if (First < cf) {
-#ifdef SHAPEANALYSIS_DEB
+#ifdef OCCT_DEBUG
cout << "Update Edge First Parameter to Curve First Parameter" << endl;
#endif
First = cf;
}
else if (First > cl) {
-#ifdef SHAPEANALYSIS_DEB
+#ifdef OCCT_DEBUG
cout << "Update Edge First Parameter to Curve Last Parameter" << endl;
#endif
First = cl;
}
if (Last < cf) {
-#ifdef SHAPEANALYSIS_DEB
+#ifdef OCCT_DEBUG
cout << "Update Edge Last Parameter to Curve First Parameter" << endl;
#endif
Last = cf;
}
else if (Last > cl) {
-#ifdef SHAPEANALYSIS_DEB
+#ifdef OCCT_DEBUG
cout << "Update Edge Last Parameter to Curve Last Parameter" << endl;
#endif
Last = cl;
if ( theCurve->Value(First).Distance(theCurve->Value(cf)) < preci ) First = cf;
if ( theCurve->Value(Last).Distance(theCurve->Value(cl)) < preci ) Last = cl;
if ( First > Last ) {
-#ifdef SHAPEANALYSIS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning : parameter range of edge crossing non periodic curve origin" << endl;
#endif
Standard_Real tmp = First;
// illegal sur une courbe fermee non periodique
// on inverse quand meme les parametres !!!!!!
else {
-#ifdef SHAPEANALYSIS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning : parameter range of edge crossing non periodic curve origin" << endl;
#endif
Standard_Real tmp = First;
}
//abv 15.03.00 #72 bm1_pe_t4 protection of exceptions in draw
else if ( First > Last ) {
-#ifdef SHAPEANALYSIS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: parameter range is bad; curve reversed" << endl;
#endif
First = theCurve->ReversedParameter ( First );
}
}
else {
-#ifdef SHAPEANALYSIS_DEB
+#ifdef OCCT_DEBUG
cout << "UpdateParam3d Failed" << endl;
cout << " - Curve Type : " << theCurve->DynamicType() << endl;
cout << " - Param 1 : " << First << endl;
#endif
//abv 15.03.00 #72 bm1_pe_t4 protection of exceptions in draw
if ( First > Last ) {
-#ifdef SHAPEANALYSIS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: parameter range is bad; curve reversed" << endl;
#endif
First = theCurve->ReversedParameter ( First );
}
catch(Standard_Failure) {
iso.Nullify();
-#ifdef SHAPEANALYSIS_DEB //:s5
+#ifdef OCCT_DEBUG //:s5
cout << "\nWarning: ShapeAnalysis_Surface, ComputeIso(): Exception in UVIso(): ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
gp_Pnt2d prev(S,T);
gp_Pnt2d solution;
if (SurfaceNewton(prev,P3D,preci,solution)) {
-#ifdef SHAPEANALYSIS_DEB
+#ifdef OCCT_DEBUG
cout <<"Newton found point on conic extrusion"<<endl;
#endif
return solution;
}
-#ifdef SHAPEANALYSIS_DEB
+#ifdef OCCT_DEBUG
cout <<"Newton failed point on conic extrusion"<<endl;
#endif
uf = -500;
}
else {
-#ifdef SHAPEANALYSIS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeAnalysis_Surface::ValueOfUV(): Extrema failed, doing Newton" << endl;
#endif
// on essai sur les bords
//szv#4:S4163:12Mar99 optimized
S = (Precision::IsInfinite(uf))? 0 : (uf+ul) / 2.;
T = (Precision::IsInfinite(vf))? 0 : (vf+vl) / 2.;
-#ifdef SHAPEANALYSIS_DEB //:s5
+#ifdef OCCT_DEBUG //:s5
cout << "\nWarning: ShapeAnalysis_Surface::ValueOfUV(): Exception: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
} // fin try RAJOUT
catch(Standard_Failure) {
theMin = RealLast(); // theMin de depart
-#ifdef SHAPEANALYSIS_DEB //:s5
+#ifdef OCCT_DEBUG //:s5
cout << "\nWarning: ShapeAnalysis_Curve::UVFromIso(): Exception: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
void ShapeAnalysis_WireOrder::SetCouples(const Standard_Real /*gap*/)
{
-#ifdef SHAPEANALYSIS_DEB
+#ifdef OCCT_DEBUG
cout<<"ShapeAnalysis_WireOrder:SetCouple not yet implemented"<<endl;
#endif
}
}
}
catch(Standard_Failure) {
-#ifdef SHAPEBUILD_DEB
+#ifdef OCCT_DEBUG
cout << "\nWarning: ShapeBuild_Edge: Exception in BuildCurve3d: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
{
BRepBuilderAPI_MakeEdge ME (curve, p1, p2);
if (!ME.IsDone()) {
-#ifdef SHAPEBUILD_DEB
+#ifdef OCCT_DEBUG
cout << "\nWarning: ShapeBuild_Edge::MakeEdge BRepAPI_NotDone";
#endif
return;
{
BRepBuilderAPI_MakeEdge ME (pcurve, S, p1, p2);
if (!ME.IsDone()) {
-#ifdef SHAPEBUILD_DEB
+#ifdef OCCT_DEBUG
cout << "\nWarning: ShapeBuild_Edge::MakeEdge BRepAPI_NotDone";
#endif
return;
aBSpline = GeomConvert::CurveToBSplineCurve(C3D,Convert_QuasiAngular);
}
catch (Standard_Failure) {
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: GeomConvert_ApproxSurface Exception: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
Handle(Geom_BSplineCurve) bspl = ConvertCurveToBSpline(basis, VF, VL, Tol3d, cnt, MaxSegments, MaxDegree);
gp_Ax1 axis = revol->Axis();
Handle(Geom_SurfaceOfRevolution) newRevol = new Geom_SurfaceOfRevolution(bspl,axis);
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout <<" Revolution on offset converted" << endl;
#endif
S = newRevol;
Standard_Boolean Done = anApprox.IsDone();
if (anApprox.MaxError() <= Tol3d && Done) {
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
Standard_Integer nbOfSpan = (anApprox.Surface()->NbUKnots()-1)*(anApprox.Surface()->NbVKnots()-1);
cout << "\terror = " << anApprox.MaxError() << "\tspans = " << nbOfSpan << endl;
cout << " Surface is aproximated with continuity " << (GeomAbs_Shape)cnt <<endl;
else {
if(anApprox.HasResult())
errSpl = Handle(Geom_BSplineSurface)::DownCast(anApprox.Surface());
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "\terror = " << anApprox.MaxError() <<endl;
#endif
break;
}
catch (Standard_Failure) {
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: GeomConvert_ApproxSurface Exception: try to decrease continuity ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
return (i <= edges->Length());
}
catch ( Standard_Failure ) {
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout<<"Error: ShapeConstruct::JoinPCurves Exception in GeomConvert_CompCurveToBSplineCurve: ";
Standard_Failure::Caught()->Print(cout); cout<<endl;
#endif
bspl = GeomConvert::CurveToBSplineCurve(tc);
}
catch ( Standard_Failure ) {
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeConstruct_Curve::ConvertToBSpline(): Exception in GeomConvert: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
return bspl;
}
catch ( Standard_Failure ) {
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeConstruct_Curve::ConvertToBSpline(): Exception in Segment: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
bspl = Conv.Curve();
}
catch ( Standard_Failure ) {
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeConstruct_Curve::ConvertToBSpline(): Exception in Approx_Curve3d: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
bspl = Geom2dConvert::CurveToBSplineCurve(tc);
}
catch ( Standard_Failure ) {
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeConstruct_Curve::ConvertToBSpline(): Exception in Geom2dConvert: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
return bspl;
}
catch ( Standard_Failure ) {
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeConstruct_Curve::ConvertToBSpline(): Exception in Segment: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
bspl = Conv.Curve();
}
catch ( Standard_Failure ) {
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeConstruct_Curve::ConvertToBSpline(): Exception in Approx_Curve3d: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
if ( bspl->Knot(i+1) > First && bspl->Knot(i) < Last ) nint++;
Standard_Integer minPnt = nint * ( bspl->Degree() + 1 );
while ( nbPini < minPnt ) nbPini += NCONTROL - 1;
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
if ( nbPini > NCONTROL )
cout << "Warning: number of points for projecting is " << nbPini << endl;
#endif
if ( appr.IsDone() )
c2d = appr.Curve2d();
}
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
else
cout<<"Warning: ProjLib cutting pcurve "<< First << " -> " << ubeg <<" ; "<< Last << " -> " << ufin << endl;
#endif
}
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
else cout<<"Warning: ProjLib "<< nbSol << " curves in ProjLib"<<endl;
#endif
if(c2d.IsNull()) {
}
catch(Standard_Failure) {
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeConstruct_ProjectCurveOnSurface::PerformByProjLib(): Exception: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
Standard_Real Up = ul - uf;
Standard_Real Vp = vl - vf;
Standard_Real dist2d;
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
if (mySurf->IsUClosed(myPreci) && mySurf->IsVClosed(myPreci)) {//#78 rln 12.03.99 S4135
cout << "WARNING : Recadrage incertain sur U & VClosed" << endl;
}
pnt2d (i) = newCurr;
}
// on verifie
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
dist2d = pnt2d (i-1).Distance(pnt2d (i));
if (dist2d > ( Vp / 2) ) {
cout << "Echec dans le recadrage" << endl;
return C2d;
}
catch(Standard_Failure) {
-#ifdef SHAPECONSTRUCT_DEB //:s5
+#ifdef OCCT_DEBUG //:s5
// debug ...
Standard_Integer nbp = params->Length();
Standard_Integer nb2 = points2d->Length();
if (myInterPol2d.IsDone()) C2d = myInterPol2d.Curve();
}
catch(Standard_Failure) {
-#ifdef SHAPECONSTRUCT_DEB //:s5
+#ifdef OCCT_DEBUG //:s5
// // debug ...
Standard_Integer nbp = params->Length();
Standard_Integer nb2 = points2d->Length();
}
catch(Standard_Failure) {
C3d.Nullify();
-#ifdef SHAPECONSTRUCT_DEB //:s5
+#ifdef OCCT_DEBUG //:s5
cout << "Warning: ShapeConstruct_ProjectCurveOnSurface::InterpolateCurve3d(): Exception: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
if (nbPntDropped == 0)
return;
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Warning : removing 3d points for interpolation" << endl;
#endif
// Build new HArrays
Standard_Integer newLast = lastElem - nbPntDropped;
if ((newLast - firstElem + 1) < 2) {
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Too many degenerated points for 3D interpolation" << endl;
#endif
return;
if (nbPntDropped == 0)
return;
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Warning : removing 2d points for interpolation" << endl;
#endif
// Build new HArrays
Standard_Integer newLast = lastElem - nbPntDropped;
if ((newLast - firstElem + 1) < 2) {
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Too many degenerated points for 2D interpolation" << endl;
#endif
//pdn 12.02.99 S4135 Creating pcurve with minimal length.
Standard_Integer newCurr = 1;
for (i = firstElem; i <= lastElem ; i++) {
if (tmpParam.Value(i) == 1) {
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Point " << i << " : " << points->Value(i).X() << " " << points->Value(i).Y() << " at param " << params->Value(i) << endl;
#endif
newPnts->SetValue(newCurr, points->Value(i));
newCurr ++;
}
else {
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
cout << "Removed " << i << " : " << points->Value(i).X() << " " << points->Value(i).Y() << " at param " << params->Value(i) << endl;
#endif
}
} // RAJOUT
catch(Standard_Failure) {
// pb : on affiche ce qu on peut
-#ifdef SHAPECONSTRUCT_DEB
+#ifdef OCCT_DEBUG
for (Standard_Integer numpnt = 1; numpnt <= nbrPnt; numpnt ++) {
cout<<"["<<numpnt<<"]param="<<params(numpnt)<<" point=("<<
points(numpnt).X()<<" "<<points(numpnt).Y()<<" "<<points(numpnt).Z()<<")"<<endl;
}
#endif
-#ifdef SHAPECONSTRUCT_DEB //:s5
+#ifdef OCCT_DEBUG //:s5
cout << "Warning: ShapeConstruct_ProjectCurveOnSurface::IsAnIsoparametric(): Exception: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
if(ConvertCurve(BasCurve,ResCurve,Standard_False,Max(VF,BasCurve->FirstParameter()),Min(VL,BasCurve->LastParameter()),TolS,Standard_False)) {
Handle(Geom_SurfaceOfRevolution) newRevol = new Geom_SurfaceOfRevolution(ResCurve,Surface->Axis());
aSurf = newRevol;
-#ifdef SHAPECUSTOM_DEB
+#ifdef OCCT_DEBUG
cout <<" Revolution on offset converted" << endl;
#endif
}
if (anApprox.MaxError() <= myTol3d && Done) {
nbOfSpan = (anApprox.Surface()->NbUKnots()-1)*(anApprox.Surface()->NbVKnots()-1);
-#ifdef SHAPECUSTOM_DEB
+#ifdef OCCT_DEBUG
if((imax-i+1)!=1) {
cout << " iteration = " << i
<< "\terror = " << anApprox.MaxError()
}
catch (Standard_Failure) {
-#ifdef SHAPECUSTOM_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: GeomConvert_ApproxSurface Exception: try to decrease continuity ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
else continue;
}
else {
-#ifdef SHAPECUSTOM_DEB
+#ifdef OCCT_DEBUG
cout<<" Approximation iteration out. Surface is not aproximated." << endl;
#endif
return Standard_False;
if(MaxDeg < myParameters->GMaxDegree())
{ MaxDeg = myParameters->GMaxDegree(); continue;}
else {
-#ifdef SHAPECUSTOM_DEB
+#ifdef OCCT_DEBUG
cout<<" Approximation iteration out. Surface is not aproximated." << endl;
#endif
return Standard_False;
(anApprox.MaxError() >= Max(TolCur,myTol3d)))) {
if(MaxSeg < myParameters->GMaxSeg()) { MaxSeg = myParameters->GMaxSeg(); aC =aC1; continue;}
else {
-#ifdef SHAPECUSTOM_DEB
+#ifdef OCCT_DEBUG
cout << "Curve is not aproxed with continuity "<< aCont<<endl;
#endif
if(IsConvert) {
MaxDeg = myParameters->GMaxDegree(); aC = aC1; continue;
}
else {
-#ifdef SHAPECUSTOM_DEB
+#ifdef OCCT_DEBUG
cout << "Curve is not aproxed with continuity "<< aCont<<endl;
#endif
if(IsConvert) {
}
}
catch (Standard_Failure) {
-#ifdef SHAPECUSTOM_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: GeomConvert_ApproxCurve Exception: Wrong Coefficient : Decrease continuity ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
if(myDeg && ((DegC > MaxDeg) || !Done || ( anApprox.MaxError() >= Max(myTol2d,TolCur)))) {
if(MaxSeg < myParameters->GMaxSeg()) { MaxSeg = myParameters->GMaxSeg(); aC =aC1; continue;}
else {
-#ifdef SHAPECUSTOM_DEB
+#ifdef OCCT_DEBUG
cout << "Curve is not aproxed with continuity "<< aCont<<endl;
#endif
if(IsConvert) {
MaxDeg = myParameters->GMaxDegree(); aC =aC1; continue;
}
else {
-#ifdef SHAPECUSTOM_DEB
+#ifdef OCCT_DEBUG
cout << "Curve is not aproxed with continuity "<< aCont<<endl;
#endif
if(IsConvert) {
}
}
catch (Standard_Failure) {
-#ifdef SHAPECUSTOM_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: Geom2dConvert_ApproxCurve Exception: Wrong Cofficient :Decrease Continuity ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
converted = Standard_True;
}
}
-#ifdef SHAPECUSTOM_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeCustom_Surface: Closed BSplineSurface is caused to be periodic" << endl;
#endif
if ( ! converted ) return newCurve;
// CKY 3-FEV-1997 : verification du sens de description
//gp_Dir AXY = aAx3.YDirection(); // AXY not used (skl)
if (aAx3.YDirection().Dot (origD1U) < 0) {
-#ifdef SHAPECUSTOM_DEB
+#ifdef OCCT_DEBUG
cout<<" Surface Analytique : sens a inverser"<<endl;
#endif
aAx3.YReverse(); // mais X reste !
new Geom_ToroidalSurface(aAx3, RR1, RR2);
if (j==2) anObject->UReverse();
anObject->D1 (0.,0.,resPnt,resD1U,resD1V);
-#ifdef SHAPECUSTOM_DEB
+#ifdef OCCT_DEBUG
if (resD1U.Dot(origD1U) < 0 && j != 2)
cout<<" Tore a inverser !"<<endl;
#endif
}
}
-#ifdef SHAPECUSTOM_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeCustom_Surface: Closed BSplineSurface is caused to be periodic" << endl;
#endif
if ( ! converted ) return newSurf;
ok &= Curve (i)->Value (Curve(i)->LastParameter()).IsEqual
(Curve (i + 1)->Value (Curve(i + 1)->FirstParameter()), Preci);
}
-#ifdef SHAPEEXTEND_DEB
+#ifdef OCCT_DEBUG
if (!ok) cout << "Warning: ShapeExtend_ComplexCurve: not connected in 3d" << endl;
#endif
return ok;
if ( ! SetUJointValues ( UJoints ) || ! SetVJointValues ( VJoints ) ) {
ok = Standard_False;
ComputeJointValues ( ShapeExtend_Natural );
-#ifdef SHAPEEXTEND_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeExtend_CompositeSurface::Init: bad joint values" << endl;
#endif
}
else if ( maxdist2 > Prec*Prec ) ok = Standard_False;
}
-#ifdef SHAPEEXTEND_DEB
+#ifdef OCCT_DEBUG
if ( ! ok ) cout << "Warning: ShapeExtend_CompositeSurface: not connected in 3d" << endl;
#endif
return ok;
const Message_Gravity)
{
if (object.IsNull()) {
-#ifdef SHAPEEXTEND_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeExtend_MsgRegistrator::Send: null object" << endl;
#endif
return;
const Message_Gravity)
{
if (shape.IsNull()) {
-#ifdef SHAPEEXTEND_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeExtend_MsgRegistrator::Send: null shape" << endl;
#endif
return;
}
if (!status) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout<<"** SameParameter not complete. On "<<numedge<<" Edges:";
if (nbfail > 0) cout<<" "<<nbfail<<" Failed";
cout<<endl;
BRepLib::EncodeRegularity ( S, tolang );
}
catch(Standard_Failure) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: Exception in ShapeFix::EncodeRegularity(): ";
Standard_Failure::Caught()->Print ( cout );
cout << endl;
for ( TopoDS_Iterator it(res); it.More(); it.Next() ) {
TopoDS_Edge E = TopoDS::Edge ( it.Value() );
if ( ! E.IsNull() ) segw->Add ( E );
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
else cout << "Error: ShapeFix_ComposeShell, ApplyContext: wrong mapping of edge" << endl;
#endif
}
else wire.AddEdge ( index, aE, iumin, iumax, ivmin, ivmax );
}
}
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
else cout << "Warning: ShapeFix_ComposeShell, ApplyContext: edge is to remove - not implemented" << endl;
#endif
else if ( code == IOR_BOTH ) { // parity error in intersector
code = IOR_LEFT;
myStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_FAIL2 );
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_ComposeShell::ComputeCode: lost intersection point" << endl;
#endif
}
if ( nsplit !=1 ) {
DistributeSplitPoints ( wire.WireData(), myFace, i, nsplit, indexes, values );
if ( nsplit <=0 ) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Error: ShapeFix_ComposeShell::SplitWire: edge dismissed" << endl;
#endif
i--;
}
if ( tanglevel <0 ) {
// myStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_FAIL4 );
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_ComposeShell::SplitByLine: tangency level <0 !" << endl;
#endif
}
// protection against creating null-length edges
if ( SplitLinePar(i) - SplitLinePar(i-1) < ::Precision::PConfusion() ) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Info: ShapeFix_ComposeShell::SplitByLine: Short segment ignored" << endl;
#endif
if ( ! V1.IsSame ( V2 ) ) { // merge coincident vertices
Context()->Replace ( V1, V.Oriented ( V1.Orientation() ) );
Context()->Replace ( V2, V.Oriented ( V2.Orientation() ) );
V1 = V2 = V;
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Info: ShapeFix_ComposeShell::SplitByLine: Coincided vertices merged" << endl;
#endif
}
}
if ( parity % 2 ) {
myStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_FAIL4 );
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Error: ShapeFix_ComposeShell::SplitByLine: parity error" << endl;
#endif
}
i--;
continue;
}
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
for ( Standard_Integer k=1; ! myClosedMode && k <= seqw(i).NbEdges(); k++ )
if ( ! seqw(i).CheckPatchIndex ( k ) ) {
cout << "Warning: ShapeFix_ComposeShell::CollectWires: Wrong patch indices" << endl;
( seqw(i).Orientation() == TopAbs_EXTERNAL ||
( seqw(i).NbEdges() == 1 && //:abv 13.05.02: OCC320 - remove if degenerated
BRep_Tool::Degenerated ( seqw(i).Edge(1) ) ) ) ) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Info: ShapeFix_ComposeShell::CollectWires: Short segment ignored" << endl;
#endif
seqw(i).Orientation ( TopAbs_INTERNAL );
IsCoincided ( endPnt, firstPnt, myUResolution, myVResolution, 2.* tol ) ) ) {
if ( ! endV.IsSame ( sae.FirstVertex ( firstEdge ) ) ) {
myStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_FAIL5 );
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_ComposeShell::CollectWires: can't close wire" << endl;
#endif
}
//pdn add into resulting sequence!
ShapeFix_WireSegment s ( wd, TopAbs_FORWARD );
wires.Append ( s );
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout <<"Warning: Short segment processed as separate wire"<<endl;
#endif
continue;
// check for lost wires, and if they are, make them roots
if ( roots.Length() <=0 && loops.Length() >0 ) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Error: ShapeFix_ComposeShell::MakeFacesOnPatch: can't dispatch wires" << endl;
#endif
for ( Standard_Integer j=1; j <= loops.Length(); j++ ) {
BRepTopAdaptor_FClass2d clas ( fc, ::Precision::PConfusion() );
if ( clas.PerformInfinitePoint() == TopAbs_IN ) {
reverse = Standard_True;
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_ComposeShell::MakeFacesOnPatch: badly oriented wire" << endl;
#endif
}
// check for lost wires, and if they are, make them roots
if ( i == roots.Length() && loops.Length() >0 ) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Error: ShapeFix_ComposeShell::MakeFacesOnPatch: can't dispatch wires" << endl;
#endif
for ( j=1; j <= loops.Length(); j++ ) {
}
*/
// Other case not yet implemented
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "TranslatePCurve not performed" << endl;
#endif
return theNewL2d;//*theL2d;
Handle(Geom2d_BSplineCurve)
aBC = Handle(Geom2d_BSplineCurve)::DownCast(aC2d);
if (aBC.IsNull()) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Untreated curve type in TranslatePCurve" << endl;
#endif
return aC2d;
} // end try
catch(Standard_Failure) {
myStatus |= ShapeExtend::EncodeStatus (ShapeExtend_FAIL2);
-#ifdef SHAPEFIX_DEB //:s5
+#ifdef OCCT_DEBUG //:s5
cout << "Warning: ShapeFix_Edge::FixAddPCurve(): Exception: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
}
}
catch(Standard_Failure) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "\nWarning: ShapeFix_Edge: Exception in SameParameter: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
Standard_Real U1 = FirstParam();
Standard_Real U2 = LastParam();
if (U1>=U2) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Parametres inverses ... " << endl;
#endif
Standard_Real tmp = U1;
else return Standard_False;
} // end try
catch(Standard_Failure) {
-#ifdef SHAPEFIX_DEB //:s5
+#ifdef OCCT_DEBUG //:s5
cout << "Warning: ShapeFix_EdgeProjAux, FindParameterWithExt(): Exception: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
return;
}
}
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
else cout <<"Other type of deg curve"<<endl;
#endif
cf=-10000;
cl= 10000;
//pdn not cutted by bounds
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout<<"Infinite Surface"<<endl;
#endif
}
//pdn not linear case not managed
cf=-10000;
cl= 10000;
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout<<"Some infinite curve"<<endl;
#endif
}
myFirstParam = theCurve2d->ReversedParameter(Usup);
myLastParam = theCurve2d->ReversedParameter(Uinf);
theCurve2d->Reverse();
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_EdgeProjAux: pcurve reversed" << endl;
#endif
return;
UpdateParam2d(theCurve2d);
else {
myLastParam+=period;
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout <<" Added"<<endl;
#endif
}
if(w1 > wmid) {
myLastParam -=period;
UpdateParam2d(theCurve2d);
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout <<" Added & Inverted"<<endl;
#endif
} else if (w2 < wmid) {
if ( Abs ( myFirstParam - cl ) <= preci2d ) myFirstParam = cf;
else if ( Abs ( myLastParam - cf ) <= preci2d ) myLastParam = cl;
else {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Error : curve 2d range crossing non periodic curve origin";
cout << endl;
#endif
}
}
else {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning : non increasing parameters for 2d curve." << endl;
cout << " update parameter 2d uncertain." << endl;
#endif
#include <TopTools_DataMapOfShapeShape.hxx>
#include <NCollection_Array1.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#define DEBUG
#endif
}
if(aResWires.Length()>1) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout<<"Wire was splitted on "<<aResWires.Length()<<" wires"<< endl;
#endif
}
BRepTools::Update(myFace);
/**/
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout<<"Natural bound on sphere or torus with holes added"<<endl; // mise au point !
#endif
SendWarning ( myFace, Message_Msg ( "FixAdvFace.FixOrientation.MSG0" ) );// Face created with natural bounds
ws.SetValue ( 1, sbdw->Wire() );
SendWarning ( sbdw->Wire(), Message_Msg ( "FixAdvFace.FixOrientation.MSG5" ) );// Wire on face was reversed
done = Standard_True;
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout<<"Wire reversed"<<endl; // mise au point !
#endif
}
Standard_Integer k =1;
for( ; k <= aSeqReversed.Length(); k++ )
{
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout<<"Wire no "<<aSeqReversed.Value(k)<<" of "<<nb<<" reversed"<<endl; // mise au point !
#endif
}
}
else {
w2.Reverse();
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
if ( ! isdeg2 ) cout << "Warning: ShapeFix_Face::FixMissingSeam(): wire reversed" << endl;
#endif
}
}
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
else cout << "Warning: ShapeFix_Face::FixMissingSeam(): incompatible open wires" << endl;
#endif
}
// else return Standard_False; // abort
else {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_Face::FixMissingSeam(): more than two open wires detected!" << endl;
#endif
//:abv 30.08.09: if more than one open wires and more than two of them are
w1.Nullify();
w2.Nullify();
i = 0;
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_Face::FixMissingSeam(): open degenerated wire removed" << endl;
#endif
continue;
if ( nbRemoved <=0 ) return Standard_False;
if ( nbWires <=0 ) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_Face: All wires on a face have small area; left untouched" << endl;
#endif
return Standard_False;
}
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_Face: " << nbRemoved << " small area wire(s) removed" << endl;
#endif
if ( ! Context().IsNull() ) Context()->Replace ( myFace, face );
Standard_Boolean isDone =(aResWires.Length() && isClosed);
if(isDone && aResWires.Length() >1)
{
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout<<"Wire was splitted on "<<aResWires.Length()<<" wires"<< endl;
#endif
}
V1=sae.FirstVertex(E1);
V2=sae.LastVertex(E2);
if(!V1.IsSame(V2)) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout<<"wire not closed --> stop split"<<endl;
#endif
return Standard_False;
#include <ShapeAnalysis_Edge.hxx>
#include <ShapeAnalysis_WireOrder.hxx>
#include <Geom2d_Curve.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopTools_MapOfShape.hxx>
#endif
// Clear the temporary map of free edges
theFreeEdges.Clear();
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
//-------------------------------
//szv debug - preparation results
//-------------------------------
// Process second face for the pair of different faces only
if (theFirstFace.IsSame(theSecondFace)) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout<<"Warning: ShapeFix_FaceConnect::Build: Self-connected face"<<endl;
#endif
}
// Clear the temporary map of processed faces
theProcessed.Clear();
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
//-------------------------------
//szv debug - sewing results
//-------------------------------
TopoDS_Shape tmpReShape = theReShape->Apply(result);
result = TopoDS::Shell(tmpReShape);
if (theReShape->Status(ShapeExtend_OK)) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout<<"Warning: ShapeFix_FaceConnect::Build: Edges not replaced by ReShape"<<endl;
#endif
}
else if (theReShape->Status(ShapeExtend_FAIL1)) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout<<"Error: ShapeFix_FaceConnect::Build: ReShape failed on edges"<<endl;
#endif
}
result = TopoDS::Shell(tmpshape);
if (theReShape->Status(ShapeExtend_FAIL1)) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout<<"Error: ShapeFix_FaceConnect::Build: ReShape failed on vertices"<<endl;
#endif
}
}
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
//-------------------------------
//szv debug - reshape results
//-------------------------------
}
else {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "The face is not strip face" << endl;
#endif
return theNewEdge;
// B.Add(mySolid,TopoDS::Shell(iter.Value()));
myShape = solid;
}
-#ifdef DEB_GET_MIDDLE_POINT
+#ifdef OCCT_DEBUG_GET_MIDDLE_POINT
//=======================================================================
//function : GetMiddlePoint
//purpose :
}
if(numon == 3 && pointstatus ==TopAbs_ON) {
-#ifdef DEB_GET_MIDDLE_POINT
+#ifdef OCCT_DEBUG_GET_MIDDLE_POINT
gp_Pnt pmid;
GetMiddlePoint(aShell2,pmid);
bsc3d.Perform(pmid,Precision::Confusion());
}
}
catch(Standard_Failure) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_Solid::SolidFromShell: Exception: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
infinstatus = bsc3d.State();
}
catch(Standard_Failure) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_Solid::SolidFromShell: Exception: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
}
}
catch(Standard_Failure) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_Solid::SolidFromShell: Exception: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
}
}
if ( seq.Length() >0 ) { // supposed that edge is SP
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Edge going over singularity detected; splitted" << endl;
#endif
Standard_Boolean isFwd = ( E.Orientation() == TopAbs_FORWARD );
myFixEdge->Projector()->AdjustOverDegenMode() = Standard_False;
myFixEdge->FixAddPCurve ( sbwd->Edge(overdegen), face, sbwd->IsSeam(overdegen), myAnalyzer->Surface(), Precision());
}
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Edge going over singularity detected; pcurve adjusted" << endl;
#endif
}
myStatusSelfIntersection |= ShapeExtend::EncodeStatus ( ShapeExtend_DONE3 );
num = ( myClosedMode ? 1 : 2 );
nb = sbwd->NbEdges();
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_Wire::FixSelfIntersection: Edge removed" << endl;
#endif
}
if ( ! Context().IsNull() ) UpdateWire();
myShape.Nullify();
}
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
if (StatusSelfIntersection (ShapeExtend_DONE5))
cout<<"Warning: ShapeFix_Wire::FixIntersection: Non-adjacent intersection fixed (split-"
<<NbSplit<<", cut-"<<NbCut<<", removed-"<<NbRemoved<<")"<<endl;
myStatusSelfIntersection |= ShapeExtend::EncodeStatus ( ShapeExtend_FAIL3 );
if(isDone)
myStatusSelfIntersection |= ShapeExtend::EncodeStatus ( ShapeExtend_DONE5 );
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (StatusSelfIntersection (ShapeExtend_DONE5))
cout << "Warning: ShapeFix_Wire::FixSelfIntersection: Non ajacent intersection fixed" << endl;
#endif
vclosed = Standard_True;
VRange = aBaseCrv->Period();
IsVCrvClosed = Standard_True;
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_Wire::FixShifted set vclosed True for Surface of Revolution" << endl;
#endif
}
UpdateEdgeUVPoints ( edge, Face() );
}
myLastFixStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_DONE1 );
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Info: ShapeFix_Wire::FixShifted(): bi - meridian case fixed" << endl;
#endif
continue;
if ( ! sae.PCurve ( E, face, c2d, a, b, Standard_False ) )
return Standard_False;
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Cut Loop: params (" << t1 << ", " << t2;
#endif
GeomAdaptor_Curve GAC ( crv, f, l );
Standard_Real dt = tolfact * GAC.Resolution(prec);
t1 -= dt; //1e-3;//::Precision::PConfusion();
t2 += dt; //1e-3;//::Precision::PConfusion();
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << ") -> (" << t1 << ", " << t2 << ")" << endl;
#endif
if ( ! TryNewPCurve ( E, face, bs, a, b, newtol ) ) return Standard_False;
Standard_Real tol = BRep_Tool::Tolerance ( E );
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Cut Loop: tol orig " << tol << ", prec " << prec << ", new tol " << newtol << endl;
#endif
if ( newtol > Max ( prec, tol ) ) return Standard_False;
TopoDS_Edge &E1,
TopoDS_Edge &E2)
{
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout<<"Info: ShapeFix_Wire::FixSelfIntersection : Try insert vertex"<<endl;
#endif
c2d = bs;
}
catch ( Standard_Failure ) {
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_Wire::FixLacking: Exception in Geom2d_BSplineCurve::Segment()" << endl;
#endif
return Standard_False;
// insert new edge
if ( doAddDegen ) {
myLastFixStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_DONE3 );
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_Wire::FixLacking: degenerated edge added" << endl;
#endif
}
FixSelfIntersectingEdge ( n1 );
FixSelfIntersectingEdge ( n2 );
FixIntersectingEdges ( n2 ); //skl 24.04.2003 for OCC58
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Info: ShapeFix_Wire::FixLacking: Bending pcurves" << endl;
#endif
myLastFixStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_DONE5 );
const Standard_Integer iumin)
{
if ( myIUMin->Value(i) < iumin ) myIUMin->SetValue ( i, iumin );
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
if ( myIUMin->Value(i) > myIUMax->Value(i) )
cout << "Warning: ShapeFix_WireSegment::DefineIUMin: indexation error" << endl;
#endif
const Standard_Integer iumax)
{
if ( myIUMax->Value(i) > iumax ) myIUMax->SetValue ( i, iumax );
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
Standard_Integer iun = myIUMin->Value(i), iux = myIUMax->Value(i);
if ( iun > iux )
cout << "Warning: ShapeFix_WireSegment::DefineIUMax: indexation error" << endl;
const Standard_Integer ivmin)
{
if ( myIVMin->Value(i) < ivmin ) myIVMin->SetValue ( i, ivmin );
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
Standard_Integer ivn = myIVMin->Value(i), ivx = myIVMax->Value(i);
if ( ivn > ivx )
cout << "Warning: ShapeFix_WireSegment::DefineIVMin: indexation error" << endl;
const Standard_Integer ivmax)
{
if ( myIVMax->Value(i) > ivmax ) myIVMax->SetValue ( i, ivmax );
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
Standard_Integer ivn = myIVMin->Value(i), ivx = myIVMax->Value(i);
if ( ivn > ivx )
cout << "Warning: ShapeFix_WireSegment::DefineIVMax: indexation error" << endl;
Standard_Integer dU = myIUMax->Value(i) - myIUMin->Value(i);
Standard_Integer dV = myIVMax->Value(i) - myIVMin->Value(i);
Standard_Boolean ok = ( dU ==0 || dU ==1 ) && ( dV ==0 || dV ==1 );
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
if ( ! ok )
cout << "Warning: ShapeFix_WireSegment::CheckPatchIndex: incomplete indexation" << endl;
#endif
}
catch (Standard_Failure)
{
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_Wire_1::FixGap3d: Exception in TrimmedCurve" <<first<<" " <<last<<endl;
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
}
catch (Standard_Failure)
{
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_Wire_1::FixGap3d: Exception in TrimmedCurve :"<<endl;
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
}
catch (Standard_Failure)
{
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_Wire_1::FixGap2d: Exception in TrimmedCurve2d" <<first<<" " <<last<<endl;
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
catch (Standard_Failure)
{
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeFix_Wire_1::FixGap2d: Exception in TrimmedCurve2d :"<<endl;
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
}
catch ( Standard_Failure )
{
-#ifdef SHAPEFIX_DEB
+#ifdef OCCT_DEBUG
cout<<"Error: ShapeFix_Wireframe::FixSmallEdges: JoinEdges: Exception in GeomConvert_CompCurveToBSplineCurve: ";
Standard_Failure::Caught()->Print(cout); cout<<endl;
#endif
{
if ( dic.IsNull() ) dic = new ShapeProcess_DictionaryOfOperator;
if ( dic->HasItem ( name, Standard_True ) ) {
-#ifdef SHAPEPROCESS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: operator with name " << name << " is already registered!" << endl;
#endif
return Standard_False;
{
if ( dic.IsNull() ) dic = new ShapeProcess_DictionaryOfOperator;
if ( ! dic->HasItem ( name, Standard_True ) ) {
-#ifdef SHAPEPROCESS_DEB
+#ifdef OCCT_DEBUG
cout << "Error: no operator with name " << name << " registered!" << endl;
#endif
return Standard_False;
// get description of the sequence
TCollection_AsciiString sequence;
if ( ! context->GetString ( "exec.op", sequence ) ) {
-#ifdef SHAPEPROCESS_DEB
+#ifdef OCCT_DEBUG
cout << "Error: ShapeProcess_Performer::Perform: sequence not defined for " << seq << endl;
#endif
context->UnSetScope();
}
}
if ( sRC.IsNull() ) {
-#ifdef SHAPEPROCESS_DEB
+#ifdef OCCT_DEBUG
cout << "Info: ShapeProcess_Context: Reload Resource_Manager: "
<< name.ToCString() << " -> " << file << endl;
#endif
if ( myRC.IsNull() ) return Standard_False;
Handle(TCollection_HAsciiString) pname = MakeName ( myScope, param );
if ( ! myRC->Find ( pname->ToCString() ) ) {
-#ifdef SHAPEPROCESS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeProcess_Context::GetInteger(): Parameter " << pname->ToCString() << " is not defined" << endl;
#endif
return Standard_False;
ref.LeftAdjust();
ref.RightAdjust();
if ( ! myRC->Find ( ref.ToCString() ) ) {
-#ifdef SHAPEPROCESS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeProcess_Context::GetInteger(): Parameter " << ref.ToCString() << " is not defined" << endl;
#endif
return Standard_False;
return Standard_True;
}
}
-#ifdef SHAPEPROCESS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeProcess_Context::GetInteger(): Parameter " << param << " is neither Real nor reference to Real";
#endif
return Standard_False;
ref.LeftAdjust();
ref.RightAdjust();
if ( ! myRC->Find ( ref.ToCString() ) ) {
-#ifdef SHAPEPROCESS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeProcess_Context::GetInteger(): Parameter " << ref.ToCString() << " is not defined" << endl;
#endif
return Standard_False;
return Standard_True;
}
}
-#ifdef SHAPEPROCESS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeProcess_Context::GetInteger(): Parameter " << param << " is neither Integer nor reference to Integer";
#endif
return Standard_False;
return Standard_True;
}
catch (Standard_Failure) {
-#ifdef SHAPEPROCESS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeProcess_Context::GetInteger(): " << param << ": ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
return myRC->Value ( MakeName ( myScope, param )->ToCString() );
}
catch (Standard_Failure) {
-#ifdef SHAPEPROCESS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeProcess_Context::GetInteger(): " << param << ": ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
SDA.SetMaxTolerance ( ctx->RealVal ( "MaxTolerance", 1. ) );
if ( ! SDA.Perform() && SDA.Status (ShapeExtend_FAIL) ) {
-#ifdef SHAPEPROCESS_DEB
+#ifdef OCCT_DEBUG
cout<<"ShapeDivideAngle failed"<<endl;
#endif
return Standard_False;
if ( ctx->GetBoolean ( "EdgeMode", EdgeMode ) ) SCB.SetEdgeMode(EdgeMode);
if ( ! SCB.Perform() && SCB.Status (ShapeExtend_FAIL) ) {
-#ifdef SHAPEPROCESS_DEB
+#ifdef OCCT_DEBUG
cout<<"Shape::ShapeConvertToBezier failed"<<endl; // !!!!
#endif
return Standard_False;
if ( ctx->GetReal ( "MaxTolerance", maxTol ) ) tool.SetMaxTolerance(maxTol);
if ( ! tool.Perform() && tool.Status (ShapeExtend_FAIL) ) {
-#ifdef SHAPEPROCESS_DEB
+#ifdef OCCT_DEBUG
cout<<"SplitContinuity failed"<<endl;
#endif
return Standard_False;
tool.SetNbSplitPoints(num);
tool.SetSurfaceSegmentMode(hasSeg);
if ( ! tool.Perform() && tool.Status (ShapeExtend_FAIL) ) {
-#ifdef SHAPEPROCESS_DEB
+#ifdef OCCT_DEBUG
cout<<"Splitting of closed faces failed"<<endl;
#endif
return Standard_False;
tool.SetNbSplitPoints(nbSplits);
if ( ! tool.Perform() && tool.Status (ShapeExtend_FAIL) ) {
-#ifdef SHAPEPROCESS_DEB
+#ifdef OCCT_DEBUG
cout<<"Splitting of closed edges failed"<<endl;
#endif
return Standard_False;
//=======================================================================
/*
-#ifdef DEB
+#ifdef OCCT_DEBUG
static void DumpMap (const TopTools_DataMapOfShapeShape &map)
{
cout << "----" << endl;
if ( repl.Extent() <=0 ) return;
RecModif ( myShape, repl, myMap, myUntil );
if ( myMap.IsBound(myShape) ) myResult = myMap.Find ( myShape );
-#ifdef DEB
+#ifdef OCCT_DEBUG
// cout << "Modifier: " << endl; DumpMap (myMap);
#endif
}
myResult = myMap.Find ( myShape );
myResult.Location(myShape.Location());
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
// cout << "ReShape: " << endl; DumpMap (myMap);
#endif
}
split->Append(val);
isUSplit = Standard_True;
}
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
else cout << "Warning: SU_ClosedFaceDivide: Thin face, not splitted" << endl;
#endif
}
split->Append(val);
isUSplit = Standard_False;
}
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
else cout << "Warning: SU_ClosedFaceDivide: Thin face, not splitted" << endl;
#endif
}
if(Abs(Last-bl) < precision)
Last = bl;
if(First < bf){
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout <<"Warning: The range of the edge exceeds the pcurve domain" <<endl;
#endif
First = bf;
mySplitValues->SetValue(1,First);
}
if(Last > bl){
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout <<"Warning: The range of the edge exceeds the pcurve domain" <<endl;
#endif
Last = bl;
if(Abs(Last-bl) < precision)
Last = bl;
if(First < bf){
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout <<"Warning: The range of the edge exceeds the curve domain" <<endl;
#endif
First = bf;
mySplitValues->SetValue(1,First);
}
if(Last > bl){
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout <<"Warning: The range of the edge exceeds the curve domain" <<endl;
#endif
Last = bl;
else
VFilteredJoints.Append(VJoints(i));
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
if(NbVFiltered || NbUFiltered)
cout<<"Warning: ShapeUpgrade_ConvertSurfaceToBezierBasis: thin patches dropped."<<endl;
#endif
bezier->Segment(V1,V2);
}
else {
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout <<"Warning: Resulting path is not surface of revolution basis on bezier curve"<<endl;
#endif
}
}
}
catch (Standard_Failure) {
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeUpgrade_FixSmallBezierCurve::Approx(): Exception in Segment :";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
}
}
catch (Standard_Failure) {
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeUpgrade_FixSmallBezierCurve::Approx(): Exception in Segment :";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
}
}
catch (Standard_Failure) {
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeUpgrade_FixSmallBezierCurve::Approx(): Exception in Segment :";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
}
catch (Standard_Failure) {
myStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_FAIL2 );
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout << "\nError: Exception in ShapeUpgrade_FaceDivide::Perform(): ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
if(Abs(lastPar-lP) < precision)
lastPar = lP;
if(firstPar < fP){
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout <<"Warning: The range of the edge exceeds the curve domain" <<endl;
#endif
firstPar = fP;
}
if(lastPar > lP){
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout <<"Warning: The range of the edge exceeds the curve domain" <<endl;
#endif
lastPar = lP;
Handle(Geom2d_BezierCurve)::DownCast(theNewCurve)->Segment (First, Last);
}
catch (Standard_Failure) {
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeUpgrade_Split2dCurve::Build(): Exception in Segment :";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
myStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_DONE3 );
}
catch (Standard_Failure) {
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeUpgrade_Split2dCurve::Build(): Exception in Segment :";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
case GeomAbs_C1 : BasCriterion = GeomAbs_C2; break;
case GeomAbs_C2 : BasCriterion = GeomAbs_C3; break;
case GeomAbs_C3 : //if (ShapeUpgrade::Debug()) cout<<". this criterion is not suitable for a Offset curve"<<endl;
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeUpgrade_SplitCurve2dContinuity: criterion C3 for Offset curve" << endl;
#endif
case GeomAbs_CN : BasCriterion = GeomAbs_CN; break;
if(Abs(lastPar-lP) < precision)
lastPar = lP;
if(firstPar < fP){
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout <<"Warning: The range of the edge exceeds the curve domain" <<endl;
#endif
firstPar = fP;
}
if(lastPar > lP){
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout <<"Warning: The range of the edge exceeds the curve domain" <<endl;
#endif
lastPar = lP;
if(Abs(Last-lastPar) < precision)
Last = lastPar;
if(First < firstPar){
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout <<"Warning: The range of the edge exceeds the curve domain" <<endl;
#endif
First = firstPar;
mySplitValues->SetValue(1,First);
}
if(Last > lastPar){
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout <<"Warning: The range of the edge exceeds the curve domain" <<endl;
#endif
Last = lastPar;
Handle(Geom_BezierCurve)::DownCast(theNewCurve)->Segment (First, Last);
}
catch (Standard_Failure) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeUpgrade_Split3dCurve::Build(): Exception in Segment :";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
myStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_DONE3 );
}
catch (Standard_Failure) {
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeUpgrade_Split3dCurve::Build(): Exception in Segment :";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
case GeomAbs_C1 : BasCriterion = GeomAbs_C2; break;
case GeomAbs_C2 : BasCriterion = GeomAbs_C3; break;
case GeomAbs_C3 : // if (ShapeUpgrade::Debug()) cout<<". this criterion is not suitable for a Offset curve"<<endl;
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeUpgrade_SplitCurve3dContinuity: criterion C3 for Offset curve" << endl;
#endif
case GeomAbs_CN : BasCriterion = GeomAbs_CN; break;
myStatus |= ShapeExtend::EncodeStatus ( ShapeExtend_DONE3 );
}
catch (Standard_Failure) {
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeUpgrade_SplitSurface::Build(): Exception in Segment :";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
case GeomAbs_C1 : BasCriterion = GeomAbs_C2; break;
case GeomAbs_C2 : BasCriterion = GeomAbs_C3; break;
case GeomAbs_C3 : //if (ShapeUpgrade::Debug()) cout<<". this criterion is not suitable for a Offset Surface"<<endl;;
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: ShapeUpgrade_SplitSurfaceContinuity: criterion C3 for Offset surface" << endl;
#endif
case GeomAbs_CN : BasCriterion = GeomAbs_CN; break;
}
}
if(aChain.Length()<SeqEdges.Length()) {
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout<<"can not create correct chain..."<<endl;
#endif
return Standard_False;
}
}
if (j < aChain.Length()) {
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout<<"null curve3d in edge..."<<endl;
#endif
return Standard_False;
break;
}
if(NeedUnion) {
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout<<"can not make analitical union => make approximation"<<endl;
#endif
TopoDS_Edge E = GlueEdgesWithPCurves(aChain, VF, VL);
aChain.SetValue(1,E);
}
else {
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout<<"can not make approximation for such types of curves"<<endl;
#endif
return Standard_False;
Handle(TColStd_HSequenceOfReal) revKnots2d = theSplit2dTool->SplitValues();
if(revKnots2d->Length()!=theKnots2d->Length()) {
isSeam = Standard_False;
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout << "Error: ShapeUpgrade_WireDivide: seam has different splitting values on pcurvesd" << endl;
#endif
}
if ( !theSegments2d.IsNull() ) {
Standard_Integer nbc2d = theSegments2d->Length();
if (nbc!=nbc2d) {
-#ifdef SHAPEUPGRADE_DEB
+#ifdef OCCT_DEBUG
cout<<"Error: Number of intervals are not equal for 2d 3d. Ignored."<<endl;
#endif
nbc = Min( nbc,nbc2d);
//! evaluated to zero (false).
//! The first argument is evaluated by all macros except Standard_ASSERT_VOID
//! which does not evaluate first argument when in Release mode.
-//! The mode is triggered by preprocessor macro DEB: if it is defined,
+//! The mode is triggered by preprocessor macro _DEBUG: if it is defined,
//! Debug mode is assumed, Release otherwise.
//!
//! In debug mode, if condition is not satisfied the macros call
inline void Standard_ASSERT_DO_NOTHING() {}
// User messages are activated in debug mode only
-#ifdef DEB
+#ifdef _DEBUG
#if (defined(_WIN32) || defined(__WIN32__))
#if defined(_MSC_VER)
// VS-specific intrinsic
#define Standard_ASSERT_DBGBREAK_() raise(SIGTRAP)
#endif
- #if defined(_MSC_VER) && defined(_DEBUG)
+ #if defined(_MSC_VER)
#include <crtdbg.h>
// use debug CRT built-in function that show up message box to user
// with formatted assert description and 3 possible actions
{
if ( (Value <= -1.) || (Value >= 1.) ){
Standard_NumericError::Raise("Illegal agument in ATanh");
-#ifdef STANDARD_DEB
+#ifdef OCCT_DEBUG
cout << "Illegal agument in ATanh" << endl ;
#endif
}
{
if ( Value < 1. ){
Standard_NumericError::Raise("Illegal agument in ACosh");
-#ifdef STANDARD_DEB
+#ifdef OCCT_DEBUG
cout << "Illegal agument in ACosh" << endl ;
#endif
}
Standard_Real Log (const Standard_Real Value)
{ if ( Value <= 0. ){
Standard_NumericError::Raise("Illegal agument in Log");
-#ifdef STANDARD_DEB
+#ifdef OCCT_DEBUG
cout << "Illegal agument in Log" << endl ;
#endif
}
{
if ( Value < 0. ){
Standard_NumericError::Raise("Illegal agument in Sqrt");
-#ifdef STANDARD_DEB
+#ifdef OCCT_DEBUG
cout << "Illegal agument in Sqrt" << endl ;
#endif
}
Handle(Standard_Transient) StdDrivers::Factory(const Standard_GUID& aGUID) {
if(aGUID == StdSchemaID) {
-#ifdef STDDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "StdSchema : Plugin" << endl;
#endif
static Handle(StdLSchema) model_ss = new StdLSchema;
static Standard_Boolean aNeedNested = Standard_True;
if(aNeedNested) {
aNeedNested = Standard_False;
-#ifdef STDDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "StdSchema: Adding nested schema" << endl;
#endif
Handle(StdSchema) aSchema = new StdSchema;
}
if(aGUID == StdStorageDriver) {
-#ifdef STDDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "StdDrivers : Storage Plugin" << endl;
#endif
static Handle(StdDrivers_DocumentStorageDriver) model_sd = new StdDrivers_DocumentStorageDriver;
return model_sd;
}
if(aGUID == StdRetrievalDriver) {
-#ifdef STDDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "StdDrivers : Retrieval Plugin" << endl;
#endif
static Handle(StdDrivers_DocumentRetrievalDriver) model_rd = new StdDrivers_DocumentRetrievalDriver;
Handle(Standard_Transient) StdLDrivers::Factory(const Standard_GUID& aGUID) {
if(aGUID == StdLSchemaID) {
-#ifdef STDLDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "StdLSchema : Plugin" << endl;
#endif
static Handle(StdLSchema) model_ss = new StdLSchema;
}
if(aGUID == StdLStorageDriver) {
-#ifdef STDLDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "StdLDrivers : Storage Plugin" << endl;
#endif
static Handle(StdLDrivers_DocumentStorageDriver) model_sd = new StdLDrivers_DocumentStorageDriver;
return model_sd;
}
if(aGUID == StdLRetrievalDriver) {
-#ifdef STDLDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "StdLDrivers : Retrieval Plugin" << endl;
#endif
static Handle(StdLDrivers_DocumentRetrievalDriver) model_rd = new StdLDrivers_DocumentRetrievalDriver;
-#ifdef DEB_MESH
+#ifdef OCCT_DEBUG_MESH
#include <OSD_Chronometer.hxx>
extern OSD_Chronometer FFaceTimer1,FFaceTimer2,FFaceTimer3,FFaceTimer4;
#endif
const Handle(Prs3d_Drawer)& aDrawer,
Prs3d_NListOfSequenceOfPnt& Curves) {
-#ifdef DEB_MESH
+#ifdef OCCT_DEBUG_MESH
FFaceTimer1.Start();
#endif
}
}
}
-#ifdef STDPRS_DEB
+#ifdef OCCT_DEBUG
else {
cout << "Cannot evaluate curve on surface"<<endl;
}
}
-#ifdef DEB_MESH
+#ifdef OCCT_DEBUG_MESH
FFaceTimer1.Stop();
FFaceTimer2.Start();
}
}
-#ifdef DEB_MESH
+#ifdef OCCT_DEBUG_MESH
FFaceTimer2.Stop();
FFaceTimer3.Start();
#endif
}
-#ifdef DEB_MESH
+#ifdef OCCT_DEBUG_MESH
FFaceTimer3.Stop();
FFaceTimer4.Start();
#endif
}
}
}
-#ifdef DEB_MESH
+#ifdef OCCT_DEBUG_MESH
FFaceTimer4.Stop();
#endif
}
}
}
}
-#ifdef STDPRS_DEB
+#ifdef OCCT_DEBUG
else {
cout << "Cannot evaluate curve on surface"<<endl;
}
BRep_Tool::Range (aWireExplorer.Current(), wf, wl);
if (Abs (wf - wl) <= Precision::Confusion())
{
- #ifdef STDSELECT_DEB
+ #ifdef OCCT_DEBUG
cout<<" StdSelect_BRepSelectionTool : Curve where ufirst = ulast ...."<<endl;
#endif
}
Standard_Boolean StepAP209_Construct::CreateFeaStructure (const Handle(StepBasic_Product) &Prod) const
{
if(Prod.IsNull()) {
-#ifdef STEPAP209_DEB
+#ifdef OCCT_DEBUG
cout<<"Prod.IsNull()"<<endl;
#endif
return Standard_False;
}
Handle(StepShape_ShapeRepresentation) AnaSR = IdealShape(Prod);
if(AnaSR.IsNull()) {
-#ifdef STEPAP209_DEB
+#ifdef OCCT_DEBUG
cout<<"AnaSR.IsNull()"<<endl;
#endif
return Standard_False;
{
// WARNING : the field is redefined.
// field set up forbidden.
-#ifdef STEPBASIC_DEB
+#ifdef OCCT_DEBUG
cout << "Field is redefined, SetUp Forbidden" << endl;
#endif
}
thescopenext = new TColStd_HArray1OfInteger (1,nb); thescopenext->Init(0);
}
else if (thescopenext->Value(numin) != 0) {
-#ifdef STEPDATA_DEB
+#ifdef OCCT_DEBUG
cout << "StepWriter : SetScope (scope : " << numscope << " entity : "
<< numin << "), Entity already in a Scope"<<endl;
#endif
#include <Message_Messenger.hxx>
#include <Message.hxx>
+#ifdef OCCT_DEBUG
#define CHRONOMESURE
#ifdef CHRONOMESURE
# include <OSD_Timer.hxx>
#endif
+#endif
// ## ## ## ## ON SAURA AU MOINS TRAITER UndefinedEntity ## ## ## ##
if (stepread () != 0) { lir_file_fin(3); stepread_endinput (newin,ficnom); return 1; }
}
catch (Standard_Failure) {
+#ifdef OCCT_DEBUG
sout << " ... Exception Raised while reading Step File : " << ficnom << ":\n" << endl;
sout << Standard_Failure::Caught()->GetMessageString();
sout << " ..." << endl;
+#endif
lir_file_fin(3);
stepread_endinput (newin,ficnom);
return 1;
void StepFile_Interrupt (char* mess)
{
+#ifdef OCCT_DEBUG
Handle(Message_Messenger) sout = Message::DefaultMessenger();
sout << " **** StepFile Error : " << mess << " ****" << endl;
+#endif
checkread->AddFail(mess);
}
{
if (i == 1) aFMulDiff = aCurrentVal - Deg - 1;
if (i == NbKnots) aLMulDiff = aCurrentVal - Deg - 1;
-#ifdef STEPTOGEOM_DEB
+#ifdef OCCT_DEBUG
cout << "\nWrong multiplicity " << aCurrentVal << " on " << i
<< " knot!" << "\nChanged to " << Deg + 1 << endl;
#endif
((SumMult - UMult.Value(1))== NUPoles)) {
shouldBeUPeriodic = Standard_True;
}
- /*else { // --- What is that ??? ---
- shouldBeUPeriodic = Standard_False;
-#ifdef DEBUG
- cout << "Strange BSpline Surface Descriptor" << endl;
-#endif
- }*/
// --- V Periodic ? ---
((SumMult - VMult.Value(1)) == NVPoles)) {
shouldBeVPeriodic = Standard_True;
}
- /*else { // --- What is that ??? ---
- shouldBeVPeriodic = Standard_False;
-#ifdef DEBUG
- cout << "Strange BSpline Surface Descriptor" << endl;
-#endif
- }*/
if (SS->IsKind(STANDARD_TYPE(StepGeom_BSplineSurfaceWithKnotsAndRationalBSplineSurface))) {
const Handle(TColStd_HArray2OfReal)& aWeight = BSR->WeightsData();
}
catch(Standard_Failure) {
// ShapeTool_DB ?
-#ifdef STEPTOGEOM_DEB //:s5
+#ifdef OCCT_DEBUG //:s5
cout<<"Warning: StepToGeom_MakeSurface: Exception:";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
if (theCurve->IsKind(STANDARD_TYPE(Geom_BoundedCurve)) && !theCurve->IsClosed()) {
if (w1 < cf) {
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout << "Update Edge First Parameter to Curve First Parameter" << endl;
#endif
w1 = cf;
}
else if (w1 > cl) {
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout << "Update Edge First Parameter to Curve Last Parameter" << endl;
#endif
w1 = cl;
}
if (w2 < cf) {
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout << "Update Edge Last Parameter to Curve First Parameter" << endl;
#endif
w2 = cf;
}
else if (w2 > cl) {
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout << "Update Edge Last Parameter to Curve Last Parameter" << endl;
#endif
w2 = cl;
if ( theCurve->Value(w1).Distance(theCurve->Value(cf)) < preci ) w1 = cf;
if ( theCurve->Value(w2).Distance(theCurve->Value(cl)) < preci ) w2 = cl;
if ( w1 > w2 ) {
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning : parameter range of edge crossing non periodic curve origin" << endl;
#endif
Standard_Real tmp = w1;
// illegal sur une courbe fermee non periodique
// on inverse quand meme les parametres !!!!!!
else {
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning : parameter range of edge crossing non periodic curve origin" << endl;
#endif
Standard_Real tmp = w1;
}
//abv 15.03.00 #72 bm1_pe_t4 protection of exceptions in draw
else if ( w1 > w2 ) {
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: parameter range is bad; curve reversed" << endl;
#endif
w1 = theCurve->ReversedParameter ( w1 );
}
}
else {
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout << "UpdateParam3d Failed" << endl;
cout << " - Curve Type : " << theCurve->DynamicType() << endl;
cout << " - Param 1 : " << w1 << endl;
#endif
//abv 15.03.00 #72 bm1_pe_t4 protection of exceptions in draw
if ( w1 > w2 ) {
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: parameter range is bad; curve reversed" << endl;
#endif
w1 = theCurve->ReversedParameter ( w1 );
void StepToTopoDS_Tool::BindVertex(const Handle(StepGeom_CartesianPoint)& P, const TopoDS_Vertex& V)
{
myVertexMap.Bind(P, V);
-#ifdef DEBUG
+#ifdef OCCT_DEBUG
TransferBRep::SetShapeResult (myTransProc,P,V);
#endif
}
}
}
catch(Standard_Failure) {
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: StepToTopoDS_TranslateCompositeCurve: Exception: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
}
}
catch(Standard_Failure) {
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: StepToTopoDS_TranslateCompositeCurve: Exception: ";
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
const Handle(Geom_Curve)& myCurve,
const TopoDS_Vertex& V1,
const TopoDS_Vertex& V2,
- const Standard_Real& /*U1*/,
- const Standard_Real& /*U2*/,
+ const Standard_Real& U1,
+ const Standard_Real& U2,
StepToTopoDS_Tool& aTool,
const Handle(StepShape_TopologicalRepresentationItem)& /*tobind*/)
{
+ (void)U1, (void)U2; // avoid compiler warning
+
Handle(Transfer_TransientProcess) TP = aTool.TransientProcess();
// if (!myCurve.IsNull() && !tobind.IsNull()) {
// TransferBRep::SetShapeResult
// (TP,tobind, MakeEdge(myCurve,V1,V2,U1,U2,BRepAPI::Precision()) );
// aTool.Bind (tobind,E); SURTOUT PAS : noter pour debug/erreur
// }
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout << "------------------------------------" << endl;
cout << "MakeEdge Error : " << ME.Error()<<" - ";
#endif
TP->AddFail(orig," Line through identic Points");
break;
}
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout << "Original Type : " << orig->DynamicType() << endl;
cout << "3D Curve Type : " << myCurve->DynamicType() << endl;
cout << "First Parameter : " << U1 << endl;
if (w1 == w2) {
RemoveSinglePCurve(myEdge,aFace);
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout<<"Removing pcuve w1=w2"<<endl;
#endif
continue;
Standard_Boolean ThereIsLikeSeam = Standard_False;
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout << " Processing Edge :" << j << endl;
#endif
}
else {
RemoveSinglePCurve(edge, Face);
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout <<"Removing after prj"<<endl;
#endif
}
for (Standard_Integer i = 1; i <= NbBnd; i ++) {
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout << " Processing Wire : " << i << endl;
#endif
FaceBound = FS->BoundsValue(i);
else {
// Type not yet implemented or non sens
TP->AddFail(Loop," Type of loop not yet implemented");
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout << Loop->DynamicType() << endl;
#endif
continue;
Message_ProgressSentry PS ( TP->GetProgress(), "Face", 0, NbFc, 1 );
for (Standard_Integer i=1; i<=NbFc && PS.More(); i++, PS.Next()) {
-#ifdef STEPTOTOPODS_DEB
+#ifdef OCCT_DEBUG
cout << "Processing Face : " << i << endl;
#endif
StepFace = CFS->CfsFacesValue(i);
}
catch(Standard_Failure)
{
-#ifdef STLTRANSFER_DEB
+#ifdef OCCT_DEBUG
cout << "Fail in StlTransfer::BuildIncrementalMesh" << endl;
#endif
}
aFile.Close();
break;
}
-#ifdef DATATYPE_MIGRATION_DEB
+#ifdef OCCT_DEBUG
cout << "Storage_Sheme:: Line: = " << aLine <<endl;
#endif
TCollection_AsciiString aKey, aValue;
}
}
}
-#ifdef DATATYPE_MIGRATION_DEB
+#ifdef OCCT_DEBUG
cout << "Storage_Sheme:: aDataMap.Size = " << aDMap.Extent() <<endl;
#endif
}
newName.Clear();
newName = aDMap.Find(oldName);
aMigration = Standard_True;
-#ifdef DATATYPE_MIGRATION_DEB
+#ifdef OCCT_DEBUG
cout << " newName = " << newName << endl;
#endif
}
#ifdef DATATYPE_MIGRATION
TCollection_AsciiString newName;
if(CheckTypeMigration(typeName, newName)) {
-#ifdef DATATYPE_MIGRATION_DEB
+#ifdef OCCT_DEBUG
cout << "CheckTypeMigration:OldType = " <<typeName << " Len = "<<typeName.Length()<<endl;
cout << "CheckTypeMigration:NewType = " <<newName << " Len = "<< newName.Length()<<endl;
#endif
struct tm *nowstruct;
if (time(&nowbin) == (time_t)-1)
{
-#ifdef STORAGE_DEB
+#ifdef OCCT_DEBUG
cerr << "Storage ERROR : Could not get time of day from time()" << endl;
#endif
}
if (strftime(nowstr, SLENGTH, "%m/%d/%Y", nowstruct) == (size_t) 0)
{
-#ifdef STORAGE_DEB
+#ifdef OCCT_DEBUG
cerr << "Storage ERROR : Could not get string from strftime()" << endl;
#endif
}
void TDF_Attribute::RemoveBackup()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (myBackup.IsNull())
Standard_DomainError::Raise("Impossible to remove a nonexistent backup.");
#endif
}
//=======================================================================
-#ifdef TDF_DEB
+#ifdef OCCT_DEBUG
static void PrintEntry(const TDF_Label& label, const Standard_Boolean allLevels)
{
TCollection_AsciiString entry;
!TDF_Tool::IsSelfContained(mySL)) return;
#endif
else {
-#ifdef TDF_DEB
+#ifdef OCCT_DEBUG
cout << "THE SAME Data" <<endl;
#endif
}
for (TDF_MapIteratorOfAttributeMap attMItr(myMapOfExt);attMItr.More(); attMItr.Next()) {
Handle(TDF_Attribute) att = attMItr.Key();
myRT->SetRelocation(att, att);
-#ifdef TDF_DEB
+#ifdef OCCT_DEBUG
PrintEntry(att->Label(), Standard_True);
#endif
}
#define BUC60879
-#ifdef DEB_DELTA
+#ifdef OCCT_DEBUG_DELTA
#define TDF_Data_DebugModified(ACTION) \
cout<<"After "<<ACTION<<" #"<<myTransaction+1<<", DF "<<this<<" had "<<myNbTouchedAtt<<" attribute(s) touched. Time = "<<myTime<<endl; \
if (!myTransaction) { \
#define TDF_Data_DebugModified(ACTION)
#endif
-#ifdef DEB_DELTA_CREATION
+#ifdef OCCT_DEBUG_DELTA_CREATION
#define TDF_DataDebugDeltaCreation(DELTATYPE) \
{ \
TCollection_AsciiString entry; \
Handle(TDF_Delta) delta;
if (myTransaction>0) {
if (withDelta) delta = new TDF_Delta();
-#ifdef DEB_DELTA
+#ifdef OCCT_DEBUG_DELTA
cout<<"TDF_Data::Begin Commit #"<<myTransaction<<endl;
#endif
#ifdef TDF_DATA_COMMIT_OPTIMIZED
if (withDelta) {
if (!delta->IsEmpty()) {
delta->Validity(myTimes.First(),myTime);
-#ifdef DEB_DELTA
+#ifdef OCCT_DEBUG_DELTA
if (myTransaction == 0) {
cout<<"TDF_Data::Commit generated this delta in t=0:"<<endl;
delta->Dump(cout);
}
#endif
}
-#ifdef DEB_DELTA
+#ifdef OCCT_DEBUG_DELTA
else {
if (myTransaction == 0)
cout<<"TDF_Data::Commit generated NO delta."<<endl;
if (!aDelta.IsNull ()) {
if (aDelta->IsApplicable(myTime)) {
if (withDelta) OpenTransaction();
-#ifdef DEB_DELTA
+#ifdef OCCT_DEBUG_DELTA
cout<<"TDF_Data::Undo applies this delta:"<<endl;
aDelta->Dump(cout);
#endif
if (withDelta) {
newDelta = CommitTransaction(Standard_True);
newDelta->Validity(aDelta->EndTime(),aDelta->BeginTime());
-#ifdef DEB_DELTA
+#ifdef OCCT_DEBUG_DELTA
cout<<"TDF_Data::Undo, after validity correction, Delta is now available from time \t#"<<newDelta->BeginTime()<<" to time \t#"<<newDelta->EndTime()<<endl;
#endif
}
#include <TDF_ListIteratorOfLabelList.hxx>
#include <TDF_MapIteratorOfLabelMap.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <Standard_ConstructionError.hxx>
#endif
}
if (!noDeadLock) {
-#ifdef TDF_DEB
+#ifdef OCCT_DEBUG
if (before) cout<<"Before"; else cout<<"After";
cout<<"Undo(): dead lock between these attributes:"<<endl;
for (itr.Initialize(ADlist); itr.More(); itr.Next()) {
{
TDF_LabelMap labMap;
// If <aLabelList> is not empty...
-#ifdef DEB_DELTA
+#ifdef OCCT_DEBUG_DELTA
Standard_Boolean inList;
if (aLabelList.Extent() > 0) cout<<"Previously added as modified label(s) ";
#endif
for (TDF_ListIteratorOfLabelList it1(aLabelList);
it1.More(); it1.Next()) {
-#ifdef DEB_DELTA
+#ifdef OCCT_DEBUG_DELTA
const TDF_Label& lab1 = it1.Value();
inList = labMap.Add(lab1);
if (!inList) {
}
#endif
}
-#ifdef DEB_DELTA
+#ifdef OCCT_DEBUG_DELTA
cout<<endl;
#endif
// New labels to add.
-#ifdef DEB_DELTA
+#ifdef OCCT_DEBUG_DELTA
if (myAttDeltaList.Extent() > 0) cout<<"New added as modified label(s) ";
#endif
for (TDF_ListIteratorOfAttributeDeltaList it2(myAttDeltaList);
it2.More();
it2.Next()) {
-#ifdef DEB_DELTA
+#ifdef OCCT_DEBUG_DELTA
const TDF_Label& lab1 = it2.Value()->Label();
inList = labMap.Add(lab1);
if (!inList) {
}
#endif
}
-#ifdef DEB_DELTA
+#ifdef OCCT_DEBUG_DELTA
cout<<endl;
#endif
// Undo = Resume.
Label().ResumeAttribute(Attribute());
Attribute()->mySavedTransaction = 0;
-#ifdef TDF_DEB
+#ifdef OCCT_DEBUG
cout<<"Resume attribute"<<endl;
#endif
}
{
// Undo = Forget.
Label().ForgetAttribute (Attribute());
-#ifdef TDF_DEB
+#ifdef OCCT_DEBUG
cout<<"Forget attribute"<<endl;
#endif
}
const TDF_LabelNode* lp1 = aLabel.myLabelNode;
TDF_LabelNode* lp2 = myLabelNode;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ((lp1 == NULL) || (lp2 == NULL))
Standard_NullObject::Raise("A null label has no ancestor nor descendant.");
#endif
myData (aDataPtr)
#endif
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
myDebugEntry = '0';
#endif
}
myData = aFather -> Data();
#endif
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
myDebugEntry = myFather->myDebugEntry;
myDebugEntry += ':';
myDebugEntry += aTag;
#ifdef KEEP_LOCAL_ROOT
TDF_Data * myData;
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
TCollection_AsciiString myDebugEntry;
#endif
};
#include <TDF_Transaction.ixx>
#undef DEB_TRANSACTION
-#ifdef DEB
+#ifdef OCCT_DEBUG
#define DEB_TRANSACTION
#endif
#undef DEB_TRANSACTION_DUMP
Standard_Integer TDF_Transaction::Open()
{
-#ifdef DEB_TRANSACTION
+#ifdef OCCT_DEBUG_TRANSACTION
cout<<"Transaction "<<myName<<" opens #"<<myDF->Transaction()+1<<endl;
#endif
if (IsOpen())
Handle(TDF_Delta) TDF_Transaction::Commit(const Standard_Boolean withDelta)
{
-#ifdef DEB_TRANSACTION
+#ifdef OCCT_DEBUG_TRANSACTION
cout<<"Transaction "<<myName<<" commits ";
#endif
Handle(TDF_Delta) delta;
if (IsOpen()) {
-#ifdef DEB_TRANSACTION
+#ifdef OCCT_DEBUG_TRANSACTION
cout<<"from #"<<myDF->Transaction()<<" until #"<<myUntilTransaction<<" while current is #"<<myDF->Transaction()<<endl;
#endif
-#ifdef DEB_TRANSACTION_DUMP
+#ifdef OCCT_DEBUG_TRANSACTION_DUMP
cout<<"DF before commit"<<endl;
TDF_Tool::DeepDump(cout,myDF);
#endif
Standard_Integer until = myUntilTransaction;
myUntilTransaction = 0;
delta = myDF->CommitUntilTransaction(until, withDelta);
-#ifdef DEB_TRANSACTION_DUMP
+#ifdef OCCT_DEBUG_TRANSACTION_DUMP
cout<<"DF after commit"<<endl;
TDF_Tool::DeepDump(cout,myDF);
#endif
}
-#ifdef DEB_TRANSACTION
+#ifdef OCCT_DEBUG_TRANSACTION
else cout<<"but this transaction is not open!"<<endl;
#endif
return delta;
void TDF_Transaction::Abort()
{
if (IsOpen()) {
-#ifdef DEB_TRANSACTION
+#ifdef OCCT_DEBUG_TRANSACTION
cout<<"Transaction "<<myName<<" aborts from #"<<myDF->Transaction()<<" until #"<<myUntilTransaction<<" while current is #"<<myDF->Transaction()<<endl;
#endif
-#ifdef DEB_TRANSACTION_DUMP
+#ifdef OCCT_DEBUG_TRANSACTION_DUMP
cout<<"DF before abort"<<endl;
TDF_Tool::DeepDump(cout,myDF);
#endif
myDF->AbortUntilTransaction(myUntilTransaction);
myUntilTransaction = 0;
-#ifdef DEB_TRANSACTION_DUMP
+#ifdef OCCT_DEBUG_TRANSACTION_DUMP
cout<<"DF after abort"<<endl;
TDF_Tool::DeepDump(cout,myDF);
#endif
#include <TColStd_ListIteratorOfListOfInteger.hxx>
#include <TDF_AttributeIterator.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#define MAXUP 1000
#endif
//=======================================================================
Handle(TColStd_HArray1OfByte) Arr1, Arr2;
Arr1 = OldAtt->InternalArray();
Arr2 = CurrAtt->InternalArray();
-#ifdef DEB_DELTA
+#ifdef OCCT_DEBUG_DELTA
if(Arr1.IsNull())
cout <<"DeltaOnModificationOfByteArray:: Old ByteArray is Null" <<endl;
if(Arr2.IsNull())
}
}
OldAtt->RemoveArray();
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
if(OldAtt->InternalArray().IsNull())
cout << "BackUp Arr is Nullified" << endl;
#endif
Handle(TDF_Attribute) TDFAttribute = Attribute();
Handle(TDataStd_ByteArray) BackAtt = (*((Handle(TDataStd_ByteArray)*)&TDFAttribute));
if(BackAtt.IsNull()) {
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << "DeltaOnModificationOfByteArray::Apply: OldAtt is Null" <<endl;
#endif
return;
}
if(aCurAtt.IsNull()) {
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << "DeltaOnModificationOfByteArray::Apply: CurAtt is Null" <<endl;
#endif
return;
byteArr->SetValue(i, BArr->Value(i));
if(!myIndxes.IsNull() && !myValues.IsNull())
for(i = 1; i <= myIndxes->Upper();i++) {
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << "i = " << i << " myIndxes->Upper = " << myIndxes->Upper() << endl;
cout << "myIndxes->Value(i) = " << myIndxes->Value(i) << endl;
cout << "myValues->Value(i) = " << myValues->Value(i) << endl;
aCurAtt->myValue = byteArr;
}
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << " << Array Dump after Delta Apply >>" <<endl;
Handle(TColStd_HArray1OfByte) BArr2 = aCurAtt->InternalArray();
for(i=BArr2->Lower(); i<=BArr2->Upper() && i<= MAXUP;i++)
#include <TColStd_ListIteratorOfListOfInteger.hxx>
#include <TDF_AttributeIterator.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#define MAXUP 1000
#endif
//=======================================================================
Handle(TColStd_HArray1OfExtendedString) Arr1, Arr2;
Arr1 = OldAtt->Array();
Arr2 = CurrAtt->Array();
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
if(Arr1.IsNull())
cout <<"DeltaOnModificationOfExtStringArray:: Old IntArray is Null" <<endl;
if(Arr2.IsNull())
}
}
OldAtt->RemoveArray();
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
if(OldAtt->Array().IsNull())
cout << "BackUp Arr is Nullified" << endl;
#endif
Handle(TDF_Attribute) TDFAttribute = Attribute();
Handle(TDataStd_ExtStringArray) BackAtt = (*((Handle(TDataStd_ExtStringArray)*)&TDFAttribute));
if(BackAtt.IsNull()) {
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << "DeltaOnModificationOfExtStringArray::Apply: OldAtt is Null" <<endl;
#endif
return;
}
if(aCurAtt.IsNull()) {
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << "DeltaOnModificationOfExtStringArray::Apply: CurAtt is Null" <<endl;
#endif
return;
strArr->SetValue(i, aStrArr->Value(i));
if(!myIndxes.IsNull() && !myValues.IsNull())
for(i = 1; i <= myIndxes->Upper();i++) {
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << "i = " << i << " myIndxes->Upper = " << myIndxes->Upper() << endl;
cout << "myIndxes->Value(i) = " << myIndxes->Value(i) << endl;
cout << "myValues->Value(i) = " << myValues->Value(i) << endl;
}
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << " << Array Dump after Delta Apply >>" <<endl;
Handle(TColStd_HArray1OfExtendedString) aStrArr2 = aCurAtt->Array();
for(i=aStrArr2->Lower(); i<= aStrArr2->Upper() && i<= MAXUP;i++)
#include <TColStd_ListOfInteger.hxx>
#include <TColStd_ListIteratorOfListOfInteger.hxx>
#include <TDF_AttributeIterator.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#define MAXUP 1000
#endif
//=======================================================================
Handle(TColStd_HArray1OfInteger) Arr1, Arr2;
Arr1 = OldAtt->Array();
Arr2 = CurrAtt->Array();
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
if(Arr1.IsNull())
cout <<"DeltaOnModificationOfIntArray:: Old IntArray is Null" <<endl;
if(Arr2.IsNull())
}
}
OldAtt->RemoveArray();
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
if(OldAtt->Array().IsNull())
cout << "BackUp Arr is Nullified" << endl;
#endif
Handle(TDF_Attribute) TDFAttribute = Attribute();
Handle(TDataStd_IntegerArray) BackAtt = (*((Handle(TDataStd_IntegerArray)*)&TDFAttribute));
if(BackAtt.IsNull()) {
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << "DeltaOnModificationOfIntArray::Apply: OldAtt is Null" <<endl;
#endif
return;
}
if(aCurAtt.IsNull()) {
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << "DeltaOnModificationOfIntArray::Apply: CurAtt is Null" <<endl;
#endif
return;
intArr->SetValue(i, IntArr->Value(i));
if(!myIndxes.IsNull() && !myValues.IsNull())
for(i = 1; i <= myIndxes->Upper();i++) {
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << "i = " << i << " myIndxes->Upper = " << myIndxes->Upper() << endl;
cout << "myIndxes->Value(i) = " << myIndxes->Value(i) << endl;
cout << "myValues->Value(i) = " << myValues->Value(i) << endl;
aCurAtt->myValue = intArr;
}
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << " << Array Dump after Delta Apply >>" <<endl;
Handle(TColStd_HArray1OfInteger) IntArr2 = aCurAtt->Array();
for(i=IntArr2->Lower(); i<=IntArr2->Upper() && i <= MAXUP;i++)
#include <TColStd_HPackedMapOfInteger.hxx>
#include <TColStd_MapIteratorOfPackedMapOfInteger.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#define MAXUP 1000
#endif
Handle(TColStd_HPackedMapOfInteger) aMap1, aMap2;
aMap1 = OldAtt->GetHMap();
aMap2 = CurrAtt->GetHMap();
-#ifdef DEB_disable
+#ifdef OCCT_DEBUG_disable
if (aMap1.IsNull())
cout <<"DeltaOnModificationOfIntPackedMap:: Old Map is Null" <<endl;
if (aMap2.IsNull())
Handle(TDF_Attribute) aTDFAttribute = Attribute();
Handle(TDataStd_IntPackedMap) aBackAtt = (*((Handle(TDataStd_IntPackedMap)*)&aTDFAttribute));
if(aBackAtt.IsNull()) {
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << "DeltaOnModificationOfIntPAckedMap::Apply: OldAtt is Null" <<endl;
#endif
return;
}
if(aCurAtt.IsNull()) {
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << "DeltaOnModificationOfIntAPckedMAp::Apply: CurAtt is Null" <<endl;
#endif
return;
IntMap->ChangeMap().Unite(myAddition->Map());
}
-#ifdef DEB_disable
+#ifdef OCCT_DEBUG_disable
cout << " << Map Dump after Delta Apply >>" <<endl;
Handle(TColStd_HPackedMapOfInteger) aIntMap = aCurAtt->GetHMap();
TColStd_MapIteratorOfPackedMapOfInteger it(aIntMap->Map());
#include <TColStd_ListOfInteger.hxx>
#include <TColStd_ListIteratorOfListOfInteger.hxx>
#include <TDF_AttributeIterator.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#define MAXUP 1000
#endif
//=======================================================================
Handle(TColStd_HArray1OfReal) Arr1, Arr2;
Arr1 = OldAtt->Array();
Arr2 = CurrAtt->Array();
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
if(Arr1.IsNull())
cout <<"DeltaOnModificationOfRealArray:: Old Array is Null" <<endl;
if(Arr2.IsNull())
}
}
OldAtt->RemoveArray();
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
if(OldAtt->Array().IsNull())
cout << "BackUp Arr is Nullified" << endl;
#endif
Handle(TDF_Attribute) TDFAttribute = Attribute();
Handle(TDataStd_RealArray) BackAtt = (*((Handle(TDataStd_RealArray)*)&TDFAttribute));
if(BackAtt.IsNull()) {
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << "DeltaOnModificationOfRealArray::Apply: OldAtt is Null" <<endl;
#endif
return;
}
if(aCurAtt.IsNull()) {
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << "DeltaOnModificationOfRealArray::Apply: CurAtt is Null" <<endl;
#endif
return;
realArr->SetValue(i, aRealArr->Value(i));
if(!myIndxes.IsNull() && !myValues.IsNull())
for(i = 1; i <= myIndxes->Upper();i++) {
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << "i = " << i << " myIndxes->Upper = " << myIndxes->Upper() << endl;
cout << "myIndxes->Value(i) = " << myIndxes->Value(i) << endl;
cout << "myValues->Value(i) = " << myValues->Value(i) << endl;
}
-#ifdef TDATASTD_DEB
+#ifdef OCCT_DEBUG
cout << " << RealArray Dump after Delta Apply >>" <<endl;
Handle(TColStd_HArray1OfReal) aRArr = aCurAtt->Array();
for(i=aRArr->Lower(); i<=aRArr->Upper() && i <= MAXUP;i++)
}
break;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
else {
Standard_Failure::Raise("curve Null dans TDataXtd_Geometry");
}
type = TDataXtd_PLANE;
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
else {
Standard_Failure::Raise("surface Null dans TDataXtd_Geometry");
}
}
}
status = GetRetrieveStatus();
-#ifdef TDOCSTD_DEB
+#ifdef OCCT_DEBUG
cout<<"TDocStd_Application::Open(): The status = "<<status<<endl;
#endif
return status;
if(storer.StoreStatus() == PCDM_SS_OK)
D->SetSaved();
#ifdef BUC60867
-#ifdef TDOCSTD_DEB
+#ifdef OCCT_DEBUG
cout<<"TDocStd_Application::SaveAs(): The status = "<<storer.StoreStatus()<<endl;
#endif
return storer.StoreStatus();
status = PCDM_SS_Failure;
}
#ifdef BUC60867
-#ifdef TDOCSTD_DEB
+#ifdef OCCT_DEBUG
cout<<"TDocStd_Application::Save(): The status = "<<status<<endl;
#endif
return status;
void TDocStd_Document::NewCommand()
{
-#ifdef DEB_TRANS
+#ifdef OCCT_DEBUG_TRANS
if (myUndoTransaction.IsOpen() && myData->Transaction() > 1) {
Standard_DomainError::Raise ("NewCommand : many open transactions");
}
CommitTransaction();
OpenTransaction();
-#ifdef DEB_TRANS
+#ifdef OCCT_DEBUG_TRANS
cout<<"End NewCommand"<<endl;
#endif
}
// Apply the Undo
// should test the applicability before.
-#ifdef DEB_DELTA
+#ifdef OCCT_DEBUG_DELTA
cout<<"DF before Undo =================================="<<endl; TDF_Tool::DeepDump(cout,myData);
#endif
Handle(TDF_Delta) D = myData->Undo(myUndos.Last(),Standard_True);
#ifdef BUC60836
D->SetName(myUndos.Last()->Name());
#endif
-#ifdef DEB_DELTA
+#ifdef OCCT_DEBUG_DELTA
cout<<"DF after Undo =================================="<<endl; TDF_Tool::DeepDump(cout,myData);
#endif
// Push the redo
myData->AllowModification(Standard_True);
// Apply the Redo
-#ifdef DEB_DELTA
+#ifdef OCCT_DEBUG_DELTA
cout<<"DF before Redo =================================="<<endl; TDF_Tool::DeepDump(cout,myData);
#endif
Handle(TDF_Delta) D = myData->Undo(myRedos.First(),Standard_True);
#ifdef BUC60836
D->SetName(myRedos.First()->Name());
#endif
-#ifdef DEB_DELTA
+#ifdef OCCT_DEBUG_DELTA
cout<<"DF after Redo =================================="<<endl; TDF_Tool::DeepDump(cout,myData);
#endif
// Push the redo of the redo as an undo (got it !)
void TDocStd_MultiTransactionManager::OpenCommand() {
if (myOpenTransaction) {
-#ifdef TDOCSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TDocStd_MultiTransactionManager::OpenCommand(): "
"Can't start new application transaction while a "
"previous one is not commited or aborted" << endl;
#include <Standard_NoSuchObject.hxx>
#include <TColStd_MapIteratorOfMapOfInteger.hxx>
-#ifdef DEB
-#include <TDataStd_Name.hxx>
-#endif // DEB
-
//=======================================================================
//function : NewFunction
//purpose : Static method to create a new function.
const TDF_Label& L = itrm.Key2();
TFunction_IFunction iFunction(L);
-#ifdef DEB
- /*
- TCollection_AsciiString fname;
- Handle(TDataStd_Name) name;
- if (L.FindAttribute(TDataStd_Name::GetID(), name))
- {
- fname = name->Get();
- }
- else if (L.Father().FindAttribute(TDataStd_Name::GetID(), name))
- {
- fname = name->Get();
- }
- */
-#endif // DEB
-
// Take the driver.
Handle(TFunction_Driver) driver = iFunction.GetDriver();
const TDF_Label& L = itrm.Key2();
TFunction_IFunction iFunction(L);
-#ifdef DEB
- /*
- TCollection_AsciiString fname;
- Handle(TDataStd_Name) name;
- if (L.FindAttribute(TDataStd_Name::GetID(), name))
- {
- fname = name->Get();
- }
- else if (L.Father().FindAttribute(TDataStd_Name::GetID(), name))
- {
- fname = name->Get();
- }
- */
-#endif // DEB
-
// Take the driver.
Handle(TFunction_Driver) driver = iFunction.GetDriver();
continue;
const TDF_LabelList& anotherRes = itrd.Value();
-#ifdef DEB
- /*
- TCollection_AsciiString afname;
- Handle(TDataStd_Name) aname;
- if (anotherL.FindAttribute(TDataStd_Name::GetID(), aname))
- {
- afname = aname->Get();
- }
- else if (anotherL.Father().FindAttribute(TDataStd_Name::GetID(), aname))
- {
- afname = aname->Get();
- }
- */
-#endif // DEB
-
for (itrl.Initialize(anotherRes); itrl.More(); itrl.Next())
{
if (argsMap.Contains(itrl.Value()))
#include <TNaming_TranslateTool.hxx>
#include <TopLoc_Datum3D.hxx>
-#define BUC60862
-#ifdef DEB
-//#define MDTV_DEB
-//#define MDTV_DEB_FSET
-#endif
-#ifdef MDTV_DEB
-#include <BRepTools.hxx>
-#include <TCollection_AsciiString.hxx>
-#include <TopTools_DataMapIteratorOfDataMapOfOrientedShapeShape.hxx>
-static void WriteS(const TopoDS_Shape& shape,
- const Standard_CString filename)
-{
- char buf[256];
- if(strlen(filename) > 256) return;
-#if defined WNT
- strcpy_s (buf, filename);
-#else
- strcpy (buf, filename);
-#endif
- char* p = buf;
- while (*p) {
- if(*p == ':')
- *p = '-';
- p++;
- }
- ofstream save (buf);
- if(!save)
- cout << "File " << buf << " was not created: rdstate = " << save.rdstate() << endl;
- save << "DBRep_DrawableShape" << endl << endl;
- if(!shape.IsNull()) BRepTools::Write(shape, save);
- save.close();
-}
-#endif
//=======================================================================
//function : MapShapes
//purpose : TNaming
return s;
}
-#ifdef BUC60862
-
//=======================================================================
//function : Print
//purpose : Prints UsedShapes.
Standard_OStream& TNaming::Print (const TDF_Label& ACCESS, Standard_OStream& s) {
Handle(TNaming_UsedShapes) US;
if (!ACCESS.Root().FindAttribute(TNaming_UsedShapes::GetID(), US)) {
-#ifdef TNAMING_DEB
+#ifdef OCCT_DEBUG
cout<<"TNaming::Print(US): Bad access"<<endl;
#endif
return s;
return US->Dump(s);
}
-#endif
-
//=======================================================================
//function : BuildMapIn
//purpose :
else
aType = (TopAbs_ShapeEnum)(Context.ShapeType()+1);
for (TopExp_Explorer exp(Context,aType); exp.More(); exp.Next()) {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
if(!Map.Bind(exp.Current(), Context))
cout << "Not bind = " <<exp.Current().ShapeType() <<endl;
else
TopoDS_Iterator anIt(Context);
while(anIt.More()) {
const TopoDS_Shape& aKey = anIt.Value();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
if(!Map.Bind(aKey, C0))
cout << "Not bind = " <<aKey.ShapeType() <<endl;
#else
static void BuildMap(const TopoDS_Shape& Context, const TopAbs_ShapeEnum StopType,
TopTools_DataMapOfOrientedShapeShape& Map)
{
-#ifdef MDTV_DEB
- TCollection_AsciiString Nam("Cnt_");
- Standard_Integer i = 0;
-#endif
TopoDS_Iterator anIt(Context);
while(anIt.More()) {
const TopoDS_Shape& aKey = anIt.Value();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
if(!Map.Bind(aKey, Context))
cout << "Not bind = " <<aKey.ShapeType() <<endl;
#else
{
TopTools_DataMapOfOrientedShapeShape aMap;
BuildMap(Context, Selection.ShapeType(), aMap);
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
TopTools_DataMapIteratorOfDataMapOfOrientedShapeShape it (aMap);
for (;it.More();it.Next()) {
cout <<"FindUniqueContext: Key - " <<it.Key().ShapeType()<< " " << it.Key().TShape() <<" OR = " <<it.Key().Orientation() <<
aCmp = it.Value();
}
if(n == 1) {
-#ifdef MDTV_DEB_FSET
+#ifdef OCCT_DEBUG_FSET
cout << "FindUniqueContextSet: n = " << n <<endl;
#endif
return aCmp;
aResult.Orientation(aShape.Orientation());
aResult.Location(TNaming_CopyShape::Translate(aShape.Location(), aMap));
TrTool->UpdateShape(aShape,aResult);
-// #ifdef DEB
+// #ifdef OCCT_DEBUG
// if(fShar) {
// cout << "=== Shareable shape ===" << endl;
// cout << "aShape Type = " <<(aShape.TShape())->DynamicType() << endl;
#include <TDF_ChildIterator.hxx>
//#define MDTV_DEB_IDF
-#ifdef MDTV_DEB_IDF
+#ifdef OCCT_DEBUG_IDF
#include <TCollection_AsciiString.hxx>
#include <TDF_Tool.hxx>
#include <BRepTools.hxx>
AncestorIdentification(Localizer, Context);
return;
}
-#ifdef MDTV_DEB_IDF
+#ifdef OCCT_DEBUG_IDF
TCollection_AsciiString entry;
TDF_Tool::Entry(NS->Label(), entry);
cout << "Identifier:: (S) Label = " << entry <<endl;
if (!it.More()) return 0;
it.Next(); if (!it.More()) return 0;
//plus d un shape.
-#ifdef TNAMING_DEB
+#ifdef OCCT_DEBUG
cout <<"WARNING IMPORTED"<<endl;
#endif
return 1;
#include <TopExp_Explorer.hxx>
#define OCC351
-#ifdef DEB
+#ifdef OCCT_DEBUG
//#define MDTV_DEB_SC
-#ifdef MDTV_DEB_SC
+#ifdef OCCT_DEBUG_SC
#include <TDF_Tool.hxx>
#include <TDF_MapIteratorOfLabelMap.hxx>
const TopoDS_Shape& Context,
TopTools_MapOfShape& AncInFeature)
{
-#ifdef MDTV_DEB_SC
+#ifdef OCCT_DEBUG_SC
LWrite(S, "Localizer_S.brep");
LWrite(Context, "Localizer_Context.brep");
#endif
const TopTools_IndexedDataMapOfShapeListOfShape& Anc = Ancestors(Context,S.ShapeType());
if (Anc.Contains(S)) {
-#ifdef MDTV_DEB_SC
+#ifdef OCCT_DEBUG_SC
cout <<"Localizer: S in ancestor" <<endl;
#endif
const TopTools_ListOfShape& L = Anc.FindFromKey(S);
TopTools_ListIteratorOfListOfShape itL(L);
for (; itL.More(); itL.Next()) {
const TopoDS_Shape& AS = itL.Value();
-#ifdef MDTV_DEB_SC
+#ifdef OCCT_DEBUG_SC
LWrite(AS, "Localizer_AS.brep");
#endif
Handle(TNaming_NamedShape) NS = TNaming_Tool::NamedShape(AS,myUS->Label());
FindFeaturesInAncestors (AS, Context, AncInFeature);
}
else {
-#ifdef TNAMING_DEB
+#ifdef OCCT_DEBUG
cout <<" TNaming_Localization : Failure in the research of ancetres in TDF"<<endl;
#endif
}
}
else {
-#ifdef TNAMING_DEB
+#ifdef OCCT_DEBUG
cout <<" TNaming_Localization : S n est pas dans le solide"<<endl;//S is not in the solid
#endif
}
TopTools_IndexedDataMapOfShapeListOfShape& Anc = itA.Value();
TopExp_Explorer exp(In,TS);
-#ifdef TNAMING_DEB
+#ifdef OCCT_DEBUG
if (!exp.More()) cout <<" TNaming_Localization : Construction ancetres impossible"<<endl;
#endif
const TopoDS_Shape& SS = exp.Current();
TopExp::MapShapesAndAncestors(In, TS, TA, Anc);
}
else {
-#ifdef TNAMING_DEB
+#ifdef OCCT_DEBUG
cout <<" TNaming_Localization : Construction ancetres impossible"<<endl;
#endif
}
TopExp::MapShapesAndAncestors(In, TS, TA, myAncestors.First());
}
else {
-#ifdef TNAMING_DEB
+#ifdef OCCT_DEBUG
cout <<" TNaming_Localization : Construction ancetres impossible"<<endl;
#endif
}
return Standard_True;
}
}
-#ifdef TNAMING_DEB
+#ifdef OCCT_DEBUG
cout <<"TNaming_Localizer:IsNewInLab : Shape n est pas dans le Label."<<endl;
#endif
return Standard_False;
LBNS.Append (TNaming_Tool::NamedShape(it.Shape(),Lab));
}
else {
-#ifdef TNAMING_DEB
+#ifdef OCCT_DEBUG
cout <<"TNaming_Localizer: Shape modifie sans avoir ete cree"<<endl;
#endif
}
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
/*static Standard_Boolean StoreValid (const TopoDS_Shape& S,
const TopTools_MapOfShape& ShapeOfSol,
TopAbs_ShapeEnum TargetType,
const TopTools_IndexedDataMapOfShapeListOfShape& Anc = Ancestors(Sol,TS);
// szy 30.03.10 to process case when Candidate is of type Vertex
// if (TA == TopAbs_VERTEX) {
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
// cout <<"construction voisins des vertex impossible"<<endl;
//#endif
// return;
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
/*static void Explode (TNaming_ShapesSet& Res,
TopAbs_ShapeEnum TS,
TNaming_ShapesSet& ResGoodType)
TopoDS_Shape& SC)
{
-#ifdef MDTV_DEB_SC
+#ifdef OCCT_DEBUG_SC
LWrite(S, "FSC_Sel.brep"); LPrintEntry( NS->Label());
#endif
TopTools_ListOfShape aList;
Standard_Boolean found = 0;
for(;it.More();it.Next()) {
SC = it.Value();
-#ifdef MDTV_DEB_SC
+#ifdef OCCT_DEBUG_SC
LWrite(SC, "FSC_OldShape.brep");
#endif
if (SC.IsNull()) continue;
for (TopExp_Explorer exp(SC,S.ShapeType()); exp.More(); exp.Next()) {
if (exp.Current().IsSame(S)) {
found = 1;
-#ifdef MDTV_DEB_SC
+#ifdef OCCT_DEBUG_SC
cout << "Find Context shape = " << SC.TShape() << "ShapeType = " << SC.ShapeType() <<endl;
#endif
break;
if (!SC.IsNull()) {
Handle(TNaming_NamedShape) aNS = TNaming_Tool::NamedShape(SC,Father);
if (!aNS.IsNull()) {
-#ifdef MDTV_DEB_SC
+#ifdef OCCT_DEBUG_SC
cout << "FindShapeContext: ";LPrintEntry(aNS->Label());
#endif
if (aNS->Label().Father().FindAttribute(TNaming_NamedShape::GetID(),aNS)) {
TopoDS_Shape aShape;
-#ifdef MDTV_DEB_SC
+#ifdef OCCT_DEBUG_SC
LWriteNSOnLabel(aNS, "FSC");
#endif
TNaming_Iterator anIter(aNS->Label());
#define BUC60925
#define OCC352
-#ifdef DEB_DBGTOOLS_WRITE
+#ifdef OCCT_DEBUG_DBGTOOLS_WRITE
//#define OCC355
#define MDTV_DEB
#define MDTV_DEB_OR
#define MDTV_DEB_ARG
#define MDTV_DEB_SHELL
#endif
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
#include <TCollection_AsciiString.hxx>
#include <TDF_Tool.hxx>
#include <BRepTools.hxx>
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TCollection_AsciiString.hxx>
#include <TDF_Tool.hxx>
#include <TDF_ChildIterator.hxx>
cout << "LabelEntry = "<< entry << endl;
}
}
-#ifdef DEB_DBGTOOLS_WRITE
+#ifdef OCCT_DEBUG_DBGTOOLS_WRITE
//=======================================================================
static void DbgTools_Write(const TopoDS_Shape& shape,
const Standard_CString filename)
for (;it.More();it.Next()) {
const Handle(TNaming_NamedShape)& aNS = it.Value();
if(aNS.IsNull()) {
-#ifdef MDTV_DEB_ARG
+#ifdef OCCT_DEBUG_ARG
cout << "ValidArgs:: NS (Naming argument) is NULL" <<endl;
#endif
return Standard_False;
}
else
if(aNS->IsEmpty()) {
-#ifdef MDTV_DEB_ARG
+#ifdef OCCT_DEBUG_ARG
TCollection_AsciiString entry;
TDF_Tool::Entry(aNS->Label(), entry);
cout << "ValidArgs:: Empty NS, Label = " << entry <<endl;
}
else
if(!aNS->IsValid()) {
-#ifdef MDTV_DEB_ARG
+#ifdef OCCT_DEBUG_ARG
TCollection_AsciiString entry;
TDF_Tool::Entry(aNS->Label(), entry);
cout << "ValidArgs::Not valid NS Label = " << entry <<endl;
const TopoDS_Shape& S,
const Handle(TNaming_NamedShape)& Context)
{
-#ifdef MDTV_DEB_MODUN
+#ifdef OCCT_DEBUG_MODUN
if(!Context.IsNull())
PrintEntry(Context->Label());
#endif
Standard_Boolean found = Standard_False;
for (; it.More(); it.Next()) {
if (!it.Shape().IsNull()) {
-#ifdef MDTV_DEB_MODUN
+#ifdef OCCT_DEBUG_MODUN
if(!it.NamedShape().IsNull())
PrintEntry(it.NamedShape()->Label());
#endif
TopTools_MapOfShape& theMS)
{
-#ifdef MDTV_DEB_MODUN
+#ifdef OCCT_DEBUG_MODUN
DbgTools_WriteNSOnLabel(Target, "SMUntil_"); // Target <== generated
Standard_Integer i = 0;
TCollection_AsciiString aGen1("Gens_New_"), aGen2("Gented_Old_"), Und("_");
Standard_Boolean found = Standard_False;
for (TNaming_ListIteratorOfListOfNamedShape it(theListOfGenerators); it.More(); it.Next()) {
const Handle(TNaming_NamedShape)& aNS = it.Value();
-#ifdef MDTV_DEB_MODUN
+#ifdef OCCT_DEBUG_MODUN
i++;
Standard_Integer j = 0;
#endif
const TopoDS_Shape& S = itL.NewShape();
found = Standard_False;
-#ifdef MDTV_DEB_MODUN
+#ifdef OCCT_DEBUG_MODUN
j++;
Standard_Integer k = 0;
TCollection_AsciiString aNam1 = aGen1 + i + Und + j + ".brep";
TNaming_Iterator itC (Target);
for (; itC.More(); itC.Next()) { // <- generated
const TopoDS_Shape& OS = itC.OldShape();
-#ifdef MDTV_DEB_MODUN
+#ifdef OCCT_DEBUG_MODUN
k++;
TCollection_AsciiString aNam2 = aGen2 + i + Und + j + Und + k + ".brep";
DbgTools_Write(OS, aNam2.ToCString());
if (OS.IsSame(S)) {
theMS.Add(S);
found = Standard_True;
-#ifdef MDTV_DEB_MODUN
+#ifdef OCCT_DEBUG_MODUN
cout << aNam2 << " is Same with " << aNam1 <<endl;
#endif
break;
#endif
TNaming_NamingTool::BuildDescendants (Stop, Forbiden); // fills Forbidden from Stop
-#ifdef MDTV_DEB_GEN
+#ifdef OCCT_DEBUG_GEN
cout <<"Regenerating ModifUntil => ";
PrintEntry(L);
DbgTools_WriteNSOnLabel(Args.Last(), "ModifUntil-");
#endif
// all last modifications of the last argument
TNaming_NamingTool::CurrentShape (Valid, Forbiden,Args.Last(),MS);
-#ifdef MDTV_DEB_GEN
+#ifdef OCCT_DEBUG_GEN
Standard_Integer i(0);
TopTools_MapIteratorOfMapOfShape it(MS);
TCollection_AsciiString aNam("ModifUnti_MS_");
for (TopTools_MapIteratorOfMapOfShape itM(MS); itM.More(); itM.Next()) {
const TopoDS_Shape& S = itM.Key();
B.Select(S,S);
-#ifdef MDTV_DEB_GEN
+#ifdef OCCT_DEBUG_GEN
TCollection_AsciiString aName = aNam + ++i + ext;
DbgTools_Write(S, aName.ToCString()) ;
cout << aName.ToCString() << " TS = " << S.TShape()->This() <<endl;
TopTools_MapOfShape MS;
TDF_LabelMap Forbiden;
-#ifdef MDTV_DEB_INT
+#ifdef OCCT_DEBUG_INT
if(!Stop.IsNull() && !Stop->Get().IsNull()) {
DbgTools_Write(Stop->Get(), "Ints_Stop.brep");
PrintEntry(Stop->Label());
TNaming_NamingTool::BuildDescendants (Stop, Forbiden); // <==<1>
-#ifdef MDTV_DEB_INT
+#ifdef OCCT_DEBUG_INT
cout << "Intersection:: Valid Map: "<<endl;
PrintEntries(Valid);
cout << "Intersection:: Forbidden Map: "<<endl;
TopoDS_Shape CS = MakeShape(MS);
TNaming_ShapesSet S(CS,ShapeType); // <==<2>
aListOfAnc.Append(CS);
-#ifdef MDTV_DEB_INT
+#ifdef OCCT_DEBUG_INT
if(!CS.IsNull())
DbgTools_Write(CS, "Int_CS_1.brep");
Standard_Integer i=2;
TNaming_NamingTool::CurrentShape (Valid,Forbiden,it.Value(),MS);
CS = MakeShape(MS);
aListOfAnc.Append(CS);
-#ifdef MDTV_DEB_INT
+#ifdef OCCT_DEBUG_INT
TCollection_AsciiString aName = aNam + i++ + ext;
DbgTools_Write(CS, aName.ToCString()) ;
cout <<"Argument " << i << " at ";
TNaming_ShapesSet OS(CS,ShapeType);
S.Filter(OS); //<<===<3.2>
-#ifdef MDTV_DEB_INT
+#ifdef OCCT_DEBUG_INT
Standard_Integer j = 1;
TCollection_AsciiString aNam2("SSMap_"), aName3;
TopTools_MapIteratorOfMapOfShape itm(S.Map());
#endif
}
-#ifdef MDTV_DEB_INT
+#ifdef OCCT_DEBUG_INT
aNam = "Int_S_";
i =1;
#endif
break;
}
}
-#ifdef MDTV_DEB_INT
+#ifdef OCCT_DEBUG_INT
cout <<"Kept: indxE = " << indxE <<" maxENum = " << nbE << " indxW = " <<indxW << " nbW = " <<nbW<<endl;
#endif
Standard_Integer aNbW(0), aCaseW(0);
}
}
if(!isOK)
-#ifdef MDTV_DEB_INT
+#ifdef OCCT_DEBUG_INT
for (TopTools_MapIteratorOfMapOfShape itM(S.Map()); itM.More(); itM.Next(),i++) {
#else
for (TopTools_MapIteratorOfMapOfShape itM(S.Map()); itM.More(); itM.Next()) {
#endif
const TopoDS_Shape& S1 = itM.Key();
-#ifdef MDTV_DEB_INT
+#ifdef OCCT_DEBUG_INT
TCollection_AsciiString aName = aNam + i + ext;
DbgTools_Write(S1, aName.ToCString()) ;
#endif
if(isOr)
KeepInList(CS,ShapeType,aListS);
TNaming_ShapesSet S(CS,ShapeType);//fill internal map of shapeset by shapes of the specified type
-#ifdef MDTV_DEB_UNN
+#ifdef OCCT_DEBUG_UNN
TCollection_AsciiString entry;
TDF_Tool::Entry(it.Value()->Label(), entry);
TCollection_AsciiString Nam("Arg_");
#endif
it.Next();
for (; it.More(); it.Next()) {
-#ifdef MDTV_DEB_UNN
+#ifdef OCCT_DEBUG_UNN
TDF_Tool::Entry(it.Value()->Label(), entry);
#endif
MS.Clear();
TNaming_ShapesSet OS(CS,ShapeType);
S.Add(OS); //concatenate both shapesets
-#ifdef MDTV_DEB_UNN
+#ifdef OCCT_DEBUG_UNN
ii++;
TCollection_AsciiString aNm = Nam + entry + "_" + ii + ".brep";
DbgTools_Write(CS, aNm.ToCString());
MS.Clear();
TNaming_NamingTool::CurrentShape (Valid, Forbiden, CNS, MS);
aContext = MakeShape(MS);
-#ifdef MDTV_DEB_UNN
+#ifdef OCCT_DEBUG_UNN
TCollection_AsciiString anEntry;
TDF_Tool::Entry(ContextLabel, anEntry);
cout << "UNION: Context Label = " << anEntry << endl;
TopExp_Explorer anExpl(aContext, ShapeType);
for(;anExpl.More(); anExpl.Next())
aList.Append(anExpl.Current());
-#ifdef MDTV_DEB_UNN
+#ifdef OCCT_DEBUG_UNN
cout <<"UNION: ShapeType = " << ShapeType << " List ext = " << aList.Extent()<<endl;
TopAbs_ShapeEnum aTyp = TopAbs_SHAPE;
TopTools_MapIteratorOfMapOfShape it1 (S.Map());
TopTools_ListIteratorOfListOfShape itl(aList);
for(;itl.More();itl.Next()) {
aCand = itl.Value();
-#ifdef MDTV_DEB_UNN
+#ifdef OCCT_DEBUG_UNN
DbgTools_Write(aCand, "Cand.brep");
#endif
Standard_Integer num = S.Map().Extent();
}
TNaming_Builder B(L);
-#ifdef MDTV_DEB_UNN
+#ifdef OCCT_DEBUG_UNN
if(!ContextLabel.IsNull()) {
if(found) cout << "UNION: Shape is found in Context" <<endl;
else cout << "UNION: Shape is NOT found in Context" <<endl;
aCompoundBuilder.Add(aCompound,itL.Value());
}
TopoDS_Shape aShape = ShapeWithType(aCompound,ShapeType);
-#ifdef MDTV_DEB_UNN
+#ifdef OCCT_DEBUG_UNN
DbgTools_Write(aShape, "Union_Selected.brep");
DbgTools_Write(aCompound, "Union_Compound.brep");
#endif
#endif
TDF_Label LabelOfGeneration = Args.First()->Label();
-#ifdef MDTV_DEB_GEN
+#ifdef OCCT_DEBUG_GEN
DbgTools_Write(Args.First()->Get(), "Generated.brep") ;
#endif
// Nouvell valeurs des generateurs dans l attribut de generation
TNaming_ListOfNamedShape aGenerators;
aGenerators.Assign(Args);
aGenerators.RemoveFirst();
-#ifdef MDTV_DEB_GEN
+#ifdef OCCT_DEBUG_GEN
DbgTools_Write(aGenerators.First()->Get(), "Generators.brep") ;
#endif
SearchModifUntil (Valid, Args.First(), aGenerators, aMS);
L.FindAttribute(TNaming_Naming::GetID(),aNaming);
if(!aNaming.IsNull())
aSelection = aNaming->GetName().Shape();
-#ifdef MDTV_DEB_GEN
+#ifdef OCCT_DEBUG_GEN
DbgTools_Write(aSelection, "G_Selection.brep") ;
cout << "Generated::SearchModifUntil aMS.Extent() = " << aMS.Extent() <<endl;
DbgTools_Write(aMS, "SearchModifUntil_Result");
if(!anOldNS.IsNull())
aVer = anOldNS->Version();
-#ifdef MDTV_DEB_GEN
+#ifdef OCCT_DEBUG_GEN
Standard_Integer i = 0, j=1;
TCollection_AsciiString aNam2("Gen_New_");
TCollection_AsciiString aNam1("Gen_Old_");
TNaming_DataMapOfShapeMapOfShape aDM;
for (TopTools_MapIteratorOfMapOfShape itMS(aMS); itMS.More(); itMS.Next()) {
const TopoDS_Shape& OS = itMS.Key();
-#ifdef MDTV_DEB_GEN
+#ifdef OCCT_DEBUG_GEN
TCollection_AsciiString aName = aNam1 + ++i + ext;
DbgTools_Write(OS, aName.ToCString()) ;
Standard_Integer j=0;
if (itNew.Label() == LabelOfGeneration) {
aMapDM.Add(itNew.Shape());
aList.Append(itNew.Shape());//szy 21.10.03
-#ifdef MDTV_DEB_GEN
+#ifdef OCCT_DEBUG_GEN
TCollection_AsciiString aName = aNam2 + i + "_" + ++j + ext;
DbgTools_Write(itNew.Shape(), aName.ToCString()) ;
#endif
Standard_Boolean found = Standard_False;
TopoDS_Shape aShape = FindShape(aDM);
-#ifdef MDTV_DEB_GEN
+#ifdef OCCT_DEBUG_GEN
if(!aShape.IsNull())
DbgTools_Write(aShape, "G_FindShape.brep") ;
#endif
if(!aShape.IsNull()) found = Standard_True;
-#ifdef MDTV_DEB_GEN
+#ifdef OCCT_DEBUG_GEN
cout << "Generated ==>aGenerators.Extent() = " <<aGenerators.Extent() <<" aMS.Extent()= " <<aMS.Extent()<<endl;
#endif
if(found) {
-#ifdef MDTV_DEB_GEN
+#ifdef OCCT_DEBUG_GEN
cout << "Generated ==> Shape is found!" <<endl;
#endif
TopTools_ListOfShape aLM;
Standard_Boolean a1NB = Standard_False;
if(aGenerators.Extent() != aMS.Extent()) { //missed generators
aHas = Standard_True;//has lost generatos
-#ifdef MDTV_DEB_GEN
+#ifdef OCCT_DEBUG_GEN
cout << "Generated ==> has lost generatos!" <<endl;
#endif
for (TNaming_ListIteratorOfListOfNamedShape itg(aGenerators); itg.More(); itg.Next()) {
}
} else
{ //not found
-#ifdef MDTV_DEB_GEN
+#ifdef OCCT_DEBUG_GEN
cout << "Generated ==> Shape is NOT found! Probably Compound will be built" <<endl;
#endif
TopTools_MapOfShape MS;
TDF_LabelMap Forbiden;
TNaming_NamingTool::CurrentShape (Valid,Forbiden,A,MS);
-#ifdef MDTV_DEB_SOL2
+#ifdef OCCT_DEBUG_SOL2
//TCollection_AsciiString entry;
//TDF_Tool::Entry(L, entry);
//TDF_Tool::Entry(A->Label(), entry);
#else
const TopoDS_Shape& S = itM.Key();
#endif
-#ifdef MDTV_DEB_SOL2
+#ifdef OCCT_DEBUG_SOL2
//TopAbs_Orientation Or = S.Orientation();
#endif
B.Select(S,S);
//----------------------------------------
Handle(TNaming_NamedShape) Cand = Args.First(); //collection of candidates
-#ifdef MDTV_DEB_FNB
+#ifdef OCCT_DEBUG_FNB
Standard_Integer i = 1;
TCollection_AsciiString aNam("Cand_");
TCollection_AsciiString ext(".brep");
TopTools_MapOfShape SCand;
TNaming_NamingTool::CurrentShape (Valid, Forbiden,Cand,SCand);//fills SCand with last modifications of Cand. CandNS should be at the same level (before) as NS of FilterByNBS
-#ifdef MDTV_DEB_FNB
+#ifdef OCCT_DEBUG_FNB
TCollection_AsciiString aNam2("SCand");
DbgTools_Write(SCand, aNam2.ToCString());
cout <<"SCand Extent = " << SCand.Extent() << " Expected ShapeType = " << ShapeType << endl;
if (ShapeType == TopAbs_EDGE) TC = TopAbs_VERTEX;
if (ShapeType == TopAbs_VERTEX) TC = TopAbs_VERTEX; // szy 31.03.10 - to process case when Candidate is of type Vertex
-#ifdef MDTV_DEB_FNB
+#ifdef OCCT_DEBUG_FNB
i=1;
aNam = "Boundaries";
#endif
else //#
for (TopExp_Explorer exp(S,TC); exp.More(); exp.Next()) { //put boundaries of each candidate (from SCand) to the Boundaries map
Boundaries.Add (exp.Current());
-#ifdef MDTV_DEB_FNB
+#ifdef OCCT_DEBUG_FNB
TCollection_AsciiString aName = aNam + i++ + ext;
DbgTools_Write(exp.Current(), aName.ToCString()) ;
#endif
TNaming_ListIteratorOfListOfNamedShape it(Args);
it.Next();
Standard_Boolean Keep = 1;
-#ifdef MDTV_DEB_FNB
+#ifdef OCCT_DEBUG_FNB
cout <<"Args number = " << Args.Extent() <<endl;
i=1;
aNam = "Boundaries";
// of each neighbor.
const Handle(TNaming_NamedShape)& NSVois = it.Value(); //neighbor
-#ifdef MDTV_DEB_FNB
+#ifdef OCCT_DEBUG_FNB
DbgTools_WriteNSOnLabel(NSVois, "Next_Neighbor_") ;
#endif
TopTools_MapOfShape SVois;
TNaming_NamingTool::CurrentShape (Valid, Forbiden,NSVois,SVois); // fills SVois with last modifications of NSVois
-#ifdef MDTV_DEB_FNB
+#ifdef OCCT_DEBUG_FNB
TCollection_AsciiString aNam2("SVois");
DbgTools_Write(SVois, aNam2.ToCString());
#endif
for (TopExp_Explorer exp1(Vois,TC); exp1.More(); exp1.Next()) { //7
if (Boundaries.Contains(exp1.Current())) {
Connected = Standard_True; // has common boundaries with candidate shape
-#ifdef MDTV_DEB_FNB
+#ifdef OCCT_DEBUG_FNB
DbgTools_Write(Vois, "Neighbor_Connected.brep");
#endif
break;
if (Keep) {
B.Select (S,S);
isDone = Standard_True;
-#ifdef MDTV_DEB_FNB
+#ifdef OCCT_DEBUG_FNB
DbgTools_Write(S, "FilterByNbs_Sel.brep") ;
#endif
}
//=======================================================================
static const TopoDS_Shape FindSubShapeInAncestor(const TopoDS_Shape& Selection, const TopoDS_Shape& Context )
{
-#ifdef MDTV_DEB_OR_AG
+#ifdef OCCT_DEBUG_OR_AG
DbgTools_Write(Selection, "Orientation_Selection.brep");
DbgTools_Write(Context, "Orientation_Context.brep");
TopExp_Explorer expl1(Context, Selection.ShapeType());
if(Selection.ShapeType() != TopAbs_COMPOUND) {
TopExp_Explorer anExpl(Context, Selection.ShapeType());
for(;anExpl.More(); anExpl.Next()) {
-#ifdef MDTV_DEB_OR_AG
+#ifdef OCCT_DEBUG_OR_AG
cout <<"FindSubShape: = " <<anExpl.Current().ShapeType() << " TS = " <<anExpl.Current().TShape()->This() << endl;
DbgTools_Write(anExpl.Current(), "Orientation_Current.brep");
#endif
else {
isSplit = Standard_True;
S = MakeShape(MS);
-#ifdef MDTV_DEB_OR
+#ifdef OCCT_DEBUG_OR
for(Standard_Integer i=1;it.More();it.Next(), i++) {
TCollection_AsciiString aNam("OR_Selection_");
TCollection_AsciiString aName = aNam + i + ".brep";
TNaming_Builder B(L);
if(S.IsNull())
return Standard_False;
-#ifdef MDTV_DEB_OR
+#ifdef OCCT_DEBUG_OR
DbgTools_Write(S, "Orientation_S.brep");
#endif
TopTools_MapOfShape MSC;
if(aSList.Extent() == 0) {
const Handle(TNaming_NamedShape)& Anc = Args.Last();
-#ifdef MDTV_DEB_OR
+#ifdef OCCT_DEBUG_OR
cout << "### ORIENTATION: Ancestor ";
PrintEntry(Anc->Label());
#endif
if(i == Index && it.Value().IsSame(S)) {
CS = it.Value();
found = Standard_True;
-#ifdef MDTV_DEB_OR
+#ifdef OCCT_DEBUG_OR
cout << "ORIENTATION => ORDER = " << i <<endl;
#endif
break;
} else
CS = FindSubShapeInAncestor(S, AS);
// <=== end 21.10.2009
-#ifdef MDTV_DEB_OR
+#ifdef OCCT_DEBUG_OR
cout << "ORIENTATION: Selection" <<" TShape = " <<CS.TShape() <<" Orientation = " << CS.Orientation() <<endl;
cout << "ORIENTATION: Context " << "ShapeType = "<<AS.ShapeType() << " TShape = " <<AS.TShape() <<endl;
DbgTools_Write(AS, "Orientation_Cnt.brep");
return Standard_False;
}
else {
-#ifdef MDTV_DEB_OR
+#ifdef OCCT_DEBUG_OR
DbgTools_Write(Arr->Value(1,2), "Ancestor.brep");
#endif
if(!Aggregation(S, Arr->Value(1,2), B)) {
return Standard_False;
}
else {
-#ifdef MDTV_DEB_OR
+#ifdef OCCT_DEBUG_OR
DbgTools_Write(AC, "Aggregation.brep");
#endif
if(!Aggregation(S, AC, B)) {
if (MS.Extent() != 1) return aResult;
TopTools_MapIteratorOfMapOfShape itM(MS);
const TopoDS_Shape& aCF = itM.Key() ;
-#ifdef MDTV_DEB_WIN
+#ifdef OCCT_DEBUG_WIN
cout <<"MS Extent = " <<MS.Extent() <<endl;
DbgTools_Write(aCF, "Context_Face.brep");
#endif
TopoDS_Shape CS = MakeShape(MS);
TNaming_ShapesSet aSet(CS,TopAbs_EDGE);//fill internal map of shapeset by shapes of the specified type
-#ifdef MDTV_DEB_WIN
+#ifdef OCCT_DEBUG_WIN
TCollection_AsciiString entry;
TDF_Tool::Entry(it.Value()->Label(), entry);
TCollection_AsciiString Nam("Arg_");
#endif
it.Next();
for (; it.More(); it.Next()) {
-#ifdef MDTV_DEB_WIN
+#ifdef OCCT_DEBUG_WIN
TDF_Tool::Entry(it.Value()->Label(), entry);
#endif
MS.Clear();
TNaming_ShapesSet OS(CS,TopAbs_EDGE);
aSet.Add(OS); //concatenate both shapesets
-#ifdef MDTV_DEB_WIN
+#ifdef OCCT_DEBUG_WIN
ii++;
TCollection_AsciiString aNm = Nam + entry + "_" + ii + ".brep";
DbgTools_Write(CS, aNm.ToCString());
#endif
}
-#ifdef MDTV_DEB_WIN
+#ifdef OCCT_DEBUG_WIN
cout <<"WIREIN: " << " Internal Map ext = " << aSet.Map().Extent()<<endl;
TopTools_MapIteratorOfMapOfShape it1 (aSet.Map());
for (int i=1;it1.More();it1.Next(),i++) {
for (TopoDS_Iterator itF(aCF); itF.More(); itF.Next()) {// find the expected wire in the face
const TopoDS_Shape& S = itF.Value();//wire
if(!S.IsNull()) {
-#ifdef MDTV_DEB_WIN
+#ifdef OCCT_DEBUG_WIN
DbgTools_Write(S, "WireIN_S.brep");
cout <<"WIREIN: ShapeType = " << S.ShapeType() << " TS = " << S.TShape()->This() <<endl;
#endif
if (MS.Extent() != 1) return aResult;
TopTools_MapIteratorOfMapOfShape itM(MS);
const TopoDS_Shape& aCSO = itM.Key() ;
-#ifdef MDTV_DEB_SHELL
+#ifdef OCCT_DEBUG_SHELL
cout <<"MS Extent = " <<MS.Extent() <<endl;
DbgTools_Write(aCSO, "Context_Solid.brep");
#endif
if(!anOuterShell.IsNull()) {
B.Select(anOuterShell, anOuterShell);
aResult = Standard_True;
-#ifdef MDTV_DEB_SHELL
+#ifdef OCCT_DEBUG_SHELL
cout << "Outer Shell case" <<endl;
PrintEntry(L);
DbgTools_Write(anOuterShell, "ShellOut_S.brep");
TopoDS_Shape CS = MakeShape(MS);
TNaming_ShapesSet aSet(CS,TopAbs_FACE);//fill internal map of shapeset by shapes of the specified type
-#ifdef MDTV_DEB_SHELL
+#ifdef OCCT_DEBUG_SHELL
TCollection_AsciiString entry;
TDF_Tool::Entry(it.Value()->Label(), entry);
TCollection_AsciiString Nam("Arg_");
#endif
it.Next();
for (; it.More(); it.Next()) {
-#ifdef MDTV_DEB_SHELL
+#ifdef OCCT_DEBUG_SHELL
TDF_Tool::Entry(it.Value()->Label(), entry);
#endif
MS.Clear();
TNaming_ShapesSet OS(CS,TopAbs_FACE);
aSet.Add(OS); //concatenate both shapesets
-#ifdef MDTV_DEB_SHELL
+#ifdef OCCT_DEBUG_SHELL
ii++;
TCollection_AsciiString aNm = Nam + entry + "_" + ii + ".brep";
DbgTools_Write(CS, aNm.ToCString());
#endif
}
-#ifdef MDTV_DEB_SHELL
+#ifdef OCCT_DEBUG_SHELL
cout <<"SHELLIN: " << " Internal Map ext = " << aSet.Map().Extent()<<endl;
TopTools_MapIteratorOfMapOfShape it1 (aSet.Map());
for (int i=1;it1.More();it1.Next(),i++) {
for (TopoDS_Iterator itS(aCSO); itS.More(); itS.Next()) {// find the expected shell in the solid
const TopoDS_Shape& S = itS.Value();//shell
if(!S.IsNull()) {
-#ifdef MDTV_DEB_SHELL
+#ifdef OCCT_DEBUG_SHELL
DbgTools_Write(S, "ShellIN_S.brep");
cout <<"SHELLIN: ShapeType = " << S.ShapeType() << " TS = " << S.TShape()->This() <<endl;
#endif
}
return aResult;
}
-#ifdef TNAMING_DEB
+#ifdef OCCT_DEBUG
//=======================================================================
static Standard_CString NameTypeToString (const TNaming_NameType Type)
{
const TDF_LabelMap& Valid) const
{
Standard_Boolean Done = 0;
-#ifdef MDTV_DEB_WIN
+#ifdef OCCT_DEBUG_WIN
PrintEntry(aLab);
#endif
try {
}
case TNaming_WIREIN:
{
-#ifdef MDTV_DEB_WIN
+#ifdef OCCT_DEBUG_WIN
cout << "Name::Solve: NameType = " << myType << " ";
PrintEntry(aLab);
#endif
}
case TNaming_SHELLIN:
{
-#ifdef MDTV_DEB_SHELL
+#ifdef OCCT_DEBUG_SHELL
cout << "Name::Solve: NameType = " << myType << " ";
PrintEntry(aLab);
#endif
}
}
} catch (...) {
-#ifdef TNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "Name::Solve: EXCEPTION==> NameType = " << NameTypeToString(myType) << " ";
PrintEntry(aLab);
#endif
void TNaming_NamedShape::Clear()
{
if (Label().IsNull()) {
-#ifdef DEB_BUILDER
+#ifdef OCCT_DEBUG_BUILDER
cout << "attention etat fantomatique" << endl;
#endif
return;
TNaming_RefShape* pns;
if (myShapes->myMap.IsBound(newShape)) {
-#ifdef DEB_BUILDER
+#ifdef OCCT_DEBUG_BUILDER
cout <<"TNaming_Builder::Generate : the shape is already in the attribute"<<endl;
#endif
pns = myShapes->myMap.ChangeFind(newShape);
if (myShapes->myMap.IsBound(oldShape))
pos = myShapes->myMap.ChangeFind(oldShape);
else {
-#ifdef DEB_BUILDER
+#ifdef OCCT_DEBUG_BUILDER
cout <<"TNaming_Builder::Delete : the shape is not in the data"<<endl;
#endif
pos = new TNaming_RefShape(oldShape);
}
if (oldShape.IsSame(newShape)) {
-#ifdef DEB_BUILDER
+#ifdef OCCT_DEBUG_BUILDER
cout <<"TNaming_Builder::Generate : oldShape IsSame newShape"<<endl;
#endif
return;
}
if (oldShape.IsSame(newShape)) {
-#ifdef DEB_BUILDER
+#ifdef OCCT_DEBUG_BUILDER
cout <<"TNaming_Builder::Modify : oldShape IsSame newShape"<<endl;
#endif
return;
}
else {
myNode = 0L;
-#ifdef TNAMING_DEB
+#ifdef OCCT_DEBUG
cout <<"TNaming_Iterator : No Shape for this label"<<endl;
#endif
}
if (access.Root().FindAttribute(TNaming_UsedShapes::GetID(),US)) {
return (US->Map().IsBound(S));
}
-#ifdef MDTV_DEB_HASL
+#ifdef OCCT_DEBUG_HASL
cout << "##==> Sub-Shape has no Label!" <<endl;
#endif
return Standard_False;
//#define MDTV_DEB_NBS
//#define MDTV_DEB_71
//#define MDTV_DEB_WIN
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
#include <TDF_MapIteratorOfLabelMap.hxx>
#include <TCollection_AsciiString.hxx>
#include <TDF_Tool.hxx>
#include <BRepTools.hxx>
#include <TNaming_Tool.hxx>
-#include <DbgTools.hxx>
-#endif
-#ifdef DEB
#include <TDF_Tool.hxx>
#include <TDF_MapIteratorOfLabelMap.hxx>
{
Handle(TNaming_Naming) subname;
for (TDF_ChildIterator it (Label(),Standard_False); it.More(); it.Next()) {
-#ifdef MDTV_DEB_NBS
+#ifdef OCCT_DEBUG_NBS
TCollection_AsciiString anEntry;
TDF_Tool::Entry(it.Value(), anEntry);
cout << "TNaming_Naming::Solve: Label to be solved = " << anEntry << endl;
}
}
}
-#ifdef MDTV_DEB_CC
+#ifdef OCCT_DEBUG_CC
TDF_MapIteratorOfLabelMap anItr(Valid);
cout << "TNaming_Naming::Solve:: Valid label Map" << endl;
for (; anItr.More(); anItr.Next()) {
{
Handle(TNaming_NamedShape) aTarget = TNaming_Tool::NamedShape(theTarget,theSource->Label());
if (!aTarget.IsNull()) {
-#ifdef MDTV_DEB_71
+#ifdef OCCT_DEBUG_71
cout <<"GetShapeEvolutions: target NS = ";
Print_Entry(aTarget->Label());
cout <<"GetShapeEvolutions: Source NS = ";
TNaming_Iterator anIter(aTarget);
for(;anIter.More();anIter.Next()) { // check all appropriate old shapes of target
-#ifdef MDTV_DEB_71
+#ifdef OCCT_DEBUG_71
if(!anIter.OldShape().IsNull()) {
Write(anIter.OldShape(), "Target_OldS.brep");
cout <<"Target OldS TS =" <<anIter.OldShape().TShape()->This() <<endl;
{
Handle(TNaming_NamedShape) aResult;
if (S.IsNull() || NS.IsNull()) return aResult;
-#ifdef MDTV_DEB_71
+#ifdef OCCT_DEBUG_71
cout <<"CompareInModification: parent NS = ";
Print_Entry(NS->Label());
Write(S, "CompareInM_S.brep");
for(;anIt.More() && aSource.IsNull();anIt.Next()) {
if (!anIt.NewShape().IsNull()) {
aSource = TNaming_Tool::NamedShape(anIt.NewShape(),NS->Label());
-#ifdef MDTV_DEB_71
+#ifdef OCCT_DEBUG_71
TCollection_AsciiString aNam("CompareInM_Source");
WriteNSOnLabel(aSource,aNam);
#endif
TopoDS_Iterator it(S);
for (; it.More(); it.Next()) {
const TopAbs_ShapeEnum aType = it.Value().ShapeType();
-#ifdef MDTV_DEB_CC
+#ifdef OCCT_DEBUG_CC
cout <<"TestSolution_FillMap: S_Type = :" << it.Value().ShapeType() <<" TShape = " << it.Value().TShape()->This() <<endl;
#endif
if(aType > TopAbs_COMPSOLID) {
TopTools_MapOfShape MS;
if (!Stop.IsNull()) TNaming_NamingTool::BuildDescendants(Stop,Forbiden);
TNaming_NamingTool::CurrentShape(MDF.GetValid(),Forbiden,NS,MS);
-#ifdef MDTV_DEB_NBS
+#ifdef OCCT_DEBUG_NBS
Write(S, "Compare_S.brep");
cout << "S: TShape = " <<S.TShape()->This() <<endl;
Standard_Integer i =1;
if (NS.IsNull()) return Standard_False;
TopoDS_Shape Res = MDF.CurrentShape(NS);// last modification of NS taken into account Valid map
if(S.IsNull() || Res.IsNull()) return Standard_False;
-#ifdef MDTV_DEB_CC
+#ifdef OCCT_DEBUG_CC
Write(S, "TSol_S.brep");
Write(Res, "TSol_Res.brep");
#endif
if(aMS.Extent())
aDMM.Bind(it.Key(), aMS);
} else {
-#ifdef TNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "Key is not BOUND!" <<endl;
#endif
return Standard_False;
Standard_Integer aLev(Lev);
TopTools_MapOfShape Neighbourg;
Localizer.FindNeighbourg (Context,S,Neighbourg);
-#ifdef MDTV_DEB_NBS
+#ifdef OCCT_DEBUG_NBS
//DbgTools::DisplayShape(Context, F, Quantity_NOC_GREEN);
//DbgTools::DisplayShape(S, F, Quantity_NOC_BLUE1);
Write(Context, "FNBS_Context.brep");
Standard_Boolean isIn = Standard_False;
TNaming_Iterator anIter(NS);
for(;anIter.More();anIter.Next()) {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
//DbgTools::DisplayShape(anIter.NewShape(), F, Quantity_NOC_RED);
#endif
if (anIter.NewShape().IsSame(S)) {
if (Neighbourg.IsEmpty()) {
-#ifdef TNAMING_DEB
+#ifdef OCCT_DEBUG
cout <<"FindNeighbourg: impossible"<<endl;
#endif
return 0;
} else {
-#ifdef MDTV_DEB_NBS
+#ifdef OCCT_DEBUG_NBS
Write(Neighbourg, "Neighbourgs");
#endif
aLev++;
TNaming_ListIteratorOfListOfNamedShape itA(aName.Arguments());
for (; itA.More(); itA.Next(), ij++) {
const TopoDS_Shape& aFace = TNaming_Tool::CurrentShape(itA.Value());
-#ifdef MDTV_DEB_MOD
+#ifdef OCCT_DEBUG_MOD
Write(aFace, "First_Face.brep");
cout <<"Selection TS = " << S.TShape()->This() <<endl;
#endif
TopoDS_Iterator it(aFace);
for (;it.More();it.Next(),i++) {
nbW++;
-#ifdef MDTV_DEB_MOD
+#ifdef OCCT_DEBUG_MOD
Write(it.Value(), "First_Wire.brep");
#endif
if(!isFound) {
TopoDS_Iterator it2(it.Value());
for (;it2.More();it2.Next(),j++) {
nbE++;
-#ifdef MDTV_DEB_MOD
+#ifdef OCCT_DEBUG_MOD
Write(it2.Value(), "First_Wire.brep");
cout <<"Edge TS = " << it2.Value().TShape()->This() <<endl;
#endif
theName.Type(TNaming_FILTERBYNEIGHBOURGS);
theName.Append(NS);
theName.StopNamedShape (Until);
-#ifdef MDTV_DEB_NBS
+#ifdef OCCT_DEBUG_NBS
cout << "FilterByNBS: ";
Print_Entry(NF->Label());
cout <<"AppendNS = " ;
const TopoDS_Shape& aS = itN.Key();
Handle (TNaming_NamedShape) aNS =
BuildName(NF->Label(), MDF, aS, Context, Stop, 1);
-#ifdef MDTV_DEB_NBS
+#ifdef OCCT_DEBUG_NBS
const TopoDS_Shape& aS2 = aNS->Get();
if(!aS.IsNull())
cout << "Shape arg type = " << aS.ShapeType() <<" TSH = " << aS.TShape()->This()<<endl;
if(allowChild && !aSNS.IsNull() && aS.ShapeType() != aSNS.ShapeType() &&
aSNS.ShapeType() == TopAbs_COMPOUND)
{ // aLev < 3
-#ifdef MDTV_DEB_NBS
+#ifdef OCCT_DEBUG_NBS
cout <<"Father label = ";
Print_Entry(aNS->Label().Father());
Write(aS,"SelectionS.brep");
// Check du filtre.
//-----------------
if (Compare (NS,MDF,Stop,S)) return 1;
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG
cout <<"TNaming_Naming::Name Filter insufficient"<<endl;
#endif
return 0;
// <Context> is Ident.NamedShapeOfGeneration() ==
TDF_Label Father = Context->Label().Father();
Father.FindAttribute(TNaming_NamedShape::GetID(),NewStop);
-#ifdef MDTV_DEB_INNS
+#ifdef OCCT_DEBUG_INNS
if(!Stop.IsNull())
{cout <<" Stop NS : "; Print_Entry( Stop->Label());}
if(!NewStop.IsNull())
cout <<"Father : "; Print_Entry( Father);
#endif
}
-#ifdef MDTV_DEB_INNS
+#ifdef OCCT_DEBUG_INNS
if(NewStop.IsNull())
cout <<"BuildNameInNS:: NewStop shape is NULL" << endl;
#endif
// Create an identifier
Standard_Boolean OnlyOne = !Geom;
Standard_Boolean IsGeneration = Standard_False;
-#ifdef MDTV_DEB_MOD
+#ifdef OCCT_DEBUG_MOD
cout <<"BuildName: F => ";
Print_Entry(F);
cout <<" Selection type = " << Selection.ShapeType() << " TS = " << Selection.TShape()->This() << endl;
theName.Shape(Selection);
theName.Orientation(Selection.Orientation());
theName.Type(Ident.Type());
-#ifdef MDTV_DEB_MOD
+#ifdef OCCT_DEBUG_MOD
cout <<"BuildName: Inserted Naming Att at ";
Print_Entry(Naming->Label());
cout <<" NameType = " << theName.Type() <<endl;
// Renseignement du NamedShape d arret.
//------------------------------------
theName.StopNamedShape (Stop);
-#ifdef MDTV_DEB_MOD
+#ifdef OCCT_DEBUG_MOD
if(!Stop.IsNull()) {
TCollection_AsciiString Es;
TDF_Tool::Entry(Stop->Label(), Es);
for (Ident.InitArgs(); Ident.MoreArgs(); Ident.NextArg()) {
if (Ident.ArgIsFeature()) {
theName.Append(Ident.FeatureArg());
-#ifdef MDTV_DEB_MOD
+#ifdef OCCT_DEBUG_MOD
if(!Ident.FeatureArg().IsNull()) {
TCollection_AsciiString E;
TDF_Tool::Entry(Ident.FeatureArg()->Label(), E);
#endif
}
else {
-#ifdef MDTV_DEB_MOD
+#ifdef OCCT_DEBUG_MOD
cout <<"BuildName: NameType = " <<theName.Type() << " NS ";
Print_Entry(Naming->Label());
cout <<"Ident.ShapeArg() type = " << Ident.ShapeArg().ShapeType() << " TS = " << Ident.ShapeArg().TShape()->This() << endl;
// Reconstruction of Name
//------------------------
Naming->Regenerate(MDF.ChangeValid());
-#ifdef MDTV_DEB_MOD
+#ifdef OCCT_DEBUG_MOD
TCollection_AsciiString E2;
TDF_Tool::Entry(Naming->Label(), E2);
cout <<"Regenerated Naming Att at Label = "<< E2 << endl;
Naming->Label().FindAttribute(TNaming_NamedShape::GetID(),NS);
if(NS.IsNull()) return NS;
if (MDF.WithValid()) MDF.Valid(NS->Label());
-#ifdef MDTV_DEB_MOD
+#ifdef OCCT_DEBUG_MOD
if(!NS.IsNull()) {
TCollection_AsciiString E;
TDF_Tool::Entry(NS->Label(), E);
}
} else if (Ident.Type() == TNaming_MODIFUNTIL ||
(Ident.Type() == TNaming_INTERSECTION && Naming->ChangeName().Arguments().Extent() == 1)) {
-#ifdef MDTV_DEB_MOD
+#ifdef OCCT_DEBUG_MOD
cout <<"BuildName(CompareInModification): NameType = " <<Ident.Type() << " NS ";
Print_Entry(Ident.Type() == TNaming_MODIFUNTIL ? NS->Label() : Naming->ChangeName().Arguments().First()->Label());
cout <<"Selection type = " << Selection.ShapeType() << " TS = " << Selection.TShape()->This() << endl;
}
}
if (MDF.WithValid()) MDF.Valid(NS->Label());
-#ifdef MDTV_DEB_MOD
+#ifdef OCCT_DEBUG_MOD
if(!NS.IsNull()) {
TCollection_AsciiString E;
TDF_Tool::Entry(NS->Label(), E);
//=======================================================================
static Standard_Boolean IsAllIn (const TopoDS_Shape& S, const TopoDS_Shape& Context)
{
-#ifdef MDTV_DEB_CC
+#ifdef OCCT_DEBUG_CC
Write(S, "IsAllIn_Sel.brep");
#endif
Standard_Boolean found(Standard_False);
if(S.IsNull() || Context.IsNull()) return found;
Standard_Integer num1(0), num2(0);
for(TopoDS_Iterator it(S);it.More();it.Next(),num1++) {
-#ifdef MDTV_DEB_CC
+#ifdef OCCT_DEBUG_CC
cout <<"S sub-shape type = " << it.Value().ShapeType() <<endl;
Write (it.Value(), "Sel_ItValue.brep");
#endif
if(it.Value().ShapeType() != TopAbs_COMPOUND)
for (TopExp_Explorer exp(Context,it.Value().ShapeType()); exp.More(); exp.Next()) {
-#ifdef MDTV_DEB_CC
+#ifdef OCCT_DEBUG_CC
cout <<"Context sub-shape type = " << exp.Current().ShapeType() <<endl;
Write(exp.Current(), "Contex_Curnt.brep");
#endif
}
if(num1 == num2)
found = Standard_True;
-#ifdef MDTV_DEB_CC
+#ifdef OCCT_DEBUG_CC
else
cout <<"Compound case : selected num1 = " << num1 << " context contains num2 = " << num2 << endl;
#endif
}
}
}
-#ifdef MDTV_DEB_OR
+#ifdef OCCT_DEBUG_OR
cout <<"RepeatabilityInContext: = " <<aNum <<endl;
#endif
return aNum;
hasSolid = Standard_True;
TopoDS_Shell anOuterShell;
if(TNaming::OuterShell(TopoDS::Solid(Solid), anOuterShell)) {
-#ifdef MDTV_DEB_TSOL
+#ifdef OCCT_DEBUG_TSOL
Write(anOuterShell, "OuterShell.brep");
#endif
if(!anOuterShell.IsNull() && anOuterShell.IsEqual(Sh))
if(Context.ShapeType() == TopAbs_SOLID) {
for (TopoDS_Iterator it(Context) ; it.More(); it.Next()) {
-#ifdef MDTV_DEB_TSOL
+#ifdef OCCT_DEBUG_TSOL
Write(it.Value(), "Shell_inSo.brep");
#endif
if(it.Value().IsEqual(Selection)) {
// context is not SOLID
//theName.Append(BuildName (Naming->Label(),MDF,aSolid,Context,Stop,Geom));//###########
if(isOuter) {
-#ifdef MDTV_DEB_TSOL
+#ifdef OCCT_DEBUG_TSOL
Write(aSolid, "foundSolid.brep");
#endif
theName.Index(1);
theName.Shape(S);
theName.Orientation(S.Orientation());
}
-#ifdef MDTV_DEB_CC
+#ifdef OCCT_DEBUG_CC
cout <<"BuildAggregationName ==> ";
Print_Entry(Naming->Label());
#endif
}
}
} else {
-#ifdef MDTV_DEB_CC
+#ifdef OCCT_DEBUG_CC
cout << "atomic type is NOT defined ... ==> Aggregation" <<endl;
#endif
BuildAggregationName(aNaming->Label(),MDF, aS, Context,Stop,Geom);
{
Handle(TNaming_NamedShape) NS;
if (KeepOrientation) {
-#ifdef MDTV_DEB_INNS
+#ifdef OCCT_DEBUG_INNS
cout <<"KeepOR = 1: "; Print_Entry(F);
#endif
Standard_Integer aNum = RepeatabilityInContext(S, Context);
Handle(TopTools_HArray1OfShape) Arr;
if (UC.IsNull() && S.ShapeType() == TopAbs_COMPOUND) {
UC = TNaming::FindUniqueContextSet(S, Context, Arr);
-#ifdef MDTV_DEB_CC
+#ifdef OCCT_DEBUG_CC
Write(UC, "UniqueContextSet.brep");
Write(S, "InitialSelection.brep");
if(S.ShapeType()==TopAbs_COMPOUND) {
#include <TNaming_Tool.hxx>
#include <TNaming_Naming.hxx>
#include <TDF_ChildIterator.hxx>
-#ifdef DEB
-//#define MDTV_DEB_DESC
-//#define MDTV_DEB_APPLY
-#ifdef MDTV_DEB_DESC
+
+#ifdef OCCT_DEBUG_DESC
#include <TCollection_AsciiString.hxx>
#include <TDF_Tool.hxx>
#include <BRepTools.hxx>
save.close();
}
#endif
-#endif
+
//=======================================================================
//function : IsForbiden
//purpose : ANaming voir NamingTool
Standard_Boolean YaModif = Standard_False;
for (; it.More(); it.Next()) {
const TDF_Label& Lab = it.Label();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG_DESC
TCollection_AsciiString entry;
TDF_Tool::Entry(Lab, entry);
cout << "NamingTool:: LastModif LabelEntry = "<< entry << endl;
const TopAbs_Orientation OrientationToApply)
{
if (!MS.IsEmpty ()) {
-#ifdef MDTV_DEB_APPLY
+#ifdef OCCT_DEBUG_APPLY
cout <<"OrientationToApply = " <<OrientationToApply <<endl;
TopTools_MapIteratorOfMapOfShape it1(MS);
for (; it1.More(); it1.Next()) {
TopTools_MapOfShape& MS)
{
TDF_Label Lab = Att->Label();
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG_DESC
TCollection_AsciiString entry;
TDF_Tool::Entry(Lab, entry);
cout << "NamingTool:: LabelEntry = "<< entry << endl;
#endif
if (!Valid.IsEmpty() && !Valid.Contains(Lab)) {
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG_DESC
TCollection_AsciiString entry;
TDF_Tool::Entry(Lab, entry);
cout << "NamingTool:: LabelEntry = "<< entry << " is out of Valid map" << endl;
for (; itL.More(); itL.Next()) {
const TopoDS_Shape& S = itL.NewShape();
if (S.IsNull()) continue;
-#ifdef MDTV_DEB
+#ifdef OCCT_DEBUG_DESC
WriteS(S, "CS_NewShape.brep");
if(itL.OldShape().IsNull())
cout <<"OldShape is Null" <<endl;
{
for (; it.More(); it.Next()) {
Descendants.Add(it.Label());
-#ifdef MDTV_DEB_DESC
+#ifdef OCCT_DEBUG_DESC
TCollection_AsciiString entry;
TDF_Tool::Entry(it.Label(), entry);
cout<< "MakeDescendants: Label = " <<entry <<endl;
TNaming_NewShapeIterator it(NS);
for(;it.More();it.Next()) {
if(!it.NamedShape().IsNull()) {
-#ifdef MDTV_DEB_DESC
+#ifdef OCCT_DEBUG_DESC
TCollection_AsciiString entry;
TDF_Tool::Entry(it.Label(), entry);
cout<< "MakeDescendants2: Label = " <<entry <<endl;
if (NS.IsNull()) return;
Descendants.Add(NS->Label());
TNaming_NewShapeIterator it(NS);
-#ifdef MDTV_DEB_DESC
+#ifdef OCCT_DEBUG_DESC
TCollection_AsciiString entry;
TDF_Tool::Entry(NS->Label(), entry);
cout<< "MakeDescendants: Label = " <<entry <<endl;
if(!it2.Shape().IsNull()) {
Handle(TNaming_NamedShape) ONS = TNaming_Tool::NamedShape(it2.Shape(), NS->Label());
if(!ONS.IsNull()) {
-#ifdef MDTV_DEB_DESC
+#ifdef OCCT_DEBUG_DESC
TCollection_AsciiString entry;
TDF_Tool::Entry(ONS->Label(), entry);
cout<< "MakeDescendants_Old: Label = " <<entry <<endl;
#define OCC351
//#define MDTV_DEB_SEL
-#ifdef MDTV_DEB_SEL
+#ifdef OCCT_DEBUG_SEL
//#define MDTV_DEB_BNP
#include <TopExp_Explorer.hxx>
#include <TCollection_AsciiString.hxx>
TopTools_MapOfOrientedShape shapesOfContext;
MapOfOrientedShapes(Context,shapesOfContext);
Handle(TNaming_NamedShape) CNS = TNaming_Tool::NamedShape(Context, F);
-#ifdef MDTV_DEB_BNP
+#ifdef OCCT_DEBUG_BNP
PrintEntry (CNS->Label(),0);
#endif
if(!CNS.IsNull()) {
// Naming data structure is empty - no sub-shapes under resulting shape
const Handle(TNaming_NamedShape) aNS = FindPrevNDS(CNS); //look to old shape data structure if exist
if(!aNS.IsNull()) {
-#ifdef MDTV_DEB_BNP
+#ifdef OCCT_DEBUG_BNP
PrintEntry (aNS->Label(),0);
#endif
cit.Initialize(aNS->Label(), TNaming_NamedShape::GetID(), Standard_False);
if(!NS.IsNull()) {
TopoDS_Shape aS = TNaming_Tool::CurrentShape(NS);
if(aS.IsNull()) continue;
-#ifdef MDTV_DEB_BNP
+#ifdef OCCT_DEBUG_BNP
PrintEntry(NS->Label(), 0);
cout <<"ShapeType =" << aS.ShapeType() <<endl;
Write (aS, "BNProblem.brep");
TopTools_MapIteratorOfMapOfOrientedShape it(M);
for(;it.More();it.Next()) {
if(!shapesOfContext.Contains(it.Key())) {
-#ifdef MDTV_DEB_BNP
+#ifdef OCCT_DEBUG_BNP
cout <<"BNProblem: ShapeType in AtomicMap = " << it.Key().ShapeType() << " TShape = " <<it.Key().TShape() <<" OR = " <<it.Key().Orientation() <<endl;
Write (it.Key(), "BNProblem_AtomicMap_Item.brep");
TopTools_MapIteratorOfMapOfOrientedShape itC(shapesOfContext);
if(Selection.ShapeType() == TopAbs_EDGE) {
Handle(TNaming_NamedShape) aNS = TNaming_Tool::NamedShape(Selection, F);
if(!aNS.IsNull()) { //presented in DF
-#ifdef MDTV_DEB_BNP
+#ifdef OCCT_DEBUG_BNP
PrintEntry (aNS->Label(),0);
#endif
const TopoDS_Shape& aS = TNaming_Tool::CurrentShape(aNS);
selection = Selection;
*/
-#ifdef MDTV_DEB_SEL
+#ifdef OCCT_DEBUG_SEL
cout << "SELECTION ORIENTATION = " << Selection.Orientation() <<", TShape = " << Selection.TShape() <<endl;
//cout << "SELECTION ORIENTATION = " << selection.Orientation() <<", TShape = " << selection.TShape() <<endl;
PrintEntry(myLabel, 0);
// mpv: if oldShape for selection is some shape from used map of shapes,
// then naming structure becomes more complex, can be cycles
const TopoDS_Shape& aSelection = TNaming_Tool::CurrentShape(NS); //szy
-#ifdef MDTV_DEB_CHECK_TYPE
+#ifdef OCCT_DEBUG_CHECK_TYPE
if(!Selection.IsSame(aSelection) && Selection.ShapeType() != TopAbs_COMPOUND) {
TCollection_AsciiString entry;
TDF_Tool::Entry(NS->Label(), entry);
Standard_Boolean TNaming_Selector::Solve (TDF_LabelMap& Valid) const
{
Handle(TNaming_Naming) name;
-#ifdef MDTV_DEB_SEL
+#ifdef OCCT_DEBUG_SEL
cout <<"TNaming_Selector::Solve==> ";
PrintEntry(myLabel,0);
#endif
const TopAbs_ShapeEnum Type)
{
if (CS.IsNull()) return;
-#ifdef MDTV_DEB_INT
+#ifdef OCCT_DEBUG_INT
cout << "ShapeSet: CS TShape = " <<CS.TShape() << " Type = " << Type <<endl;
#endif
if (Type == TopAbs_SHAPE) {
if (Type > CS.ShapeType()) {
for (TopExp_Explorer exp(CS,Type) ; exp.More(); exp.Next()) {
Add(exp.Current());
-#ifdef MDTV_DEB_INT
+#ifdef OCCT_DEBUG_INT
cout << "ShapeSet: sub-shape TShape = " <<exp.Current().TShape() <<endl;
#endif
}
// Pour DEBUGGER
-#ifdef DEB
+#ifdef OCCT_DEBUG
//=======================================================================
//function : TNamingTool_Label
// Which type of shape is being expected?
Handle(TNaming_Naming) aNaming;
if (!Arg->FindAttribute(TNaming_Naming::GetID(), aNaming)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
// cout<<"TNaming_Tool::FindShape(): Naming attribute hasn't been found attached at the Argument label"<<endl;
#endif
return;
TopTools_MapOfShape subShapes;
TopExp_Explorer anExpl(Arg->Get(), (TopAbs_ShapeEnum)((int)(aNaming->GetName().ShapeType()) + 1));
for (; anExpl.More(); anExpl.Next()) subShapes.Add(anExpl.Current());
-#ifdef DEB
+#ifdef OCCT_DEBUG
// cout<<"TNaming_Tool::FindShape(): Nb of sub shapes = "<<subShapes.Extent()<<endl;
#endif
TDF_AttributeMap outRefs;
TDF_Tool::OutReferences(Arg->Label(), outRefs);
if (outRefs.IsEmpty()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
// cout<<"TNaming_Tool::FindShape(): No out references have been found"<<endl;
#endif
return;
}
for (TDF_MapIteratorOfAttributeMap itr(outRefs); itr.More(); itr.Next()) {
if (itr.Key()->DynamicType() == STANDARD_TYPE(TNaming_NamedShape)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nbExtArgs = extArgs.Extent();
#endif
const Handle(TNaming_NamedShape)& anExtArg = Handle(TNaming_NamedShape)::DownCast(itr.Key());
const Handle(TNaming_NamedShape)& aCurrentExtArg = TNaming_Tool::CurrentNamedShape(anExtArg);
if (!aCurrentExtArg.IsNull() && !aCurrentExtArg->IsEmpty())
extArgs.Append(aCurrentExtArg);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// if (extArgs.Extent() - 1 == nbExtArgs) {
// cout<<"TNaming_Tool::FindShape(): An external reference has been found at ";
// itr.Key()->Label().EntryDump(cout); cout<<endl;
if (anExtArg->Label().Father().IsNull() ||
!anExtArg->Label().Father().FindAttribute(TNaming_NamedShape::GetID(), aContextNS)) {
aContextNS = anExtArg;
-// #ifdef DEB
+// #ifdef OCCT_DEBUG
// cout<<"TNaming_Tool::FindShape(): A context shape hasn't been found at the father label of the external argument"<<endl;
// #endif
// continue;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
// cout<<"TNaming_Tool::FindShape(): Searching in the external reference ";
// aContextNS->Label().EntryDump(cout); cout<<" ";
#endif
}
}
if (DoesCoincide == subShapes.Extent()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
// cout<<"TNaming_Tool::FindShape(): Found! ";
#endif
S = possibleResult;
}
if (!S.IsNull()) break;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// cout<<endl;
#endif
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (S.IsNull()) {
cout<<"TNaming_Tool::FindShape(): There hasn't been found a sub shape of the context shape coinciding with the sub shapes of naming"<<endl;
}
}
catch (Standard_Failure)
{
-#if defined(_DEBUG) || defined(DEB)
+#ifdef OCCT_DEBUG
ErrorMessage (Message_Msg("TObj_Appl_Exception") <<
Standard_Failure::Caught()->GetMessageString());
#endif
}
catch (Standard_Failure)
{
-#if defined(_DEBUG) || defined(DEB)
+#ifdef OCCT_DEBUG
Handle(Standard_Failure) anExc = Standard_Failure::Caught();
TCollection_ExtendedString aString(anExc->DynamicType()->Name());
aString = aString + ": " + anExc->GetMessageString();
{
TObjDRAW::Init(theDI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
theDI << "Draw Plugin : All TKTObjDRAW commands are loaded" << "\n";
#endif
}
// Dimension is build on one or two shapes.
if (aGeomNum < 1 || aGeomNum > 2)
{
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeDistance: 1 or 2 geometries are needed" << endl;
#endif
NullifyAIS(theAIS);
if (aShape1.IsNull())
{
- #ifdef TPRSSTD_DEB
+ #ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeDistance : null shape" << endl;
#endif
NullifyAIS (theAIS);
if (aShape1.IsNull() || aShape2.IsNull())
{
- #ifdef TPRSSTD_DEB
+ #ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeDistance : null shape" << endl;
#endif
NullifyAIS (theAIS);
{
if (aShape1.ShapeType () != TopAbs_EDGE)
{
- #ifdef TPRSSTD_DEB
+ #ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeDistance : shape should be edge" << endl;
#endif
NullifyAIS (theAIS);
if (isCheckPlane && aPlane.IsNull())
{
- #ifdef DEB
+ #ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeDistance : null plane" << endl;
#endif
NullifyAIS (theAIS);
{
Standard_Integer nbgeom = aConst->NbGeometries();
if (nbgeom < 2) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputePerpendicular: at leat two constraintes are needed" << endl;
#endif
NullifyAIS(anAIS);
if (is_planar) GetShapesAndGeom(aConst,shape1,shape2,ageom3);
else GetTwoShapes(aConst,shape1,shape2);
if (shape1.IsNull() || shape2.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputePerpendicular : null shape" << endl;
#endif
NullifyAIS(anAIS);
if (is_planar) {
Handle(Geom_Plane) aplane = Handle(Geom_Plane)::DownCast(ageom3);
if (aplane.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputePerpendicular: nul plane" << endl;
#endif
NullifyAIS(anAIS);
{
Standard_Integer nbgeom = aConst->NbGeometries();
if (nbgeom < 2) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeParallel: at least 2 constraintes are needed" << endl;
#endif
NullifyAIS(anAIS);
}
if (!aConst->IsPlanar()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeParallel: must be a planar constraint" << endl;
#endif
NullifyAIS(anAIS);
GetShapesAndGeom(aConst,shape1,shape2,ageom3);
if (shape1.IsNull() || shape2.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeParallel : null shape" << endl;
#endif
NullifyAIS(anAIS);
}
Handle(Geom_Plane) aplane = Handle(Geom_Plane)::DownCast(ageom3);
if (aplane.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeParallel: nul plane" << endl;
#endif
NullifyAIS(anAIS);
{
Standard_Integer nbgeom = aConst->NbGeometries();
if (nbgeom < 3) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeSymmetry: at least 3 constraintes are needed" << endl;
#endif
NullifyAIS(anAIS);
Standard_Boolean is_planar(aConst->IsPlanar());
if (!is_planar) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeSymmetry: must be a planar constraint" << endl;
#endif
NullifyAIS(anAIS);
GetShapesAndGeom(aConst,shape1,shape2,shape3,ageom3);
if (shape1.IsNull() || shape2.IsNull() || shape3.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeSymmetry : null shape" << endl;
#endif
NullifyAIS(anAIS);
GetGoodShape(shape3);
Handle(Geom_Plane) aplane = Handle(Geom_Plane)::DownCast(ageom3);
if (aplane.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeSymmetry: null plane" << endl;
#endif
NullifyAIS(anAIS);
Standard_Integer nbgeom = aConst->NbGeometries();
if (nbgeom < 3)
{
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeSymmetry: at least 3 constraints are needed" << endl;
#endif
NullifyAIS(anAIS);
Standard_Boolean is_planar(aConst->IsPlanar());
if ( !is_planar )
{
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeSymmetry: must be a planar constraint" << endl;
#endif
NullifyAIS(anAIS);
if (shape1.IsNull() || shape2.IsNull() || shape3.IsNull())
{
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeSymmetry : null shape" << endl;
#endif
NullifyAIS(anAIS);
Handle(Geom_Plane) aplane = Handle(Geom_Plane)::DownCast(ageom3);
if (aplane.IsNull())
{
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeSymmetry: null plane" << endl;
#endif
NullifyAIS(anAIS);
{
Standard_Integer nbgeom = aConst->NbGeometries();
if (nbgeom < 2) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeTangent: at leat two constraintes are needed" << endl;
#endif
NullifyAIS(anAIS);
return;
}
if (!aConst->IsPlanar()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeTangent: must be a planar constraint" << endl;
#endif
NullifyAIS(anAIS);
GetShapesAndGeom(aConst,shape1,shape2,ageom3);
if (shape1.IsNull() || shape2.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeTangent : null shape" << endl;
#endif
NullifyAIS(anAIS);
GetGoodShape(shape2);
Handle(Geom_Plane) aplane = Handle(Geom_Plane)::DownCast(ageom3);
if (aplane.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeTangent: nul plane" << endl;
#endif
NullifyAIS(anAIS);
GetOneShape( aConst, shape );
if (shape.IsNull() ) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeAngleForOneFace : null shape" << endl;
#endif
NullifyAIS(anAIS);
}
}
}
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd::Compute angle : Shape is not Compound or is Null" <<endl;
#endif
return (Standard_False);
Standard_Integer nbgeom = aConst->NbGeometries();
if (nbgeom < 2) {
if( nbgeom == 1 ) { ComputeAngleForOneFace( aConst, anAIS ); return; }
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeAngle: at least 2 constraints are needed" << endl;
#endif
NullifyAIS(anAIS);
GetShapesAndGeom (aConst,shape1,shape2,ageom3);
if (shape1.IsNull() || shape2.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeAngle : null shape" << endl;
#endif
NullifyAIS(anAIS);
aFace = TopoDS::Face(shape1);
else
if(!CheckIsShapeCompound(shape1, aFace)) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "Compute angle : Geom type = " << shape1.ShapeType()
<< " non traite"<<endl;
#endif
gp_Torus aTore = aSurfaFace.Torus();
anax1aFace1 = aTore.Axis();
} else {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout<<"Compute angle"<<aTypeaFace<<" non traite"<<endl;
#endif
NullifyAIS(anAIS);
aFace = TopoDS::Face(shape2);
else
if(!CheckIsShapeCompound(shape2, aFace)) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "Compute angle : Geom type = " << shape2.ShapeType()
<< " non traite"<<endl;
#endif
gp_Torus aTore = aSurfaFace.Torus();
anax1aFace2 = aTore.Axis();
} else {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "Compute angle " << aTypeaFace << " non traite"<<endl;
#endif
NullifyAIS(anAIS);
Handle(Geom_Line) computedgeom3 = new Geom_Line (aLine);
ageom3 = computedgeom3;
} else {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout<<"Compute angle insertection of planes failed"<<endl;
#endif
NullifyAIS(anAIS);
}
} else {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout<<"Compute angle faces are //"<<endl;
#endif
NullifyAIS(anAIS);
if (ageom3->IsKind(STANDARD_TYPE(Geom_Plane))) isplan = Standard_True;
else if (ageom3->IsKind(STANDARD_TYPE(Geom_Line))) isplan = Standard_False;
else {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeAngle: unknown 3rd arg " << endl;
#endif
NullifyAIS(anAIS);
Standard_ProgramError::Raise ("TPrsStd_ConstraintTools::ComputeConcentric: at least 2 constraintes are needed");
}
if (!aConst->IsPlanar()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeConcentric: must be a planar constraint" << endl;
#endif
NullifyAIS(anAIS);
GetShapesAndGeom(aConst,shape1,shape2,ageom3);
if (shape1.IsNull() || shape2.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeConcentric : null shape" << endl;
#endif
NullifyAIS(anAIS);
//ota : to allow concentric constraint display between vertex and edge
if (shape1.ShapeType() != TopAbs_EDGE && shape2.ShapeType() != TopAbs_EDGE) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeConcentric: concentric between two vertexes : NOT DISPLAYED" << endl;;
#endif
NullifyAIS(anAIS);
Handle(Geom_Plane) aplane = Handle(Geom_Plane)::DownCast(ageom3);
if (aplane.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeConcentric: nul plane" << endl;;
#endif
NullifyAIS(anAIS);
{
Standard_Integer nbgeom = aConst->NbGeometries();
if (nbgeom < 1) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeRadius: at least one constrainte is needed" << endl;
#endif
NullifyAIS(anAIS);
TopoDS_Shape shape1 ;
GetOneShape (aConst,shape1);
if (shape1.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeRadius: null shape" << endl;
#endif
NullifyAIS(anAIS);
shape1.ShapeType()==TopAbs_COMPSOLID ||
shape1.ShapeType()==TopAbs_SOLID ||
shape1.ShapeType()==TopAbs_SHELL ) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeRadius: not good shape" << endl;
#endif
NullifyAIS(anAIS);
GetGeom(aConst,ageom2);
Handle(Geom_Plane) aplane = Handle(Geom_Plane)::DownCast(ageom2);
if (aplane.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeRadius: nul plane" << endl;
#endif
NullifyAIS(anAIS);
{
Standard_Integer nbgeom = aConst->NbGeometries();
if (nbgeom < 1) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeMinRadius: at least one constrainte is needed" << endl;
#endif
NullifyAIS(anAIS);
TopoDS_Shape shape1 ;
GetOneShape (aConst,shape1);
if (shape1.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeMinradius: null shape" << endl;
#endif
NullifyAIS(anAIS);
shape1.ShapeType()==TopAbs_COMPSOLID ||
shape1.ShapeType()==TopAbs_SOLID ||
shape1.ShapeType()==TopAbs_SHELL ) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeMinRadius: not good shape" << endl;
#endif
NullifyAIS(anAIS);
GetGeom(aConst,ageom2);
Handle(Geom_Plane) aplane = Handle(Geom_Plane)::DownCast(ageom2);
if (aplane.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeMinRadius: nul plane" << endl;
#endif
NullifyAIS(anAIS);
{
Standard_Integer nbgeom = aConst->NbGeometries();
if (nbgeom < 1) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeMaxRadius: at least one constrainte is needed" << endl;
#endif
NullifyAIS(anAIS);
TopoDS_Shape shape1 ;
GetOneShape (aConst,shape1);
if (shape1.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeMaxradius: null shape" << endl;
#endif
NullifyAIS(anAIS);
shape1.ShapeType()==TopAbs_COMPSOLID ||
shape1.ShapeType()==TopAbs_SOLID ||
shape1.ShapeType()==TopAbs_SHELL ) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeMaxRadius: not good shape" << endl;
#endif
NullifyAIS(anAIS);
GetGeom(aConst,ageom2);
Handle(Geom_Plane) aplane = Handle(Geom_Plane)::DownCast(ageom2);
if (aplane.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeMaxRadius: nul plane" << endl;
#endif
NullifyAIS(anAIS);
{
Standard_Integer nbgeom = aConst->NbGeometries();
if (nbgeom < 4) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeEqual: at least four geometries are needed" << endl;;
#endif
NullifyAIS(anAIS);
GetShapesAndGeom(aConst, aShape1, aShape2, aShape3, aShape4, aGeom);
if (aShape1.IsNull()||aShape2.IsNull()||
aShape3.IsNull()||aShape4.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeEqualDistance : null shape" << endl;
#endif
NullifyAIS(anAIS);
if (!CheckShapesPair(aShape1, aShape2) ||
!CheckShapesPair(aShape3, aShape4)){
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeEqualDistance : at least one pair of shapes is incorrect"<<endl;
#endif
NullifyAIS(anAIS);
if (!IsPlanar || aPlane.IsNull()) {
//create the plane
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout<< "The constraint plane is not assigned "<< endl;
#endif
NullifyAIS(anAIS);
gp_Dir aDir1 = aCurve1.Line().Direction();
gp_Dir aDir2 = aCurve2.Line().Direction();
if (!(aDir1.IsParallel(aDir2, Precision::Confusion()))) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << " Lines are not parallel"<<endl;
#endif
return Standard_False;
gp_Pnt aCntr1 = aCurve1.Circle().Location(); //get the circle center
gp_Pnt aCntr2 = aCurve2.Circle().Location(); //get the circle center
if (!aCntr1.IsEqual(aCntr2,Precision::Confusion())){
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << " Circles are not concentric"<<endl;
#endif
return Standard_False;
}
}
else {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "Incorrect pair of curves "<<endl;
#endif
return Standard_False;
{
gp_Pnt aCntr = aCurve.Circle().Location();
if (!aCntr.IsEqual(aPnt, Precision::Confusion())){
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << " The point doesn't coincide with the circle center"<<endl;
#endif
return Standard_False;
{
Standard_Integer nbgeom = aConst->NbGeometries();
if (nbgeom < 2) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeEqualRadius: at least two geometries are needed" << endl;;
#endif
NullifyAIS(anAIS);
GetShapesAndGeom(aConst, shape1, shape2, ageom3);
if (shape1.IsNull()||shape2.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeEqualRadius : null shape" << endl;
#endif
NullifyAIS(anAIS);
aDir1.IsParallel(aDir2, Precision::Confusion()))
aplane = aPlane2;
else {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeRadiusRelation: nul plane" << endl;
#endif
NullifyAIS(anAIS);
{
Standard_Integer nbgeom = aConst->NbGeometries();
if (nbgeom < 1) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeDiameter: at least one constrainte is needed" << endl;;
#endif
NullifyAIS(anAIS);
GetOneShape(aConst,shape1);
if (shape1.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeDiameter : null shape" << endl;
#endif
NullifyAIS(anAIS);
GetGeom(aConst,ageom2);
Handle(Geom_Plane) aplane = Handle(Geom_Plane)::DownCast(ageom2);
if (aplane.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeDiameter: nul plane" << endl;
#endif
NullifyAIS(anAIS);
{
Standard_Integer nbgeom = aConst->NbGeometries();
if (nbgeom < 1) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeFix: at least one constrainte is needed" << endl;;
#endif
NullifyAIS(anAIS);
return;
}
if (!aConst->IsPlanar()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeFix: must be a planar constraint" << endl;;
#endif
NullifyAIS(anAIS);
GetOneShape(aConst,shape1);
if (shape1.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeFix : null shape" << endl;
#endif
NullifyAIS(anAIS);
GetGeom(aConst,ageom2);
Handle(Geom_Plane) aplane = Handle(Geom_Plane)::DownCast(ageom2);
if (aplane.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeFix: nul plane" << endl;
#endif
NullifyAIS(anAIS);
if (is_planar) {
GetGeom (aConst,aplane);
if (aplane.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeOffset: null plane" << endl;
#endif
NullifyAIS(anAIS);
}
if (S1.IsNull() || S2.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeOffset: null shape" << endl;
#endif
NullifyAIS(anAIS);
BRepAdaptor_Curve CURVE(OE);
if (CURVE.GetType() == GeomAbs_Line) {
// Works only with line !!
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
Handle(Geom_Geometry) aGeomGeometry = CURVE.Curve().Curve()->Transformed(CURVE.Trsf()) ;
gp_Lin OLin = ((Handle(Geom_Line)&) aGeomGeometry)->Lin();
//#else
//#endif
TopoDS_Edge NE = TopoDS::Edge(S2);
CURVE.Initialize (NE);
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
aGeomGeometry = CURVE.Curve().Curve()->Transformed(CURVE.Trsf()) ;
gp_Lin NLin = ((Handle(Geom_Line)&)aGeomGeometry)->Lin();
//#else
}
else
if (CURVE.GetType() == GeomAbs_Circle) {
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
Handle(Geom_Geometry) aGeomGeometry = CURVE.Curve().Curve()->Transformed(CURVE.Trsf()) ;
gp_Ax1 ax = ((Handle(Geom_Circle)&) aGeomGeometry)->Circ().Axis();
//#else
BRepBuilderAPI_MakeFace MkF (w1,Standard_True);
if (MkF.IsDone()) {
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
Handle(Geom_Surface) aGeomSurface = BRep_Tool::Surface(MkF.Face());
aplane = (Handle(Geom_Plane)&) aGeomSurface ;
//#else
return;
}
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeOffset: Case not implemented" << endl;
#endif
NullifyAIS(anAIS);
TopoDS_Shape shape1,shape2 ;
GetTwoShapes(aConst,shape1,shape2);
if (shape1.IsNull() || shape2.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputePlacement: nul shape" << endl;
#endif
NullifyAIS(anAIS);
{
Standard_Integer nbgeom = aConst->NbGeometries();
if (nbgeom < 2) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeCoincident: at leat two constraintes are needed" << endl;
#endif
NullifyAIS(anAIS);
}
if (!aConst->IsPlanar()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeCoincident: must be a planar constraint" << endl;
#endif
anAIS.Nullify() ;
Handle(Geom_Plane) aplane;
GetShapesAndGeom(aConst,shape1,shape2,aplane);
if (shape1.IsNull() || shape2.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeCoincident: nul shape" << endl;
#endif
NullifyAIS(anAIS);
GetGoodShape(shape1);
GetGoodShape(shape2);
if (aplane.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeCoincident: nul plane" << endl;
#endif
NullifyAIS(anAIS);
{
Standard_Integer nbgeom = aConst->NbGeometries();
if (nbgeom < 1) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputeRound: at leat one geometry is needed" << endl;
#endif
NullifyAIS(anAIS);
TopoDS_Shape shape1;
GetOneShape (aConst,shape1);
if (shape1.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "TPrsStd_ConstraintTools::ComputePlacement: nul shape" << endl;
#endif
NullifyAIS(anAIS);
{
Handle(TNaming_NamedShape) atgeom = aConst->GetPlane();
if (atgeom.IsNull()) {
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout<<"TPrsStd_ConstraintTools::GetGeom : aConst->GetPlane().IsNull()"<<endl;
#endif
return;
if (TDataXtd_Geometry::Plane(label,aplane)) aGeom = new Geom_Plane(aplane);
else if (TDataXtd_Geometry::Line(label,anaxis)) aGeom = new Geom_Line(anaxis);
else if (TDataXtd_Geometry::Point(label,apoint)) aGeom = new Geom_CartesianPoint(apoint);
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
else {
cout << "TPrsStd_ConstraintTools::GetGeom no geom on label " << endl;
}
if ( drivertable.IsNull() )
{
drivertable = new TPrsStd_DriverTable;
-#ifdef TPRSSTD_DEB
+#ifdef OCCT_DEBUG
cout << "The new TPrsStd_DriverTable was created" << endl;
#endif
}
{
if (PHDSD != NULL) { PHDSD->SetShape1(S1);PHDSD->SetShape2(S2); }
if (PBOOP != NULL) { PBOOP->SetShape1(S1);PBOOP->SetShape2(S2); }
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopOpeBRepDS_SettraceSPSX_SS(S1,S2);
#endif
}
{
if (PHDSD != NULL) { PHDSD->SetCurrentHDS(HDS); }
if (PBOOP != NULL) { PBOOP->SetCurrentHDS(HDS); }
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopOpeBRepDS_SettraceSPSX_HDS(HDS);
#endif
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_EXPORT void debloi(const TopOpeBRepDS_ListOfInterference& L)
{
if (PBOOP == NULL) return;
SWDRAW::Init (theDI);
-#ifdef TESTTOPOPE_DEB
+#ifdef OCCT_DEBUG
cout << "Draw Plugin : All topological operations kernel commands are loaded" << endl;
#endif
}
extern Standard_Integer TOPOPE_SeeShape(char *name);
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopOpeBRepTool_KRO.hxx>
extern Standard_Boolean TopOpeBRepTool_GettraceKRO();
extern void PrintKRO_PREPA();
Standard_Integer TestTopOpe_BOOP::Builder_Perform()
{
myHB->Perform(myHDS,myS1,myS2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( TopOpeBRepTool_GettraceKRO() ) PrintKRO_PREPA();
#endif
myESP = myHDS->EdgesSameParameter();
#include <DBRep.hxx>
extern void suppressarg(Standard_Integer& na,const char** a,const Standard_Integer d);
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern void TopOpeBRepTool_SettraceEND(const Standard_Boolean);
extern Standard_Boolean TopOpeBRepTool_GettraceEND();
#endif
if (esa) {
TCollection_AsciiString s;
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopTools_ListIteratorOfListOfShape ils;
#endif
if (outdraw) {
} // TOPO
// ----------------------------------------------------------------------
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer BOOPCHK(Draw_Interpretor& ,Standard_Integer na,const char** a)
{
if (!strcmp(a[0],"tchk")) {
if (na == 1) return 0;
err = SETTOPOPREP(PT,na,a); if (err) return err;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tend = TopOpeBRepTool_GettraceEND();
TopOpeBRepTool_SettraceEND(PT.ChangeVarsTopo().GetVerbose());
#endif
if (err) return err;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopOpeBRepTool_SettraceEND(tend);
#endif
return 0;
void FUN_cout(const gp_Pnt2d& p2d, Draw_Interpretor& di)
{di <<" = ("<<p2d.X()<<" "<<p2d.Y()<<") ";}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_IMPORT void FUN_tool_coutsta(const Standard_Integer& sta, const Standard_Integer& i1, const Standard_Integer& i2);
#endif
if (w1.IsNull() || w2.IsNull() || Fref.IsNull()) return 1;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer sta =
#endif
classi.ClassiBnd2d(w1,w2,toluv,Standard_True);
di <<"wires classification : checklarge=true ";
-#ifdef DEB
+#ifdef OCCT_DEBUG
FUN_tool_coutsta(sta,1,2);
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
sta =
#endif
classi.ClassiBnd2d(w1,w2,toluv,Standard_False);
di <<"wires classification : checklarge=false ";
-#ifdef DEB
+#ifdef OCCT_DEBUG
FUN_tool_coutsta(sta,1,2);
#endif
Standard_Real dist=0.; gp_Pnt2d uv; Standard_Boolean ok = FUN_tool_projPonF(p,f,uv,dist);
if (!ok) {di<<"projection failed"<<"\n"; return 1;}
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Vec ngf =
#endif
FUN_tool_nggeomF(uv,f);
return r;
}
-#ifdef TESTTOPOPE_DEB
+#ifdef OCCT_DEBUG
Standard_Integer iS = myHDS->Shape(S,FindKeep);
cout<<endl<<"***** shape "<<iS<<" has no ancestor index : use shapemaps"<<endl;
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopOpeBRepTool_KRO.hxx>
Standard_IMPORT TOPKRO KRO_DSFILLER_TOTAL;
Standard_IMPORT TOPKRO KRO_DSFILLER_INTFF;
di<<pV.X()<<" "<<pV.Y()<<" "<<pV.Z()<<"\n";
return 0;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <Draw_Chronometer.hxx>
Standard_IMPORT Standard_Boolean Draw_Chrono;
Standard_Integer CHROBOOP(Draw_Interpretor& di, Standard_Integer n, const char** a)
theCommands.Add("mksol","make a solid [1] with [2] ...",__FILE__,MKSOLSHE,g);
theCommands.Add("mkshe","make a shell [1] with [2] ...",__FILE__,MKSOLSHE,g);
theCommands.Add("getp3d","getp3d vertex",__FILE__,GETP3D,g);
-#ifdef DEB
+#ifdef OCCT_DEBUG
theCommands.Add("chroboop","",__FILE__,CHROBOOP,g);
#endif
}
--
-- All of the Trace controls in top.ope. kernel
-- are enclosed by the C conditional compilation statements :
--- #ifdef DEB ... #endif
+-- #ifdef OCCT_DEBUG ... #endif
--
-- The "Traced" packages of topological operation kernel are :
-- - TopBuild
#include <Draw_Appli.hxx>
#include <TopOpeBRepTool_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
TestTopOpeTools_Trace theTrace(100,"trace");
TestTopOpeTools_Trace theContext(100,"context");
Standard_IMPORT void TopOpeBRepDS_SetcontextMKTONREG(const Standard_Boolean);
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
//----------------------------------------------------------------------------
static Standard_Integer InitTraceTopOpeKernel (TestTopOpeTools_Trace& T)
//----------------------------------------------------------------------------
return 0;
}
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
//----------------------------------------------------------------------------
Standard_Integer InitContextTopOpeKernel (TestTopOpeTools_Trace& T)
//----------------------------------------------------------------------------
//=========================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer TestTopOpeTools_SetTrace(Draw_Interpretor&, Standard_Integer n ,const char** a)
#else
Standard_Integer TestTopOpeTools_SetTrace(Draw_Interpretor&, Standard_Integer,const char**)
#endif
{
Standard_Integer ok = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
InitTraceTopOpeKernel(theTrace);
Standard_Integer mute = 0; if (!strcasecmp(a[0],"trcmute")) mute = 1;
ok = TestTopOpeTools_SetFlags(theTrace,mute,n,a);
// a1 = flag (for example tbs) <a2> = value, if omitted flag becomes True
//=========================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer TestTopOpeTools_SetContext(Draw_Interpretor&, Standard_Integer n ,const char** a)
{
Standard_Integer ok = Standard_True;
void TopClass_Classifier3d::Compare(const TopoDS_Face& Face,
const TopAbs_Orientation) {
if(!isSet) {
-#ifdef TOPCLASS_DEB
+#ifdef OCCT_DEBUG
cout<<" Call to TopClass_Classifier3d::Compare without a Reset ! ";
#endif
return;
myFace = myIntersector.Face();
if(Abs(myParam)<=myTolerance) {
//-- #########################################
-#ifdef TOPCLASS_DEB
+#ifdef OCCT_DEBUG
cout<<" myParam = "<<myParam<<" ds TopClass_Classifier3d.gxx "<<endl;
#endif
//-- #########################################
else if(myIntersector.Transition() == IntCurveSurface_In) {
myState = TopAbs_OUT;
}
-#ifdef TOPCLASS_DEB
+#ifdef OCCT_DEBUG
else {
cout<<" -------- Probleme ds TopClass_Classifier3d.gxx "<<endl;
}
//-- TopClass_SolidClassifier.gxx
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_EXPORT Standard_Boolean TopClass_GettraceFC();
#endif
void TopClass_SolidClassifier::Perform(TheSolidExplorer& SolidExplorer,
const gp_Pnt& P,
const Standard_Real Tol) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trace = TopClass_GettraceFC();
#endif
parmin = Intersector.WParameter();
if(Abs(parmin)<=Tol) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trace) {
//-- #########################################
cout<<" parmin = "<<parmin<< " avec Par = "<<Par;
myState = 4; //-- OUT --
}
else {
-#ifdef TOPCLASS_DEB
+#ifdef OCCT_DEBUG
cout<<"*Probleme ds TopClass_SolidClassifier.gxx"<<endl;
#endif
}
myState = 4; //-- OUT --
}
else {
-#ifdef TOPCLASS_DEB
+#ifdef OCCT_DEBUG
cout<<"*Probleme ds TopClass_SolidClassifier.gxx "<<endl;
#endif
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
//-- #########################################
// cout<<" Intersector.State() == TopAbs_ON";
// cout<<" ds TopClass_SolidClassifier.gxx "<<endl;
}
} //-- Exploration of the shells
-#ifdef DEB
+#ifdef OCCT_DEBUG
//#################################################
SolidExplorer.DumpSegment(P,L,parmin,State());
//#################################################
return TopAbs_INTERNAL;
else if (Aft == TopAbs_OUT)
return TopAbs_REVERSED;
-#ifdef TOPCNX_DEB
+#ifdef OCCT_DEBUG
else
cout << "\n*** Complex Transition : unprocessed state"<<endl;
#endif
return TopAbs_FORWARD;
else if (Aft == TopAbs_OUT)
return TopAbs_EXTERNAL;
-#ifdef TOPCNX_DEB
+#ifdef OCCT_DEBUG
else
cout << "\n*** Complex Transition : unprocessed state"<<endl;
#endif
}
-#ifdef TOPCNX_DEB
+#ifdef OCCT_DEBUG
else
cout << "\n*** Complex Transition : unprocessed state"<<endl;
#endif
extern void BREP_mergePDS(const Handle(TopOpeBRepDS_HDataStructure)& HDS);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_EXPORT void debcomplete(){};
Standard_EXPORT void debcompleteds(){};
static int Vdebfillerds=0;void debfillerds(void){Vdebfillerds++;}
Standard_Real par1 = CPI1->Parameter();
Standard_Real par2; Standard_Boolean ok = FUN_tool_parE(e1,par1,e2,par2);
if (!ok) {
-#ifdef TOPOPEBREP_DEB
+#ifdef OCCT_DEBUG
cout<<"**********TopOpeBRep FUN_shareNOG**********"<<endl;
#endif
return Standard_False;
{
InsertIntersection(aS1,aS2,HDS,orientFORWARD);
Complete(HDS);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceEND()) cout<<"DSFiller::Insert"<<endl;
#endif
} // Insert
if (myPShapeClassifier == NULL) myPShapeClassifier = new TopOpeBRepTool_ShapeClassifier();
myFacesFiller.SetPShapeClassifier(myPShapeClassifier);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tsiff = TopOpeBRep_GettraceSIFF();
Standard_Boolean tkro = TopOpeBRepTool_GettraceKRO();
if (tsiff) SIFF.Start("DSFiller debut tsif ",cout);
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
debfillerreset(); // debug
#endif
myShapeIntersector.InitIntersection(S1,S2);
while (myShapeIntersector.MoreIntersection()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer i1deb = myShapeIntersector.Index(1);
Standard_Integer i2deb = myShapeIntersector.Index(2);
Standard_Boolean b1deb = TopOpeBRep_GettraceSHA(i1deb);
}
if (isFF) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tsiff) SIFF.Add(i1deb,i2deb); debfillerff();
#endif
TopOpeBRep_FacesIntersector& FF=myShapeIntersector.ChangeFacesIntersector();
lFF2 = FF.Face(2);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (isFFsamdom) debfillerffsd(); // debug
Standard_Integer exf1 = myShapeIntersector.Index(1);
Standard_Integer exf2 = myShapeIntersector.Index(2);
}
else if ((t1 == TopAbs_EDGE) && (t2 == TopAbs_EDGE)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
debfilleree(); // debug
#endif
TopOpeBRep_EdgesIntersector& EE =
myShapeIntersector.ChangeEdgesIntersector();
EE.Dimension(2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean EEsamedomain =
#endif
EE.SameDomain();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (EEsamedomain) debfillereesd(); // debug
#endif
if ( islFFsamdom ) {
}
else if ((t1 == TopAbs_FACE) && (t2 == TopAbs_EDGE)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
debfillerfe(); // debug
#endif
TopOpeBRep_FaceEdgeIntersector& FE =
}
else if ((t1 == TopAbs_EDGE) && (t2 == TopAbs_FACE)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
debfilleref(); // debug
#endif
TopOpeBRep_FaceEdgeIntersector& FE =
FDSCNX_Prepare(aS1,aS2,HDS);
FDSSDM_prepare(HDS);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tkro) KRO_DSFILLER_TOTAL.Stop();if (tsiff) SIFF.End("DSFiller fin tsif ",cout);
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceEND()) cout<<"DSFiller::InsertIntersection"<<endl;
#endif
//=======================================================================
void TopOpeBRep_DSFiller::Complete(const Handle(TopOpeBRepDS_HDataStructure)& HDS)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
debcomplete();
#endif
GapFiller(HDS);
Reducer(HDS);
RemoveUnsharedGeometry(HDS);
Checker(HDS);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceEND()) cout<<"DSFiller::Complete"<<endl;
#endif
} // Complete
void TopOpeBRep_DSFiller::GapFiller(const Handle(TopOpeBRepDS_HDataStructure)& HDS) const
{
TopOpeBRepDS_GapFiller GF(HDS); GF.Perform();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceEND()) cout<<"DSFiller::GapFiller"<<endl;
#endif
}
//=======================================================================
void TopOpeBRep_DSFiller::CompleteDS(const Handle(TopOpeBRepDS_HDataStructure)& HDS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
debcompleteds();
#endif
const TopoDS_Shape& S1 = myShapeIntersector.Shape(1);
FUN_ds_completeforE7(HDS); // xpu130898,
FUN_ds_completeforSE9(HDS); // xpu011098
FUN_ds_complete1dForSESDM(HDS); // MSV 25.03.2002 : OCC251
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceEND()) cout<<"DSFiller::CompleteDS"<<endl;
#endif
} // CompleteDS
TopOpeBRepDS_Filter F(HDS);
F.ProcessEdgeInterferences();
F.ProcessCurveInterferences();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceEND()) cout<<"DSFiller::Filter"<<endl;
#endif
} // Filter
{
TopOpeBRepDS_Reducer R(HDS);
R.ProcessEdgeInterferences();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceEND()) cout<<"DSFiller::Reducer"<<endl;
#endif
} // Reducer
void TopOpeBRep_DSFiller::RemoveUnsharedGeometry(const Handle(TopOpeBRepDS_HDataStructure)& HDS)
{
Standard_Boolean processNOG = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GetcontextNONOG()) processNOG = Standard_False;
#endif
if (!processNOG) return;
}
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceEND()) cout<<"DSFiller::RemoveUnsharedGeometry"<<endl;
#endif
} // RemoveUnsharedGeometry
void TopOpeBRep_DSFiller::Checker(const Handle(TopOpeBRepDS_HDataStructure)& /*HDS*/) const
{
// TopOpeBRepDS_Checker C(HDS); // NYI
- //#ifdef DEB
+ //#ifdef OCCT_DEBUG
// if (TopOpeBRepTool_GettraceEND()) cout<<"DSFiller::Checker"<<endl;
//#endif
}
{
InsertIntersection2d(aS1,aS2,HDS);
CompleteDS2d(HDS);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceEND()) cout<<"DSFiller::Insert2d"<<endl;
#endif
} // Insert
BREP_correctgbound(HDS);
BREP_mergePDS(HDS);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceEND()) cout<<"DSFiller::InsertIntersection2d"<<endl;
#endif
TopOpeBRepDS_Reducer R(HDS);
R.ProcessEdgeInterferences();
// TopOpeBRepDS_Checker C(HDS); // NYI
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceEND()) cout<<"DSFiller::CompleteDS2d"<<endl;
#endif
} // CompleteDS2d
Standard_Boolean TopOpeBRep_DSFiller::IsContext1d(const TopoDS_Shape& aS) const
{
Standard_Boolean is1d = IsMadeOf1d(aS);
-#ifdef TOPOPEBREP_DEB
+#ifdef OCCT_DEBUG
if ( is1d ) cout<<"TopOpeBRep_DSFiller : 1d"<<endl;
#endif
if ( !is1d ) return Standard_False;
Standard_Boolean TopOpeBRep_DSFiller::CheckInsert(const TopoDS_Shape& aS1,const TopoDS_Shape& aS2) const
{
if (aS1.IsEqual(aS2)) {
-#ifdef TOPOPEBREP_DEB
+#ifdef OCCT_DEBUG
cout<<"TopOpeBRep_DSFiller : CheckInsert : S1 == S2"<<endl;
#endif
return Standard_False;
#include <TopOpeBRep_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopOpeBRepDS_reDEB.hxx>
extern Standard_Boolean TopOpeBRepDS_GettraceEDSF();
extern Standard_Boolean TopOpeBRepDS_GettraceDSF();
myLI2.Clear();
myHDS = HDS;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceDSF();
trc = trc || TopOpeBRepDS_GettraceEDSF();
trc = trc || TopOpeBRep_GettraceEEFF();
if ( ! myF1.IsNull() ) myPDS->AddShape(myF1,1);
if ( ! myF2.IsNull() ) myPDS->AddShape(myF2,2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean pointofsegment = P2D.IsPointOfSegment();
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
if (pointofsegment && esd) debposesd();
else if (pointofsegment && !esd) debposnesd();
TopoDS_Vertex V2; if (isvertex2) V2 = P2D.Vertex(2);
Standard_Boolean isvertex = isvertex1 || isvertex2;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (isvertex1 && isvertex2) {
gp_Pnt P3D1 = BRep_Tool::Pnt(V1);
gp_Pnt P3D2 = BRep_Tool::Pnt(V2);
Standard_Boolean faulty = (isvertex && isnewpoint) || (!isvertex && isnewvertex);
if (faulty) {
-#ifdef TOPOPEBREP_DEB
+#ifdef OCCT_DEBUG
Standard_Boolean foundvertex = (found) && (K == TopOpeBRepDS_VERTEX);
cout<<"- - - faulty EdgesFiller : G "<<G<<" K ";TopOpeBRepDS::Print(K,cout);cout.flush();
cout<<" isvertex="<<isvertex;cout.flush();
Standard_Boolean condcpi = ((ki==TopOpeBRepDS_POINT) && (gi==G) && iscpi);
if (condcpi) { // remplacer G,K de I par le vertex courant
-#ifdef DEB
+#ifdef OCCT_DEBUG
rototo();
#endif
Handle(TopOpeBRepDS_CurvePointInterference) epi = Handle(TopOpeBRepDS_CurvePointInterference)::DownCast(I);
const TopOpeBRepDS_Kind& kevi = epi->SupportType();
evi->SupportType(kevi);
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopOpeBRepDS::Print(K,G,cout,"TopOpeBRep_EdgesFiller : remplacer "," ");
TopOpeBRepDS::Print(TopOpeBRepDS_VERTEX,gevi,cout,"par "," dans les courbes NYI\n");
#endif
TopOpeBRepDS_TKI tki; tki.FillOnGeometry(LI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer EIX = myPDS->Shape(E); Standard_Boolean TRC=DSREDUEDGETRCE(EIX);
if (TRC) cout<<endl<<"RecomputeInterferences E"<<EIX<<" <- "<<LI.Extent()<<endl;
if (TRC) tki.DumpTKIIterator("","\n");
Standard_Integer nloi = loi.Extent();
if (nloi == 0) continue;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (nloi > 1) {cout<<"TopOpeBRep_EdgesFiller : > 1 I on UNUN/F on E"<<EIX<<" A FAIRE"<<endl;}
#endif
Standard_Integer ifb = TU.IndexBefore();
const TopoDS_Face& fb = TopoDS::Face(myPDS->Shape(ifb));
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer ifa = TU.IndexAfter();
if (ifb != ifa) {cout<<"TopOpeBRep_EdgesFiller : ifb != ifa on E"<<EIX<<" NYI"<<endl;}
#endif
TN.ShapeBefore(TU.ShapeBefore());TN.IndexBefore(TU.IndexBefore());
TN.ShapeAfter(TU.ShapeAfter());TN.IndexAfter(TU.IndexAfter());
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean ok =
#endif
FDS_stateEwithF2d(*myPDS,E,pE,K,G,fb,TN);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) {
TopOpeBRepDS_ListOfInterference l1;l1.Append(iloi);
TopOpeBRepDS_TKI dt;dt.FillOnGeometry(l1);dt.DumpTKIIterator("","");
#include <TopOpeBRep_Point2d.hxx>
#include <TopOpeBRep_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepTool_GettraceNYI();
extern Standard_Boolean TopOpeBRepTool_GettraceKRO();
extern Standard_Boolean TopOpeBRepDS_GettraceEDSF();
myTol2 = (myTol2 > 1.e-4)? 1.e-4: myTol2;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer DEBi = 0;
if ( DEBi ) {
cout<<"TopOpeBRep_EdgesIntersector::SetFaces : ";
tole = BRep_Tool::Tolerance(myEdge1);
myDomain1.SetValues(pfirst,first,tole,plast,last,tole);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = Standard_False;
if (trc) {
cout<<"ed1 on fa1 : {pfirst=("<<pfirst.X()<<" "<<pfirst.Y()<<"), first="<<first<<"\n";
tole = BRep_Tool::Tolerance(myEdge2);
myDomain2.SetValues(pfirst,first,tole,plast,last,tole);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
cout<<"ed2 on fa1 : {pfirst=("<<pfirst.X()<<" "<<pfirst.Y()<<"), first="<<first<<"\n";
cout<<" plast =("<<plast.X()<<" "<<plast.Y()<<"),last="<<last<<"}"<<endl;}
PC2on1->D0(first,pfirst);
PC2on1->D0(last,plast);
myDomain2.SetValues(pfirst,first,tole,plast,last,tole);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( TopOpeBRep_GettracePROEDG() ) {
cout<<"------------ projection de curve"<<endl;
cout<<"--- Curve : "<<endl;
}
// compute the intersection
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceKRO()) KRO_DSFILLER_INTEE.Start();
#endif
// Wrong !!!
/* if ( !myTolForced ) {
if ( t1 != t2 ) {
- //#ifdef DEB // JYL 28/09/98 : temporaire
+ //#ifdef OCCT_DEBUG // JYL 28/09/98 : temporaire
//if ( TopOpeBRep_GetcontextTOL0() ) { // JYL 28/09/98 : temporaire
tol1 = 0.; // JYL 28/09/98 : temporaire
tol2 = 0.; // JYL 28/09/98 : temporaire
}
*/
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GettraceFITOL()) {
cout<<"EdgesIntersector : Perform";
#ifdef DRAW
for (Standard_Integer s=1; s<=nbs; s++) mylseg.Append(myIntersector.Segment(s));
Standard_Boolean filter = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean nofilter = TopOpeBRep_GetcontextNOFEI(); if (nofilter) filter = Standard_False;
#endif
const IntRes2d_IntersectionPoint& P2=mylpnt.Value(p+1);
if( TransitionEqualAndExtremity(P1.TransitionOfFirst(),P2.TransitionOfFirst())
|| TransitionEqualAndExtremity(P1.TransitionOfSecond(),P2.TransitionOfSecond()) ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC = Standard_True;
if (TRC) cout<<"\n Egalite de transitions \n"<<endl;
#endif
myTrueNbPoints = myNbPoints + 2 * myNbSegments;
myPointIndex = 0;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GettraceEEFF()) debeeff();
#endif
TopOpeBRepDS_Transition& T1 = P2D.ChangeTransition(1);
TopOpeBRepDS_Transition& T2 = P2D.ChangeTransition(2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean newT1=Standard_False, newT2=Standard_False;
#endif
Standard_Boolean isvertex12 = isvertex1 && isvertex2;
const TopoDS_Vertex& V2 = P2D.Vertex(2);
TopOpeBRepDS_Transition newT; Standard_Boolean computed = ::EdgesIntersector_checkT1D(myEdge1,myEdge2,V2,newT);
if (computed) T1.Set(newT.Orientation(TopAbs_IN));
-#ifdef DEB
+#ifdef OCCT_DEBUG
else newT1 = Standard_False;
#endif
}
const TopoDS_Vertex& V1 = P2D.Vertex(1);
TopOpeBRepDS_Transition newT; Standard_Boolean computed = ::EdgesIntersector_checkT1D(myEdge2,myEdge1,V1,newT);
if (computed) T2.Set(newT.Orientation(TopAbs_IN));
-#ifdef DEB
+#ifdef OCCT_DEBUG
else newT2 = Standard_False;
#endif
}
Standard_Boolean nT2 = ( !T2INT && clE1 && isvertex11 && vcl1.IsSame(P2D.Vertex(1)) );
if (nT2) T2.Set(TopAbs_INTERNAL);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc&&(newT1||nT1)) {cout<<"-> ** newT on e(1) = ";T1.Dump(cout);cout<<endl;}
if (trc&&(newT2||nT2)) {cout<<"-> ** newT on e(2) = ";T2.Dump(cout);cout<<endl;}
#endif
} // MorePoint
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceKRO()) KRO_DSFILLER_INTEE.Stop();
#endif
} // Perform
return SetSameDomain(Standard_True);
if (t1 != GeomAbs_Circle) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceNYI())
cout<<"TopOpeBRep_EdgesIntersector : EdgesSameDomain on NYI curve type"<<endl;
#endif
Standard_Boolean condredu = (myHasSegment && !mySameDomain);
if (!condredu) return;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceDSF(); trc = trc || TopOpeBRepDS_GettraceEDSF();
if (trc) Dump("AVANT ReduceSegments");
#endif
//function : Dump
//purpose :
//=======================================================================
-#ifndef DEB
+#ifndef OCCT_DEBUG
void TopOpeBRep_EdgesIntersector::Dump(const TCollection_AsciiString& ,const Standard_Integer ,const Standard_Integer )
{
#else
#include <TopOpeBRep_define.hxx>
#include <IntPatch_GLine.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceDSNC();
extern Standard_Boolean TopOpeBRepDS_GettraceDSF();
extern Standard_Boolean TopOpeBRepDS_GettraceDSFK();
//function : TopOpeBRep_FFDumper
//purpose :
//=======================================================================
-#ifndef DEB
+#ifndef OCCT_DEBUG
TopOpeBRep_FFDumper::TopOpeBRep_FFDumper(const TopOpeBRep_PFacesFiller& )
{
#else
//function : Init
//purpose :
//=======================================================================
-#ifndef DEB
+#ifndef OCCT_DEBUG
void TopOpeBRep_FFDumper::Init(const TopOpeBRep_PFacesFiller& )
{
#else
//function : DumpLine
//purpose :
//=======================================================================
-#ifndef DEB
+#ifndef OCCT_DEBUG
void TopOpeBRep_FFDumper::DumpLine(const Standard_Integer )
{
#else
//function : DumpLine
//purpose :
//=======================================================================
-#ifndef DEB
+#ifndef OCCT_DEBUG
void TopOpeBRep_FFDumper::DumpLine(const TopOpeBRep_LineInter& )
{
#else
//function : DumpVP
//purpose :
//=======================================================================
-#ifndef DEB
+#ifndef OCCT_DEBUG
void TopOpeBRep_FFDumper::DumpVP(const TopOpeBRep_VPointInter& )
{
#else
//function : DumpVP
//purpose :
//=======================================================================
-#ifndef DEB
+#ifndef OCCT_DEBUG
void TopOpeBRep_FFDumper::DumpVP(const TopOpeBRep_VPointInter& ,const Standard_Integer )
{
#else
//function : ExploreIndex
//purpose :
//=======================================================================
-#ifndef DEB
+#ifndef OCCT_DEBUG
Standard_Integer TopOpeBRep_FFDumper::ExploreIndex(const TopoDS_Shape& , const Standard_Integer ) const
{
return 0;
//function : DumpDSP
//purpose :
//=======================================================================
-#ifndef DEB
+#ifndef OCCT_DEBUG
void TopOpeBRep_FFDumper::DumpDSP(const TopOpeBRep_VPointInter& ,const TopOpeBRepDS_Kind ,const Standard_Integer ,
const Standard_Boolean ) const
{
#include <GeomAPI_ProjectPointOnCurve.hxx>
#include <gp_Vec.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceDSF();
#endif
case IntSurf_Outside : result = TopAbs_EXTERNAL; break;
case IntSurf_Unknown :
Odefined = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// if ( TopOpeBRepDS_GettraceDSF() ) {
// cout<<"TopOpeBRepDS:TransitionToOrientation : unknown situation"<<endl;
// }
case IntSurf_Undecided :
Odefined = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// if ( TopOpeBRepDS_GettraceDSF() ) {
// cout<<"TopOpeBRepDS:TransitionToOrientation : undecided transition"<<endl;
// }
case IntSurf_Unknown :
Odefined = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( TopOpeBRepDS_GettraceDSF() ) {
cout<<"ProcessFaceTransition : unknown situation"<<endl;
}
case IntSurf_Undecided :
Odefined = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( TopOpeBRepDS_GettraceDSF() ) {
cout<<"ProcessFaceTransition : undecided transition"<<endl;
}
res = Standard_True;
}
}
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
// return res; // BUG ???
//#else
return (Standard_Boolean ) res ;
#include <TopoDS_Edge.hxx>
#include <gp_Pnt2d.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern void FEINT_DUMPPOINTS(TopOpeBRep_FaceEdgeIntersector& FEINT,
const TopOpeBRepDS_DataStructure& BDS);
extern Standard_Boolean TopOpeBRepDS_GettraceDSF();
const TopoDS_Face& FF = TopoDS::Face(F);
const TopoDS_Edge& EE = TopoDS::Edge(E);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceDSF()) {
FEINT_DUMPPOINTS(FEINT,HDS->DS());
}
gp_Pnt2d pUV; FEINT.UVPoint(pUV);
Standard_Real parE = FEINT.Parameter();
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopOpeBRepDS_Transition TFF =
#endif
FEINT.Transition(1,EEori); // EEori bidon = EXTERNAL
// append I to list LI
LI.Append(I);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean appendtoG = Standard_False;
#endif
Standard_Integer G = I->Geometry();
break;
case TopOpeBRepDS_SURFACE :
-#ifdef DEB
+#ifdef OCCT_DEBUG
appendtoG = Standard_True;
#endif
BDS.ChangeSurfaceInterferences(G).Append(I);
break;
case TopOpeBRepDS_CURVE :
-#ifdef DEB
+#ifdef OCCT_DEBUG
appendtoG = Standard_True;
#endif
BDS.ChangeCurveInterferences(G).Append(I);
break;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceDSF()) {
cout<<"append "; I->Dump(cout);
if (appendtoG) cout<<" and to G"<<G<<" list";
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TCollection_AsciiString.hxx>
#include <TopOpeBRep_FaceEdgeIntersector.hxx>
#include <Precision.hxx>
#include <Standard_ProgramError.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopAbs.hxx>
extern Standard_Boolean TopOpeBRep_GettraceFITOL();
extern Standard_Boolean TopOpeBRep_GettraceSAVFF();
ResetIntersection();
if (!myForceTolerance) ShapeTolerances(SF,SE);
myTol = BRep_Tool::Tolerance(TopoDS::Edge(SE));
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GettraceFITOL()) cout<<"Perform : myTol = "<<myTol<<endl;
#endif
myFace = TopoDS::Face(SF); myFace.Orientation(TopAbs_FORWARD);
myEdge = TopoDS::Edge(SE); myEdge.Orientation(TopAbs_FORWARD);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GettraceSAVFF()) SAVFE(myFace,myEdge);
#endif
myCurve.Load(*PGCao1,f,l);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceKRO()) KRO_DSFILLER_INTFE.Start();
#endif
BRepIntCurveSurface_Inter FEINT;
FEINT.Init(myFace,myCurve,myTol);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceKRO()) KRO_DSFILLER_INTFE.Stop();
#endif
myTol = Tol;
myForceTolerance = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GettraceFITOL())
cout<<"ForceTolerance : myTol = "<<myTol<<endl;
#endif
Standard_Integer TopOpeBRep_FaceEdgeIntersector::Index() const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
return myPointIndex;
#else
return 0;
myTol = Max(ToleranceMax(S1,TopAbs_EDGE),ToleranceMax(S2,TopAbs_EDGE));
myForceTolerance = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GettraceFITOL()) {
cout<<"ShapeTolerances on S1 = ";TopAbs::Print(S1.ShapeType(),cout);
cout<<" S2 = ";TopAbs::Print(S2.ShapeType(),cout);
return paramLdef;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceDSF();
extern Standard_Boolean TopOpeBRepDS_GettraceDSFK();
extern Standard_Boolean TopOpeBRepDS_GettraceDSNC();
TopOpeBRep_FacesFiller::TopOpeBRep_FacesFiller() : myPShapeClassifier(NULL)
{
myexF1 = myexF2 = 0;
-#ifdef DEB
+#ifdef OCCT_DEBUG
myHFFD = new TopOpeBRep_FFDumper(this);
#endif
}
myDS = &(HDS->ChangeDS());
if (myPShapeClassifier == NULL) myPShapeClassifier = new TopOpeBRepTool_ShapeClassifier();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer exF1,exF2; GetTraceIndex(exF1,exF2);
myFacesIntersector->InitLine();
for (; myFacesIntersector->MoreLine(); myFacesIntersector->NextLine()) myFacesIntersector->CurrentLine().SetTraceIndex(exF1,exF2);
TopOpeBRep_TypeLineCurve t = L.TypeLineCurve();
Standard_Integer nbvp = L.NbVPoint();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TDSF = TopOpeBRepDS_GettraceDSF();
if (TDSF) { cout<<"CheckLine ";TopOpeBRep::Print(t,cout);cout<<" "<<nbvp<<" points"<<endl; }
#endif
if ( t == TopOpeBRep_WALKING ) {
if ( nbvp < 2 ) {
-#ifdef TOPOPEBREP_DEB
+#ifdef OCCT_DEBUG
cout<<"\n=== Nb de IntPatch_Point sur WL incorrect : "<<nbvp<<" ===\n";
#endif
check = Standard_False;
if (isBV1) V2 = B.VertexOnS1();
if (isBV2) V2 = B.VertexOnS2();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TDSF) {
cout<<"CheckLine : isAV1 isAV2 isBV1 isBV2 ";
cout<<isAV1<<" "<<isAV2<<" "<<isBV1<<" "<<isBV2<<endl;
#endif
if ( !V1.IsNull() && ( V1.IsSame(V2) ) ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Real parA = A.ParameterOnLine();
Standard_Real parB = B.ParameterOnLine();
if (TDSF) {
}
}
-#ifdef TOPOPEBREP_DEB
+#ifdef OCCT_DEBUG
if (!check) { cout<<"# DEB CheckLine : rejet de ";TopOpeBRep::Print(t,cout);cout<<" a "<<nbvp<<" points"<<endl; }
#endif
void TopOpeBRep_FacesFiller::VP_Position(TopOpeBRep_LineInter& L)
{
myLine = &L;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceDSFK()) {
cout<<endl<<"VP_Position on line "<<L.Index()<<" ";L.DumpType();cout<<endl;
}
L.SetVPBounds();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceDSFK()) {
Standard_Integer VPF,VPL,VPN; L.VPBounds(VPF,VPL,VPN);
cout<<"SetVPBounds : VPF,VPL,VPN = "<<VPF<<","<<VPL<<","<<VPN;
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceDSFK()) {
cout<<"VP "<<VP.Index()<<" on "<<Esi<<" : ";
TopAbs::Print(VP.State(Esi),cout);
if (c1) VPC.VPointPosition(myF1,VP,1,myPointClassifier,AssumeINON,tol);
if (c2) VPC.VPointPosition(myF2,VP,2,myPointClassifier,AssumeINON,tol);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceDSFK()) {
cout<<"VP "<<VP.Index()<<" on "<<si<<" : ";
if (c1) { TopAbs::Print(VP.State(1),cout);cout<<"/1 "; }
#include <TopOpeBRep_DRAW.hxx>
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_EXPORT void debrest(const Standard_Integer i) {cout<<"+ debrest "<<i<<endl;}
Standard_EXPORT void debrline() {cout<<"+ debrline"<<endl;}
if (reject) return;
ResetDSC();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer ili = myLine->Index(),nli = myFacesIntersector->NbLines();
Standard_Boolean tcx = TopOpeBRepDS_GettraceCX(ili);
Standard_Boolean tDSF = TopOpeBRepDS_GettraceDSF();
myHDS->SortOnParameter(myDSCIL);
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopOpeBRepDS_Dumper Dumper(myHDS);
if (tDSF||traceDSNC) Dumper.DumpLOI(myDSCIL,cout,"current curve : ");
#endif
//=======================================================================
void TopOpeBRep_FacesFiller::ProcessVPnotonR(const TopOpeBRep_VPointInter& VP)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean traceDSF = TopOpeBRepDS_GettraceDSF();
Standard_Boolean traceDSP = TopOpeBRepDS_GettraceDSP();
Standard_Boolean traceISTO = TopOpeBRepDS_GettraceISTO();
Standard_Integer ShapeIndex = 0;
Standard_Integer iVP = VP.Index();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer ili=myLine->Index(),ivp=iVP,isi=ShapeIndex;
if(traceDSF || traceDSP){
cout<<"trc tnvp 1 "<<myexF1<<" "<<myexF2<<" "<<ili<<" "<<ivp<<" "<<isi;
Standard_Boolean CPIfound = GetGeometry(itCPIL,VP,PVIndex,PVKind);
if ( !CPIfound ) {
if (iVP != iINON1 && iVP != iINONn) {
-#ifdef TOPOPEBREP_DEB
+#ifdef OCCT_DEBUG
cout<<"VP "<<iVP<<" on "<<0<<" : point d'intersection anormal : rejet"<<endl;
#endif
return;
//=======================================================================
void TopOpeBRep_FacesFiller::ProcessRLine()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tDSF = TopOpeBRepDS_GettraceDSF();
#endif
Standard_Integer rank = myDS->AncestorRank(iErest);
Standard_Integer OOrank = (rank == 1)? 2: 1;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tDSF) {cout<<"+ edge restriction "<<myDS->SectionEdge(Erest);
cout<<" (DS "<<iErest<<")"<<endl;}
Standard_Boolean trce = TopOpeBRepDS_GettraceSPSX(iErest); if(trce) debrest(iErest);
Standard_Boolean T1unk = T1.IsUnknown();
Standard_Boolean T2unk = T2.IsUnknown();
Standard_Boolean processUNK = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean nopunk = TopOpeBRep_GetcontextNOPUNK();
if (nopunk) processUNK = Standard_False;
#endif
if (processUNK && (T1unk || T2unk)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSTRANGE(); trc = trc || tDSF;
if (trc) cout<<"T UNKNOWN FEI F"<<iF1<<" F"<<iF2<<" on Erest"<<iErest<<endl;
#endif
if (OOTok) {
if (OOrank == 1) FDS_SetT(T1,T);
else FDS_SetT(T2,T);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
cout<<"F"<<iOOF<<" + new FEI(";TopAbs::Print(T.Before(),cout);cout<<",";
TopAbs::Print(T.After(),cout);cout<<" (F"<<iF<<") (E"<<iErest<<"))\n";
if (Tok) {
if (rank == 1) FDS_SetT(T1,T);
else FDS_SetT(T2,T);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"F"<<iF<<" + new FEI(";TopAbs::Print(T.Before(),cout);cout<<",";
TopAbs::Print(T.After(),cout);cout<<" (F"<<iOOF<<") (E"<<iErest<<"))\n";}
#endif
VPI.Init((*myLine));
Standard_Real tola = Precision::Angular()*1.e5;//NYIXPUTOL
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tDSF) {
debrline();
cout<<endl<<"------------ Rline processing --------------------"<<endl;
const TopOpeBRep_VPointInter& vpf = VPI.CurrentVP();
for (; VPI.More(); VPI.Next()) {
const TopOpeBRep_VPointInter& VP = VPI.CurrentVP();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tDSF) {cout<<endl;myHFFD->DumpVP(VP);}
#endif
Standard_Integer absindex = VP.ShapeIndex(); // 0,1,2,3
Standard_Integer obOO = TopOpeBRepTool_TOOL::OnBoundary(OOpar,OOE); //vertex can be missed
if ((obRest == EXTERNAL)||(obOO == EXTERNAL)){
-#ifdef TOPOPEBREP_DEB
+#ifdef OCCT_DEBUG
if(obRest==EXTERNAL) cout<<"***********ProcessRLine : faulty parameter on Erest"<<endl;
if(obOO==EXTERNAL) cout<<"***********ProcessRLine : faulty parameter on OOE"<<endl;
#endif
if (!ok) continue;
transEdge.Before(Tr.Before()); transEdge.After(Tr.After());
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tDSF) {cout<<"*-> new transEdge (edge"<<SIedgeIndex<<",face"<<iOOFace<<")=";
TopAbs::Print(transEdge.Before(),cout);
cout<<" ";TopAbs::Print(transEdge.After(),cout);cout<<endl;}
//=======================================================================
void TopOpeBRep_FacesFiller::FillLineVPonR()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tDSF = TopOpeBRepDS_GettraceDSF();
Standard_Boolean trline = Standard_False;
#endif
mykeptVPnbr = 0;
if (myLine->TypeLineCurve() == TopOpeBRep_RESTRICTION) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trline) FUN_traceRLine(*myLine);
#endif
ProcessRLine();
return;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trline) FUN_traceGLine(*myLine);
#endif
myLineIsonEdge = LSameDomainERL(*myLine, myERL);
// walking (case mouch1a 1 1) : line (vpfirst on 3,vplast on 0,nvpkept = 2) => kept
myLastVPison0 = ::FUN_haslastvpon0(*myLine);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tDSF) {
if (myLineIsonEdge) cout<<" geometric line is on edge"<<endl;
else cout <<" geometric line not on edge"<<endl;
// sharing same domain with the current geometric line are computed here
//----------------------------------------------------------------------
-#ifdef DEB
+#ifdef OCCT_DEBUG
#ifdef DRAW
Standard_Boolean trcd = Standard_False;
if (trcd) FUN_DrawMap(myDataforDegenEd);
//=======================================================================
void TopOpeBRep_FacesFiller::FillLine()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tDSF = TopOpeBRepDS_GettraceDSF();
#endif
const TopOpeBRep_VPointInter& VP = VPI.CurrentVP();
if ( ! VP.Keep() ) continue;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tDSF) cout<<endl;
#endif
if (onsampt) id = Standard_True;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceDSF()) {
cout<<endl<<"minmax "<<pmin<<","<<pmax;
if (id) cout<<" --> rejet";
TopOpeBRepDS_Curve DSC;
myDSCIndex = myDS->AddCurve(DSC);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceDSF() || TopOpeBRepDS_GettraceDSNC())
cout<<"new DSC "<<myDSCIndex<<endl;
if (TopOpeBRepDS_GettraceDSLT()) myLine->DumpLineTransitions(cout);
{
TopOpeBRepDS_Point DSP = TopOpeBRep_PointGeomTool::MakePoint(VP);
Standard_Boolean b = myHDS->GetGeometry(IT,DSP,G,K);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceDSF() || TopOpeBRepDS_GettraceDSP();
if (b && trc) {
Standard_Boolean newinDS = Standard_False; myHFFD->DumpDSP(VP,K,G,newinDS);
K = TopOpeBRepDS_POINT;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceDSF() || TopOpeBRepDS_GettraceDSP();
if (trc) {
Standard_Boolean newinDS = Standard_True; myHFFD->DumpDSP(VP,K,G,newinDS);
Standard_EXPORT Standard_Real GLOBAL_tolFF = 1.e-7;
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopAbs.hxx>
extern Standard_Boolean TopOpeBRep_GettraceFI();
extern Standard_Boolean TopOpeBRep_GettraceFITOL();
void TopOpeBRep_FacesIntersector::Perform(const TopoDS_Shape& F1,const TopoDS_Shape& F2,
const Bnd_Box& B1,const Bnd_Box& B2)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GettraceSAVFF()) SAVFF(TopoDS::Face(F1),TopoDS::Face(F2));
#endif
myDomain1->Initialize(mySurface1);
myDomain2->Initialize(mySurface2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceKRO()) KRO_DSFILLER_INTFF.Start();
#endif
Standard_Real tol2 = myTol2;
GLOBAL_tolFF = Max(tol1,tol2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GettraceFITOL()) {
cout<<"FacesIntersector : Perform tol1 = "<<tol1<<endl;
cout<<" tol2 = "<<tol2<<endl;
myIntersector.SetTolerances(myTol1,myTol2,MaxUV,Deflection);
myIntersector.Perform(mySurface1,myDomain1,mySurface2,myDomain2,myTol1,myTol2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceKRO()) KRO_DSFILLER_INTFF.Stop();
#endif
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GettraceFI()) cout<<"Perform : isempty "<<IsEmpty()<<endl;
#endif
}
myTol1 = Tol1;
myTol2 = Tol2;
myForceTolerances = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GettraceFITOL())
cout<<"ForceTolerances : myTol1,myTol2 = "<<myTol1<<","<<myTol2<<endl;
#endif
//purpose : (private)
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRep_FacesIntersector::ShapeTolerances(const TopoDS_Shape& S1,
const TopoDS_Shape& S2)
#else
myTol1 = Precision::Confusion();
myTol2 = myTol1;
myForceTolerances = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GettraceFITOL()) {
cout<<"ShapeTolerances on S1 = ";TopAbs::Print(S1.ShapeType(),cout);
cout<<" S2 = ";TopAbs::Print(S2.ShapeType(),cout);
Handle(IntPatch_WLine) anWLine = NULL;
anWLine = GetMergedWLineOnRestriction(theSlin,TolVrtx,aLineOn2S);
-#ifdef TOPOPEBREP_DEB
+#ifdef OCCT_DEBUG
cout << "*** TopOpeBRep_FaceIntersector: Merge WLines on Restriction S1 to WLine ***" << endl;
#endif
theSlin.Clear();
Handle(IntPatch_WLine) anWLine = NULL;
anWLine = GetMergedWLineOnRestriction(theSlin,TolVrtx,aLineOn2S);
-#ifdef TOPOPEBREP_DEB
+#ifdef OCCT_DEBUG
cout << "*** TopOpeBRep_FaceIntersector: Merge WLines on Restriction S2 to WLine***" << endl;
#endif
theSlin.Clear();
#include <TopoDS.hxx>
#include <BRep_Tool.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <GeomTools_SurfaceSet.hxx>
#include <GeomTools_CurveSet.hxx>
#include <GeomTools_Curve2dSet.hxx>
tole = BRep_Tool::Tolerance(myEdge1);
myDomain1.SetValues(pfirst,first,tole,plast,last,tole);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = Standard_False;
if (trc) {
cout<<"ed1 on fa1 : {pfirst=("<<pfirst.X()<<" "<<pfirst.Y()<<"),first="<<first<<"\n";
tole = BRep_Tool::Tolerance(myEdge2);
myDomain2.SetValues(pfirst,first,tole,plast,last,tole);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
cout<<"ed2 on fa1 : {pfirst=("<<pfirst.X()<<" "<<pfirst.Y()<<"),first="<<first<<"\n";
cout<<" plast =("<<plast.X()<<" "<<plast.Y()<<"),last="<<last<<"}"<<endl;
PC2on1->D0(first,pfirst);
PC2on1->D0(last,plast);
myDomain2.SetValues(pfirst,first,tole,plast,last,tole);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( TopOpeBRep_GettracePROEDG() ) {
cout<<"------------ projection de curve"<<endl;
cout<<"--- Curve : "<<endl;GeomTools_CurveSet::PrintCurve(NC,cout);
mySurfacesSameOriented = TopOpeBRepTool_ShapeTool::SurfacesSameOriented(S1,S2);
myFacesSameOriented = TopOpeBRepTool_ShapeTool::FacesSameOriented(myFace1,myFace2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer DEBi = 0;
if ( DEBi ) {
cout<<"TopOpeBRep_Hctxff2d::SetSurfacesPrivate : ";
#include <Standard_ProgramError.hxx>
#include <Standard_NotImplemented.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRep_GetcontextALWLNBP(Standard_Integer&);
extern Standard_Boolean TopOpeBRep_GettraceCONIC();
extern Standard_Boolean TopOpeBRepDS_GettraceDSF();
const Standard_Real deflectionmax = 0.01;
const Standard_Real pasUVmax = 0.05;
Standard_Integer nbpointsmax = 200;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer newnbp;
if (TopOpeBRep_GetcontextALWLNBP(newnbp)) nbpointsmax = newnbp;
#endif
// Build the trimmed 3d curve
Handle(Geom_Curve) C3D = Curve();
Handle(Geom_TrimmedCurve) TC3D = new Geom_TrimmedCurve(C3D,parmin,parmax);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( TopOpeBRep_GettraceCONIC() ) {
cout<<"TopOpeBRep_LineInter::Curve on a ";
TopOpeBRep::Print(myTypeLineCurve,cout);cout<<endl;
void TopOpeBRep_LineInter::DumpType()const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopOpeBRep::Print(myTypeLineCurve,cout);
#endif
}
//=======================================================================
void TopOpeBRep_LineInter::DumpVPoint
-#ifndef DEB
+#ifndef OCCT_DEBUG
(const Standard_Integer ,
const TCollection_AsciiString& ,
const TCollection_AsciiString& ) const
//=======================================================================
void TopOpeBRep_LineInter::DumpBipoint
-#ifndef DEB
+#ifndef OCCT_DEBUG
(const TopOpeBRep_Bipoint& ,
const TCollection_AsciiString& ,
const TCollection_AsciiString& ) const
void TopOpeBRep_LineInter::SetOK(const Standard_Boolean B)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceDSF() || TopOpeBRepDS_GettraceDSNC()) {
if (myOK != B) {
cout<<"line "<<myIndex<<" (";
//=======================================================================
Standard_OStream& TopOpeBRep_LineInter::DumpLineTransitions(Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OS<<"transition from f1 / f2 "; TopAbs::Print(myF2.Orientation(),OS);
OS<<" : "; myLineTonF1.Dump(OS); OS<<endl;
OS<<"transition from f2 / f1 "; TopAbs::Print(myF1.Orientation(),OS);
//function : Dump
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRep_Point2d::Dump(const Standard_Integer E1index,const Standard_Integer E2index) const
{
Standard_Real par1 = Parameter(1);
#include <TopOpeBRepTool_EXPORT.hxx>
#include <TopOpeBRepTool_SC.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopOpeBRep_FFDumper.hxx>
#include <Geom_TrimmedCurve.hxx>
#include <Geom_Line.hxx>
// if the Rline is describing the portion on curve (vpl,vpf),
// we have to commutate these bounds.
if (isperiodic) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
// TopOpeBRep_FFDumper FFD(*this);
// cout <<"vpf :"; FFD.DumpVP(vpf,cout);
// cout <<"vpl :"; FFD.DumpVP(vpl,cout);
if (Lrest.ArcIsEdge(1)) IArc = 1;
if (Lrest.ArcIsEdge(2)) IArc = 2;
if (IArc == 0) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Failure::Raise("StBipVPonF");
#endif
return TopAbs_UNKNOWN;
Standard_Real x = 0.789; Standard_Real parmil = (1-x)*uf + x*ul; //xpu170898
gp_Pnt pmil = BC.Value(parmil);
-#ifdef DEB
+#ifdef OCCT_DEBUG
#ifdef DRAW
Standard_Boolean trc = TopOpeBRep_GettraceBIPS();
if (trc) {TCollection_AsciiString aa("pmil"); FUN_brep_draw(aa,pmil);}
#include <TopOpeBRep_define.hxx>
#include <TopTools_MapOfShape.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceDSF();
extern Standard_Boolean TopOpeBRepDS_GettraceDSFK();
extern Standard_Boolean TopOpeBRepDS_GettraceDSNC();
void TopOpeBRep_FacesFiller::GetESL(TopTools_ListOfShape& LES)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean b22 = TopOpeBRepDS_GettraceDSNC();
Standard_Boolean trRL=Standard_False;
#endif
if (isrest) {
const TopoDS_Edge& E = TopoDS::Edge(L.Arc());
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trRL) {
TopOpeBRep_VPointInterIterator VPI;VPI.Init(L);
cout<<endl<<"------------ Dump Rline --------------------"<<endl;
LES.Append(E);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (b22) {
if (add) cout<<" : add restriction edge of line ";
else cout<<" rejection of restriction edge of line ";
Standard_Boolean TopOpeBRep_FacesFiller::KeepRLine
(const TopOpeBRep_LineInter& L,const Standard_Boolean checkkeep) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
//Standard_Boolean trc = (TopOpeBRepDS_GettraceDSF() || TopOpeBRepDS_GettraceDSNC());
#endif
TopAbs_State stVPbip = StBipVPonF(vpf,vpl,L,isedge1);
keeprline = (stVPbip == TopAbs_IN);
keeprline = keeprline||(stVPbip==TopAbs_ON); // REST1
-#ifdef DEB
+#ifdef OCCT_DEBUG
// if (trc) {
// cout<<" bip("<<vpf.Index()<<","<<vpl.Index()<<") of line restriction ";
// cout<<L.Index()<<" is ";TopAbs::Print(stVPbip,cout);
//=======================================================================
void TopOpeBRep_FacesFiller::ProcessSectionEdges()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean DSNC = TopOpeBRepDS_GettraceDSNC();
if (DSNC) cout<<endl<<"--- Section Edges Processing : ---"<<endl;
#endif
Standard_Boolean isdg = BRep_Tool::Degenerated(E); //xpu290698
if (isdg) continue; //xpu290698
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iSE =
#endif
myDS->AddSectionEdge(E);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iE =
#endif
myDS->Shape(E);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer rE =
#endif
myDS->AncestorRank(E);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DSNC) cout<<"add section edge "<<iSE<<" : "<<iE<<"("<<rE<<")"<<endl;
#endif
}
TopTools_DataMapIteratorOfDataMapOfShapeListOfShape itmapELE;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (DSNC) {
for (itmapELE.Initialize(mapELE); itmapELE.More(); itmapELE.Next()) {
const TopoDS_Edge& E1 = TopoDS::Edge(itmapELE.Key());
#include <TopOpeBRepTool_box.hxx>
#include <TopOpeBRep_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRep_GettraceSI();
extern Standard_Boolean TopOpeBRep_GetcontextFFOR();
extern Standard_Integer SAVFFi1; // FacesIntersector
{
Standard_Boolean res = myIntersectionDone;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GettraceSI() && res) {
if ( myFFDone ) cout<<"FF : ";
else if ( myEEFFDone ) cout<<" EE : ";
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRep_ShapeIntersector::DumpCurrent(const Standard_Integer K) const
{
if ( myFFDone ) {
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer TopOpeBRep_ShapeIntersector::Index
(const Standard_Integer K)const
{
const TopoDS_Shape& GS1 = myFaceScanner.Current();
const TopoDS_Shape& GS2 = myFaceExplorer.Current();
-#ifdef DEB
+#ifdef OCCT_DEBUG
SAVFFi1 = myFaceScanner.Index(); SAVFFi2 = myFaceExplorer.Index();
if (TopOpeBRep_GettraceSI()) {
cout<<"?? FF : ";
TopoDS_Shape face1 = myFaceScanner.Current(); // -26-08-96
TopoDS_Shape face2 = myFaceExplorer.Current(); // -26-08-96
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GetcontextFFOR()) {
face1.Orientation(TopAbs_FORWARD); //-05/07
face2.Orientation(TopAbs_FORWARD); //-05/07
const TopoDS_Shape& GS2 = myEdgeExplorer.Current();
myEEIntersector.Perform(GS1,GS2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GettraceSI() && myEEIntersector.IsEmpty()) {
cout<<" EE : ";
myEdgeScanner.DumpCurrent(cout);
// so this suggestion must be developed carefully. while we don't classify it!
// *****************************************************************************
}
-#ifdef TOPOPEBREP_DEB
+#ifdef OCCT_DEBUG
if( result != 0 )
cout << "# one of the SOLIDs probably is a HALF SPACE" << endl;
#endif
#include <Bnd_Box.hxx>
#include <TopOpeBRepTool_box.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRep_GettraceSI();
extern Standard_Boolean TopOpeBRep_GetcontextFFOR();
#endif
{
Standard_Boolean res = myIntersectionDone;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GettraceSI() && res) {
if ( myFFDone ) cout<<"FF : ";
else if ( myEEFFDone ) cout<<" EE : ";
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRep_ShapeIntersector2d::DumpCurrent(const Standard_Integer K) const
{
if ( myFFDone ) {
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer TopOpeBRep_ShapeIntersector2d::Index
(const Standard_Integer K)const
{
const TopoDS_Shape& GS1 = myFaceScanner.Current();
const TopoDS_Shape& GS2 = myFaceExplorer.Current();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GettraceSI()) {
cout<<"?? FF : ";
myFaceScanner.DumpCurrent(cout);
TopoDS_Shape face1 = myFaceScanner.Current(); // -26-08-96
TopoDS_Shape face2 = myFaceExplorer.Current(); // -26-08-96
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GetcontextFFOR()) {
face1.Orientation(TopAbs_FORWARD); //-05/07
face2.Orientation(TopAbs_FORWARD); //-05/07
const TopoDS_Shape& GS2 = myEdgeExplorer.Current();
myEEIntersector.Perform(GS1,GS2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRep_GettraceSI() && myEEIntersector.IsEmpty()) {
cout<<" EE : ";
myEdgeScanner.DumpCurrent(cout);
//=======================================================================
Standard_OStream& TopOpeBRep_ShapeScanner::DumpCurrent(Standard_OStream& OS)const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( More() ) {
const TopoDS_Shape& S = Current();
TopAbs_ShapeEnum T = S.ShapeType();
#include <Precision.hxx>
#include <TopOpeBRep_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceDSFK();
static TCollection_AsciiString PRODINP("dinp ");
#endif
Standard_OStream& TopOpeBRep_VPointInter::Dump(const Standard_Integer I,const TopoDS_Face& F,Standard_OStream& OS) const
{
const TopoDS_Edge& E = TopoDS::Edge(Edge(I));
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Real Epar =
#endif
EdgeParameter(I);
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopAbs_Orientation O =
#endif
E.Orientation();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean closingedge =
#endif
TopOpeBRepTool_ShapeTool::Closed(E,F);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (closingedge) OS<<"on closing edge "; else OS<<"on edge "; TopAbs::Print(O,cout);
cout<<" of "<<I<<" : par : "<<Epar<<endl;
TopOpeBRepDS_Transition T = TopOpeBRep_FFTransitionTool::ProcessLineTransition(*this,I,O);
//function : Dump
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_OStream& TopOpeBRep_VPointInter::Dump(const TopoDS_Face& FF1,const TopoDS_Face& FF2,Standard_OStream& OS) const
{
const TopoDS_Face& F1 = TopoDS::Face(FF1);
#include <TopOpeBRepDS_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceDSF();
extern Standard_Boolean TopOpeBRep_GetcontextNEWKP();
#endif
return sameuv;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
//-------------------------------------------------------------------
void FUNBREP_topokpartDEB
(const Handle(TopOpeBRepDS_Interference)& /*Ifound*/,
TopOpeBRepDS_Transition& transLine)
//----------------------------------------------------------------------
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceDSF();
#endif
Standard_Boolean samevponcouture = samepar && keep;
if (samevponcouture) {
keep = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<"is same vp on couture";
#endif
}
return keep;
} // FUNBREP_topowalki_new
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean GLOBAL_bvpr;
Standard_EXPORT void debvpr2(void) {}
#endif
TopOpeBRepDS_Transition& transLine)
//----------------------------------------------------------------------
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceDSF();
#endif
return Standard_False;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean newkp = TopOpeBRep_GetcontextNEWKP();
if (newkp) {
Standard_Boolean keep = FUNBREP_topowalki_new(Ifound,DSCIL,L,VP,E,samepar,couture,transLine);
if (keep && samevponcouture) {
keep = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<"is same vp on couture";
#endif
}
if (keep) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (GLOBAL_bvpr) debvpr2();
#endif
return Standard_False;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean newkp = TopOpeBRep_GetcontextNEWKP();
if (newkp) {
Standard_Boolean keep = FUNBREP_topogline_new(DSCIL,L,VP,BDS,toluv,samepar,couture,parline,transLine);
TopOpeBRepDS_Transition lasttransLine;
if (!DSCIL.IsEmpty()) lasttransLine = DSCIL.Last()->Transition(); // xpu12-12-97
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceDSF()) {
FUNBREP_topokpartDEB(Ifound,DSCIL,L,VP,lasttransLine,BDS,E,F,toluv,
CPIfound,samepar,couture,parline,transLine);
TopOpeBRepDS_ListIteratorOfListOfInterference itI;itI.Initialize(BDS.ChangeCurveInterferences(ic));if (!itI.More()) continue;
const TopoDS_Face& f1 = TopoDS::Face(c.Shape1());
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer if1 =
#endif
BDS.Shape(f1);
const TopoDS_Face& f2 = TopoDS::Face(c.Shape2());
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer if2 =
#endif
BDS.Shape(f2);
else if (ivp2) { CPI->GeometryType(k2); CPI->Geometry(iv2); }
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (editITF) {
if (ivp1 != 0) {
cout<<TopOpeBRepDS::SPrint(TopOpeBRepDS_CURVE,ic,"# BREP_mergePDS "," : ");
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <Standard_Type.hxx>
//#include <Standard_OStream.hxx>
return TopOpeBRep_contextNONOG;
}
-// #ifdef DEB
+// #ifdef OCCT_DEBUG
#endif
# include <strings.h>
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <Standard_Type.hxx>
return b;
}
-// #ifdef DEB
+// #ifdef OCCT_DEBUG
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <Standard_Type.hxx>
#include <TCollection_AsciiString.hxx>
Standard_Boolean b = BOOPSHA.Get(1,t);return b;
}
-// #ifdef DEB
+// #ifdef OCCT_DEBUG
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopOpeBRep_traceSIFF.hxx>
#include <stdio.h>
return b;
}
-// #ifdef DEB
+// #ifdef OCCT_DEBUG
#endif
#ifndef _TopOpeBRep_traceSIFF_HeaderFile
#define _TopOpeBRep_traceSIFF_HeaderFile
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopOpeBRepTool_define.hxx>
#include <Standard_OStream.hxx>
Standard_Boolean myopen;
};
-// #ifdef DEB
+// #ifdef OCCT_DEBUG
#endif
// #define _TopOpeBRep_traceSIFF_HeaderFile
#endif
#define M_UNKNOWN(st) (st == TopAbs_UNKNOWN)
#define M_REVERSED(st) (st == TopAbs_REVERSED)
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceISTO();
extern Standard_Boolean TopOpeBRepDS_GettraceDSF();
extern Standard_Boolean TopOpeBRepDS_GettraceDSP();
}
TopOpeBRepDS_ListIteratorOfListOfInterference itCPIL(DSCIL);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = Standard_False;
if (trc) {TopOpeBRepDS_Dumper DSD(HDS); TCollection_AsciiString aa("DSCIL :");
DSD.DumpLOI(DSCIL,cout,aa);}
gp_Pnt2d uv = VP.SurfaceParameters(OOShapeIndex);
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopOpeBRepDS_Transition Tr;
#endif
// <Tr> relative to 3d <OOface> matter,
Standard_Real toluv = 1.e-8;
Standard_Boolean keep = FUNBREP_topokpart(Ifound,DSCIL,L,VP,(*pDS),E,F,toluv,parline,ttransLine);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer trc=TopOpeBRepDS_GettraceDSF();
if (trc){if(keep)cout<<"\t-> on garde";else cout<<"\t-> on jette";cout<<endl;}
#endif
return isonf || isonl;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_EXPORT void funraise() {cout<<"!!!!!!!!!! PVIndex = 0 !!!!!!!!!!"<<endl;}
#endif
dgOOe = BRep_Tool::Degenerated(OOedge);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean traceDSF = TopOpeBRepDS_GettraceDSF();
Standard_Boolean traceDSP = TopOpeBRepDS_GettraceDSP();
Standard_Integer ili=myLine->Index(),ivp=iVP,isi=ShapeIndex;
keepvpfirst = keepvpfirst && myLastVPison0;
//modified by NIZHNY-MKK Mon Jul 3 11:30:21 2000.END
if (keepvpfirst) transLine.Set(TopAbs_FORWARD);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (traceDSF) cout<<"myLastVPison0 ->"<<endl;
#endif
ret1 = Standard_False;
// -------------------
TopAbs_Orientation Transori = Trans.Orientation(TopAbs_IN);
TopOpeBRepDS_Transition transEdge = TopOpeBRep_FFTransitionTool::ProcessEdgeTransition(VP,ShapeIndex,Transori);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(traceDSF){cout<<"trans edge on f"<<ShapeIndex<<" / f"<<OOShapeIndex<<" : ";
transEdge.Dump(cout);cout<<endl;}
#endif
newtransEdge = newtransEdge || closing || OOclosing;
newtransEdge = newtransEdge && (!myLineINL);
if (newtransEdge){
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iedge =
#endif
myDS->Shape(edge);
if (ok) {transEdge.Before(Tr.Before()); transEdge.After(Tr.After());}
newtransEdge = ok;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (traceDSF && (found || newtransEdge))
{if (found) cout<<"*-> found "; if (newtransEdge) cout<<"*-> new ";
cout<<"transEdge (edge "<<iedge<<",face"<<iOOFace<<") = "; TopAbs::Print(transEdge.Before(),cout);
// OO*** : data issued from other shape
if (SIedgeIndex == 0) SIedgeIndex = myDS->AddShape(edge,ShapeIndex);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trce = TopOpeBRepDS_GettraceSPSX(SIedgeIndex); if(trce) debarc(SIedgeIndex);
#endif
CPIfound,ICPI, // out
M_MKNEWVP);
if (PVIndex == 0){
-#ifdef DEB
+#ifdef OCCT_DEBUG
funraise();
#endif
}
// Gfound = VP corresponds with an existing geometry of ShapeIndex
Standard_Boolean Gfound = ( EPIfound || CPIfound );
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trcpv = TopOpeBRepDS_GettraceSPSX(PVIndex);
Standard_Boolean ispoint = (PVKind == TopOpeBRepDS_POINT);
if(trcpv && ispoint) debpoint(PVIndex);
}
}
if ( correctON ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trcooe=TopOpeBRepDS_GettraceSPSX(OOedgeIndex);if (trcooe) debooarc(OOedgeIndex);
#endif
if (OOedgeIndex == 0) OOedgeIndex = myDS->AddShape(OOedge,OOShapeIndex);
TopAbs_State stb,sta; ok = MKT.MkTonE(stb,sta);
if (ok) {
tOOedge.Before(stb); tOOedge.After(sta);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(traceDSF){
cout<<"* !on2edges && TopAbs_ON *\n";
if(OOisrest) cout<<"* edge "<<OOedgeIndex<<" RESTRICTION *\n";
if (!ok) addEPI = Standard_True;
} // EPIfound
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (GLOBAL_bvpr) debvprmess(myexF1,myexF2,ili,ivp,isi);
#endif
#define M_ON(st) (st == TopAbs_ON)
#define M_REVERSED(st) (st == TopAbs_REVERSED)
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceDSF();
extern Standard_Boolean TopOpeBRepDS_GettraceSPSX(const Standard_Integer i1);
Standard_EXPORT void debarc(const Standard_Integer i);
if (iOOFace == 0) iOOFace = myDS->AddShape(OOFace,OOShapeIndex);
// current VPoint is on <edge>
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer SIedgeIndex = 0;
#endif
const TopoDS_Edge& edge = TopoDS::Edge(VP.Edge(ShapeIndex));
if (!myDS->HasShape(edge)) myDS->AddShape(edge,ShapeIndex);
-#ifdef DEB
+#ifdef OCCT_DEBUG
else SIedgeIndex = myDS->Shape(edge);
#endif
else OOedgeIndex = myDS->AddShape(OOedge,OOShapeIndex);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean traceDSF = TopOpeBRepDS_GettraceDSF();
Standard_Boolean trce = TopOpeBRepDS_GettraceSPSX(SIedgeIndex); if(trce) debarc(SIedgeIndex);
Standard_Boolean trcooe = TopOpeBRepDS_GettraceSPSX(OOedgeIndex); if(trcooe) debooarc(OOedgeIndex);
// transEdge should be INTERNAL/EXTERNAL.
Standard_Boolean Tunk = transEdge.IsUnknown();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (!Tunk && traceDSF) cout<<"-> on closing : transAdd = "<<endl;
#endif
TopOpeBRepDS_Transition transAdd;
TopoDS_Vertex& theVertex);
// modified by NIZHNY-MKK Tue Nov 21 17:30:27 2000.END
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceDEGEN();
extern Standard_Boolean TopOpeBRepDS_GettraceDSF();
Standard_EXPORT Standard_Boolean FUN_debnull(const TopoDS_Shape& s);
else y = ngFi.Reversed();
gp_Vec z(x^y);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = Standard_False;
if (trc) {
gp_Pnt p = BRep_Tool::Pnt(ve);
else y = ngFi.Reversed();
gp_Vec z(x^y);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = Standard_False;
if (trc) {
gp_Pnt p = BRep_Tool::Pnt(v);
// Ed append EVI of transition(FACE Fi) on G=(VERTEX,V), S=(FACE,Fi) par = paronEd2
// with Ed the degenerated edge, Ei of Fi interfers with Ed at vertex V.
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean traceDSF = TopOpeBRepDS_GettraceDSF();
Standard_Boolean traceDEGEN = TopOpeBRepDS_GettraceDEGEN();
Standard_Boolean trace = traceDSF || traceDEGEN;
else Fi = F2;
Standard_Integer iv = 0;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (FUN_debnull(Fe)) cout<<"Fe is null"<<endl;
if (FUN_debnull(Fi)) cout<<"Fi is null"<<endl;
if (FUN_debnull(Ec)) cout<<"Ec is null"<<endl;
TopoDS_Edge tmpOOEi; Standard_Real tmpparonOOEi; TopOpeBRepDS_Transition tmpTOOEi;
for (;itloei.More(); itloei.Next()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (FUN_debnull(itloei.Value())) cout<<"Ei is null"<<endl;
#ifdef DRAW
if (trace3d) {TCollection_AsciiString aa("ecur");FUN_brep_draw(aa,itloei.Value());}
Standard_Boolean& EPIfound, Handle(TopOpeBRepDS_Interference)& IEPI, // out
Standard_Boolean& CPIfound, Handle(TopOpeBRepDS_Interference)& ICPI) // out
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean traceDSF = TopOpeBRepDS_GettraceDSF();
Standard_Boolean traceDEGEN = TopOpeBRepDS_GettraceDEGEN();
#endif
if (rankFi == 1) Fi = myF1;
else Fi = myF2;
Standard_Integer iFi = myDS->AddShape(Fi,rankFi);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iEd =
#endif
myDS->AddShape(dgEd,rankdg);
Standard_Integer iOOEi = 0;
if (hasOOEi) iOOEi = myDS->AddShape(OOEi,rankFi);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trace = traceDSF || traceDEGEN;
if (trace) cout<<" VP is on degenerated edge "<<iEd<<" :"<<endl;
#endif
#include <TopAbs_Orientation.hxx>
#include <TopAbs.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GettraceAREA();
extern Standard_Boolean TopOpeBRepDS_GettraceSTRANGE();
#endif
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Area1dBuilder::DumpList(const TopOpeBRepBuild_ListOfLoop& LOL)
{
Standard_Integer iLOL;
const Handle(TopOpeBRepBuild_Loop)& L = LS.Loop();
Standard_Boolean boundaryL = L->IsShape();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GettraceAREA()) {
cout<<"++++ new loop : "; L->Dump();
if (boundaryL) cout<<" is bound"; else cout<<" is not bound";
} // end of block loop
} // end of LoopSet LS scan
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GettraceAREA()) {
if ( ! myArea.IsEmpty() ) {
cout<<"------- Areas -------"<<endl;
(const Handle(TopOpeBRepBuild_Loop)& L,
TopOpeBRepBuild_ListOfLoop& LOL,
const Standard_Address
-#ifdef DEB
+#ifdef OCCT_DEBUG
ss
#endif
) const
{
LOL.Append(L);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GettraceAREA()) {
cout<<"--------------------- add area loop to area : ";
L->Dump(); cout<<endl;
void TopOpeBRepBuild_Area1dBuilder::REM_Loop_FROM_LISTOFLoop
(TopOpeBRepBuild_ListIteratorOfListOfLoop& ITA,
TopOpeBRepBuild_ListOfLoop& A,
-#ifdef DEB
+#ifdef OCCT_DEBUG
const Standard_Address ss) const
{
char* s = (char*)ss;
{
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GettraceAREA()) {
if (ITA.More()) {
cout<<"--------------------- remove area loop from area : ";
A.Remove(ITA);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GettraceAREA()) {
DumpList(A);
cout<<"---------------------"<<endl;
void TopOpeBRepBuild_Area1dBuilder::ADD_LISTOFLoop_TO_LISTOFLoop
(TopOpeBRepBuild_ListOfLoop& A1,
TopOpeBRepBuild_ListOfLoop& A2,
- #ifdef DEB
+ #ifdef OCCT_DEBUG
const Standard_Address ss,
const Standard_Address ss1,
const Standard_Address ss2) const
const Standard_Address) const
#endif
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
char* s = (char*)ss;
char* s1 = (char*)ss1;
char* s2 = (char*)ss2;
A2.Append(A1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GettraceAREA()) {
cout<<"2 : "; if (s2 != NULL) cout<<s2; cout<<endl;
DumpList(A2);
#include <TopOpeBRepBuild_Area2dBuilder.ixx>
#include <TopOpeBRepBuild_Loop.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GettraceAREA();
#endif
if ( ! boundaryloops.IsEmpty() ) {
if ( myArea.IsEmpty() ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GettraceAREA())
cout<<"---"<<endl<<"--- purge"<<endl<<"---"<<endl;
#endif
#include <Standard_DomainError.hxx>
#include <TopAbs.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceSTRANGE();
#endif
"AreaBuilder : Position Unknown");
}
else {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( TopOpeBRepDS_GettraceSTRANGE() ) {
cout<<"AreaBuilder : state "; TopAbs::Print(state,cout);
cout<<" taken as "; TopAbs::Print(newstate,cout); cout<<endl;
#include <TopoDS.hxx>
#include <TopOpeBRepBuild_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GettraceCU();
#endif
//=======================================================================
void TopOpeBRepBuild_Builder::BuildEdges(const Standard_Integer iC,const Handle(TopOpeBRepDS_HDataStructure)& HDS)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GettraceCU()) cout<<"\nBuildEdges on C "<<iC<<endl;
#endif
const TopOpeBRepDS_Curve& C = HDS->Curve(iC);
Standard_Integer ip, np = HDS->NbPoints();
TColStd_HArray1OfInteger tp(0,np,0);
for (cex.Init(BDS); cex.More(); cex.Next()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
// const TopOpeBRepDS_Curve& C = cex.Curve();
#endif
Standard_Integer ic = cex.Index();
#include <BRep_Tool.hxx>
#include <BRep_Builder.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GettraceCU();
extern Standard_Boolean TopOpeBRepBuild_GettraceCUV();
extern Standard_Boolean TopOpeBRepBuild_GettraceSPF();
//
TopOpeBRepBuild_WireEdgeSet WES(aFace, this);
//
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tSE = TopOpeBRepBuild_GettraceSPF();
Standard_Boolean tCU = TopOpeBRepBuild_GettraceCU();
Standard_Boolean NtCUV = !TopOpeBRepBuild_GettraceCUV();
for (; SCurves.More(); SCurves.Next()) {
Standard_Integer iC = SCurves.Current();
const TopOpeBRepDS_Curve& CDS = HDS->Curve(iC);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSE) cout<<endl<<"BuildFaces : C "<<iC<<" on S "<<iS<<endl;
if (tCU) { CDS.Dump(cout,iC,NtCUV); cout<<endl; }
#endif
#include <TopOpeBRepDS_Reducer.hxx>
#include <TopOpeBRepBuild_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GettraceCU();
extern Standard_Boolean TopOpeBRepBuild_GettraceCUV();
extern Standard_Boolean TopOpeBRepBuild_GettraceSPF();
//=======================================================================
void TopOpeBRepBuild_Builder::Perform(const Handle(TopOpeBRepDS_HDataStructure)& HDS)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
GdumpSHASETreset();
#endif
Clear();
TopOpeBRepDS_CurveIterator FCurves = myDataStructure->FaceCurves(aFace);
for (; FCurves.More(); FCurves.Next()) {
Standard_Integer iC = FCurves.Current();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tCU = TopOpeBRepBuild_GettraceCU();
Standard_Boolean NtCUV = !TopOpeBRepBuild_GettraceCUV();
if(tCU) {cout<<endl;myDataStructure->Curve(iC).Dump(cout,iC,NtCUV);}
Standard_Boolean hassame = myDataStructure->HasSameDomain(S);
Standard_Boolean tosplit = (!issplit) && (hasgeom || hassame);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iS; Standard_Boolean tSPS = GtraceSPS(S,iS);
if (tSPS) {
cout<<"tosplit "<<tosplit<<" : "<<"!issplit "<<(!issplit);
TopOpeBRepDS_ListOfShapeOn1State& losos = (*p).ChangeFind(S);
losos.Split(Bval);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iS; Standard_Boolean tSPS = GtraceSPS(S,iS);
if(tSPS){
GdumpSHA(S, (char *) "MarkSplit ");
if ((*p).IsBound(S)) {
const TopOpeBRepDS_ListOfShapeOn1State& losos = (*p).Find(S);
res = losos.IsSplit();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer n = losos.ListOnState().Extent();
#endif
}
//=======================================================================
TopTools_ListOfShape& TopOpeBRepBuild_Builder::ChangeSplit(const TopoDS_Shape& S,const TopAbs_State ToBuild)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iS; Standard_Boolean tSPS = GtraceSPS(S,iS);
if(tSPS){
GdumpSHA(S, (char *) "ChangeSplit ");
for (TopTools_ListIteratorOfListOfShape Iti(LS); Iti.More(); Iti.Next()) {
const TopoDS_Shape& SLS = Iti.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// TopAbs_ShapeEnum tSLS = SLS.ShapeType();
#endif
state = myShapeClassifier.StateShapeShape(S,(*PLOS),SLS);
TopTools_ListIteratorOfListOfShape it1(L1);
for (i=1 ; i<=nl1; i++) {
const TopoDS_Shape& S1 = it1.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iS1 = myDataStructure->Shape(S1); // DEB
#endif
TopTools_ListIteratorOfListOfShape itsd(myDataStructure->SameDomain(S1));
for (; itsd.More(); itsd.Next() ) {
const TopoDS_Shape& S2 = itsd.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iS2 = myDataStructure->Shape(S2);// DEB
#endif
Standard_Boolean found = Contains(S2,L2);
TopTools_ListIteratorOfListOfShape it2(L2);
for (i=1 ; i<=nl2; i++) {
const TopoDS_Shape& S2 = it2.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iS2 = myDataStructure->Shape(S2);// DEB
#endif
TopTools_ListIteratorOfListOfShape itsd(myDataStructure->SameDomain(S2));
for (; itsd.More(); itsd.Next() ) {
const TopoDS_Shape& S1 = itsd.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iS1 = myDataStructure->Shape(S1);// DEB
#endif
Standard_Boolean found = Contains(S1,L1);
if ( !it.More() ) return;
const TopoDS_Shape& sref = it.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iref = myDataStructure->SameDomainReference(sref);
#endif
TopOpeBRepDS_Config oref = myDataStructure->SameDomainOrientation(sref);
#include <BRepLProp_SurfaceTool.hxx>
#include <BRepLProp_SLProps.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_EXPORT Standard_Boolean TopOpeBRepBuild_GetcontextEINTERNAL();
Standard_EXPORT Standard_Boolean TopOpeBRepBuild_GetcontextEEXTERNAL();
Standard_EXPORT Standard_Boolean TopOpeBRepBuild_GetcontextNOSG();
{return B.GtraceSPS(iFOR,GI); }
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_EXPORT void FUN_RaiseON()
{Standard_Failure::Raise("BuilderON");}
static void FUN_cout(const TopoDS_Shape& eON)
myPLSclass = PLSclass;
myPWES = PWES;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iFOR;Standard_Boolean tFOR=myPB->GtraceSPS(FOR,iFOR);
if (tFOR) debfillonf(iFOR);
#endif
TopOpeBRepDS_Kind GT,ST;Standard_Integer GI,SI;FDS_data(SSI,GT,GI,ST,SI);
if (GT != TopOpeBRepDS_EDGE || ST != TopOpeBRepDS_FACE) return Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iFOR=BDS.Shape(myFace);
#endif
const TopoDS_Edge& EG=TopoDS::Edge(BDS.Shape(GI, Standard_False));
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iEG=BDS.Shape(EG, Standard_False);
#endif
const TopoDS_Shape& FS=BDS.Shape(SI, Standard_False);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iFS=BDS.Shape(FS, Standard_False);
#endif
TopAbs_ShapeEnum ShapeInterf=TopAbs_FACE;
const TopTools_ListOfShape& lEspON=myPB->Splits(EG,TopAbs_ON);
if (lEspON.Extent() == 0) return Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// const TopoDS_Shape& EspON=lEspON.First();
#endif
Standard_Integer rankFS=myPB->GShapeRank(FS);
void TopOpeBRepBuild_BuilderON::GFillONPartsWES1(const Handle(TopOpeBRepDS_Interference)& I)
{
const TopOpeBRepDS_DataStructure& BDS=myPB->DataStructure()->DS();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iFOR=
#endif
BDS.Shape(myFace);
const TopoDS_Edge& EG=TopoDS::Edge(BDS.Shape(GI));
// const TopoDS_Shape& FS=BDS.Shape(SI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iEG=BDS.Shape(EG);
// Standard_Integer iFS=BDS.Shape(FS);
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tEFOR=DEBTEFOR(*myPB,iFOR,GI);
if (tEFOR) debfillonfemess(iFOR,GI,myPB,myPWES,"--- GFillONPartsWES1");
#endif
const TopTools_ListOfShape& lEspON=myPB->Splits(EG,TopAbs_ON);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nEspON=lEspON.Extent();
#endif
for(TopTools_ListIteratorOfListOfShape it(lEspON);it.More();it.Next()) {
}
} // GFillONPartsWES1
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_EXPORT void FUN_coutmess(const TCollection_AsciiString& m)
{
cout<<m;
#endif
//------------------------------------------------------
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean FUN_keepEON(const TopOpeBRepBuild_Builder& B,
#else
Standard_Boolean FUN_keepEON(const TopOpeBRepBuild_Builder&,
const TopoDS_Shape& sEG,
const TopoDS_Shape& sFOR,
const TopoDS_Shape& sFS,
-#ifdef DEB
+#ifdef OCCT_DEBUG
const Standard_Boolean EGBoundFOR,
#else
const Standard_Boolean,
TopoDS_Face FF=TopoDS::Face(sFOR);FF.Orientation(TopAbs_FORWARD);
TopoDS_Face FS=TopoDS::Face(sFS);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iEG;/*Standard_Boolean tEG=*/B.GtraceSPS(EG,iEG);
Standard_Integer iFF;/*Standard_Boolean tFF=*/B.GtraceSPS(FF,iFF);
Standard_Integer iFS;/*Standard_Boolean tFS=*/B.GtraceSPS(FS,iFS);
Standard_Boolean tFSEG=DEBTEFOR(B,iFS,iEG);if (tFSEG) debfillonfemess(iFS,iEG);
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean keep1=Standard_True;
Standard_Boolean keep2=Standard_True;
#endif
Standard_Boolean keep3=Standard_True;
Standard_Boolean isclosedFF=BRep_Tool::IsClosed(EG,FF);
if (isclosedFF) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
keep1=Standard_True;
keep2=Standard_True;
#endif
TopAbs_Orientation oEGFF=TopAbs_FORWARD;
FUN_tool_orientEinF(EG,FF,oEGFF);
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopAbs_Orientation omatFS1=TFE.Orientation(TB1);
if (oEGFF == TopAbs_REVERSED) omatFS1=TopAbs::Complement(omatFS1);
keep1=(omatFS1 == TopAbs_FORWARD);
else if (oEGFF == TopAbs_INTERNAL) keep3=(tfea == TB1 || tfeb == TB1);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tFFEG || tFSEG) {
if ( keep1 != keep2 || keep1 != keep3 || keep2 != keep3 ) {
cout<<"\nkeepEON : EGB "<<EGBoundFOR<<" EG "<<iEG<<" FOR "<<iFF<<" FS "<<iFS;
const TopoDS_Face& FOR=TopoDS::Face(myFace); Standard_Integer iFOR=BDS.Shape(FOR);
const TopoDS_Edge& eON=TopoDS::Edge(EspON);
const TopoDS_Edge& EG=TopoDS::Edge(BDS.Shape(GI));
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iEG=
#endif
BDS.Shape(EG);
Standard_Boolean isclosedFS=FUN_tool_IsClosingE(EG,FS,FS); //xpu240898
Standard_Boolean isclosed=(isclosedFF || isclosedFS);
Standard_Boolean isrest=BDS.IsSectionEdge(EG);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean issplit=myPB->IsSplit(EG,TopAbs_ON);
#endif
Standard_Integer rankFS=myPB->GShapeRank(FS);
TopAbs_Orientation OTFE = TFE.Orientation(TopAbs_IN);
TopAbs_State TFEbef = TFE.Before();
TopAbs_State TFEaft = TFE.After();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean EGboundFOR =
// Handle(TopOpeBRepDS_ShapeShapeInterference)::DownCast(I)->GBound();
#endif
Standard_Boolean opeFus = myPB->Opefus();
Standard_Boolean opec12 = myPB->Opec12();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean opec21 = myPB->Opec21();
#endif
Standard_Boolean opeCut = myPB->Opec12() || myPB->Opec21();
TopAbs_State TBFOR = FUN_build_TB(myPB,rankFOR);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tFOR=myPB->GtraceSPS(iFOR);Standard_Boolean tE=myPB->GtraceSPS(GI);
Standard_Boolean tEFOR=DEBTEFOR(*myPB,iFOR,GI);
if (tFOR) debON(iFOR);
//=========================================
if ( yap00 ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debfillonfemess(iFOR,iEG,myPB,myPWES,"yap0 GFillON");
if (tE) {cout<<"yap00(FOR"<<iFOR<<" FS"<<iFS<<" EG"<<GI<<") ";
cout<<"TB1=";TopAbs::Print(TB1,cout);cout<<" TB2=";TopAbs::Print(TB2,cout);cout<<endl;}
TopoDS_Shape newE = EspON;
newE.Orientation(neworiE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debaddpwes(iFOR,TB1,iEG,neworiE,myPB,myPWES,"yap00 GFillON","WES+ EspON ");
if (tE) FUN_cout(newE);
#endif
//=========================================
if ( yap0 ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debfillonfemess(iFOR,iEG,myPB,myPWES,"yap0 GFillON");
if (tE) {cout<<"yap0(FOR"<<iFOR<<" FS"<<iFS<<" EG"<<GI<<") ";
cout<<"TB1=";TopAbs::Print(TB1,cout);cout<<" TB2=";TopAbs::Print(TB2,cout);cout<<endl;}
} // hsdFOR
newE.Orientation(neworiE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debaddpwes(iFOR,TB1,iEG,neworiE,myPB,myPWES,"yap0 GFillON","WES+ EspON ");
if (tE) FUN_cout(newE);
#endif
//=========================================
if ( yapc1 ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debfillonfemess(iFOR,iEG,myPB,myPWES,"yapc1 GFillON");
if (tE) {cout<<"yapc1(FOR"<<iFOR<<" FS"<<iFS<<" EG"<<GI<<") ";
cout<<"TB1=";TopAbs::Print(TB1,cout);cout<<" TB2=";TopAbs::Print(TB2,cout);cout<<endl;}
if (!ok) return; //nyiRAISE
Standard_Boolean samegeom; ok = FUN_tool_curvesSO(EG,parEG,e3d,samegeom);
if (!ok) return; //nyiRAISE
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (!TopOpeBRepBuild_GetcontextNOSG()) {
#endif
if (!samegeom) oe3dk = TopAbs::Complement(oe3dk);
-#ifdef DEB
+#ifdef OCCT_DEBUG
}
#endif
else if (oe3dk == TopAbs_INTERNAL) keep3d = Standard_True;
else if (oe3dk == TopAbs_EXTERNAL) keep3d = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// if(tEFOR) {cout<<endl<<"yapc1 keep3d : "<<keep3d<<endl;debfillonfemess3d(iFOR,iEG);}
#endif
TopoDS_Shape newE = EspON;
newE.Orientation(neworiE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debaddpwes(iFOR,TB1,iEG,neworiE,myPB,myPWES,"yapc1 GFillON","WES+ EspON ");
if (tE) FUN_cout(newE);
#endif
//=========================================
if ( yapc2 ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debfillonfemess(iFOR,iEG,myPB,myPWES,"yapc2 GFillON");
if (tE) {cout<<"yapc2(FOR"<<iFOR<<" FS"<<iFS<<" EG"<<GI<<") ";
cout<<"TB1=";TopAbs::Print(TB1,cout);cout<<" TB2=";TopAbs::Print(TB2,cout);cout<<endl;}
else if (M_INTERNAL(neworiE)) addFORREV = Standard_True;
newE.Orientation(neworiEk);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) {
if (!isclosedFF)
debaddpwes(iFOR,TB1,iEG,neworiE,myPB,myPWES,"yapc2 GFillON","WES+ EspON not closed");
//=========================================
if ( yapc3 ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debfillonfemess(iFOR,iEG,myPB,myPWES,"yapc3 GFillON");
if (tE) {cout<<"yapc3(FOR"<<iFOR<<" FS"<<iFS<<" EG"<<GI<<") ";
cout<<"TB1=";TopAbs::Print(TB1,cout);cout<<" TB2=";TopAbs::Print(TB2,cout);cout<<endl;}
Standard_Boolean samegeom; Standard_Boolean ok = FUN_tool_curvesSO(eON,EG,samegeom);
if (!ok) return; // nyiRAISE
Standard_Boolean reverse = (!samegeom);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GetcontextNOSG())
// MSV 21.03.2002: restore the genaral behaviour, since the function
// FUN_UNKFstasta was corrected.
- reverse = Standard_False; //we exclude this line from #ifdef DEB because
+ reverse = Standard_False; //we exclude this line from #ifdef OCCT_DEBUG because
//in optimised mode this line will never be included , and that follows to regressions
//MZV-12-05-2000
#endif
newE.Orientation(neworiEk);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) {
if (!addFORREV)
debaddpwes(iFOR,TB1,iEG,neworiEk,myPB,myPWES,"yapc3 GFillON","WES+ EspON ");
TopAbs_Orientation orefFCX = BDS.Shape(irefFCX).Orientation();
Standard_Boolean FCXisref = (irefFCX == iFCX);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Real tolFCX = factor*BRep_Tool::Tolerance(FCX); //NYITOLXPU
#endif
yap6b = yap6b && eONFS; //xpu240898
yap6b = yap6b && !eghassd3d;// yap6b = yap6b && !eghassd3dON;
if (yap6b) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
// FUN_RaiseON();
#endif
yap2 = Standard_True;
TopAbs_State staFOR = TB1;
TopAbs_State staFS = (rankFS == rankFOR) ? TB1 : TB2;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// if(tEFOR) cout<<endl<<"yap1 yap2 yap3 yap4 = ";
// if(tEFOR) cout<<yap1<<" "<<yap2<<" "<<yap3<<" "<<yap4<<endl<<endl;
// if(tEFOR) debfillonfemess(iFOR,iEG);
//=========================================
if ( yap1 ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debfillonfemess(iFOR,iEG,myPB,myPWES,"yap1 GFillON");
if (tE) {cout<<"yap1(FOR"<<iFOR<<" FCX"<<iFCX<<" EG"<<GI<<") ";
cout<<"TB1=";TopAbs::Print(TB1,cout);cout<<" TB2=";TopAbs::Print(TB2,cout);cout<<endl;}
TopoDS_Shape newE = EspON;
newE.Orientation(neworiE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debaddpwes(iFOR,TB1,iEG,neworiE,myPB,myPWES,"yap1 GFillON","WES+ EspON ");
if (tE) FUN_cout(newE);
#endif
//=========================================
if ( yap2 ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debfillonfemess(iFOR,iEG,myPB,myPWES,"yap2 GFillON");
if (tE) {cout<<"yap2(FOR"<<iFOR<<" FCX"<<iFCX<<" EG"<<GI<<") ";
cout<<"TB1=";TopAbs::Print(TB1,cout);cout<<" TB2=";TopAbs::Print(TB2,cout);cout<<endl;}
else if (oegFCXF == TopAbs_REVERSED) b2d = (Tbef == TopAbs_IN);
else FUN_coutmess("DEBUG GFillONPartsWES2_4 orientation != F,R\n");
}
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
// if(tEFOR) {cout<<endl<<"yap2 : b3d,b2d "<<b3d<<","<<b2d<<endl;debfillonfemess(iFOR,iEG);}
//#endif
}
}
}
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
// if(tEFOR) {cout<<endl<<"yap2 : keep "<<keep<<endl;debfillonfemess(iFOR,iEG);}
//#endif
if (!keep) return;
TopoDS_Shape newE = EspON;
newE.Orientation(neworiE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debaddpwes(iFOR,TB1,iEG,neworiE,myPB,myPWES,"yap2 GFillON","WES+ EspON ");
if (tE) FUN_cout(newE);
#endif
//=========================================
if ( yap6 ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debfillonfemess(iFOR,iEG,myPB,myPWES,"yap6 GFillON");
if (tE) {cout<<"yap6(FOR"<<iFOR<<" FCX"<<iFCX<<" EG"<<GI<<") ";
cout<<"TB1=";TopAbs::Print(TB1,cout);cout<<" TB2=";TopAbs::Print(TB2,cout);cout<<endl;}
Standard_Boolean SO = FFinSDSO;//(FFinSDSO && (oFOR == oFCX)) || (FFinSDDO && (oFOR != oFCX));
Standard_Boolean DO = FFinSDDO;//(FFinSDSO && (oFOR != oFCX)) || (FFinSDDO && (oFOR == oFCX));
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer rkToFill = BDS.AncestorRank(myFace);
#endif
// Standard_Boolean samerk = (rankEG == rkToFill);
gp_Vec ntOOFOR = FUN_tool_nggeomF(uv,OOFOR);
if (OOFOR.Orientation() == TopAbs_REVERSED) ntOOFOR.Reverse();
// xxFCX :
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Real t1 =factor*BRep_Tool::Tolerance(Esd);
#endif
Standard_Real parEG; ok = FUN_tool_parE(Esd,parEsd,EG,parEG);
TopoDS_Shape newE = EspON;
newE.Orientation(neworiE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debaddpwes(iFOR,TB1,iEG,neworiE,myPB,myPWES,"yap6 GFillON","WES+ EspON ");
if (tE) FUN_cout(newE);
#endif
if (addtwice) {
neworiE = TopAbs::Complement(neworiE);
newE.Orientation(neworiE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debaddpwes(iFOR,TB1,iEG,neworiE,myPB,myPWES,"yap6 GFillON","WES+ EspON ");
if (tE) FUN_cout(newE);
#endif
//=========================================
if ( yap3 ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debfillonfemess(iFOR,iEG,myPB,myPWES,"yap3 GFillON");
if (tE) {cout<<"yap3(FOR"<<iFOR<<" FCX"<<iFCX<<" EG"<<GI<<") ";
cout<<"TB1=";TopAbs::Print(TB1,cout);cout<<" TB2=";TopAbs::Print(TB2,cout);cout<<endl;}
if (!ok) return; //nyiRAISE
Standard_Boolean samegeom; ok = FUN_tool_curvesSO(EG,parEG,e3d,samegeom);
if (!ok) return; //nyiRAISE
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (!TopOpeBRepBuild_GetcontextNOSG()) {
#endif
if (!samegeom) oe3dk = TopAbs::Complement(oe3dk);
-#ifdef DEB
+#ifdef OCCT_DEBUG
}
#endif
else if (oe3dk == TopAbs_INTERNAL) keep3d = Standard_True;
else if (oe3dk == TopAbs_EXTERNAL) keep3d = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tEFOR) {cout<<endl<<"yap3 keep3d : "<<keep3d<<endl;debfillonfemess3d(iFOR,iEG);}
#endif
TopoDS_Shape newE = EspON;
newE.Orientation(neworiE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debaddpwes(iFOR,TB1,iEG,neworiE,myPB,myPWES,"yap3 GFillON","WES+ EspON ");
if (tE) FUN_cout(newE);
#endif
//=========================================
if ( yap5 ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debfillonfemess(iFOR,iEG,myPB,myPWES,"yap5 GFillON");
if (tE) {cout<<"yap5(FOR"<<iFOR<<" FCX"<<iFCX<<" EG"<<GI<<") ";
cout<<"TB1=";TopAbs::Print(TB1,cout);cout<<" TB2=";TopAbs::Print(TB2,cout);cout<<endl;}
if (!ok) return; // nyiRAISE
Standard_Boolean samegeom; ok = FUN_tool_curvesSO(EG,parEG,e2d,samegeom);
if (!ok) return; // nyiRAISE
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (!TopOpeBRepBuild_GetcontextNOSG()) {
#endif
if (!samegeom) oe2dk = TopAbs::Complement(oe2dk);
-#ifdef DEB
+#ifdef OCCT_DEBUG
}
#endif
TopoDS_Shape newE = EspON;
newE.Orientation(neworiE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debaddpwes(iFOR,TB1,iEG,neworiE,myPB,myPWES,"yap5 GFillON","WES+ EspON ");
if (tE) FUN_cout(newE);
#endif
//=========================================
if ( yap4 ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debfillonfemess(iFOR,iEG,myPB,myPWES,"yap4 GFillON");
if (tE) {cout<<"yap4(FOR"<<iFOR<<" FCX"<<iFCX<<" EG"<<GI<<") ";
cout<<"TB1=";TopAbs::Print(TB1,cout);cout<<" TB2=";TopAbs::Print(TB2,cout);cout<<endl;}
TopAbs_Orientation neworiE = oTFE;
TopoDS_Shape newE = EspON;
newE.Orientation(neworiE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debaddpwes(iFOR,TB1,iEG,neworiE,myPB,myPWES,"yap4 GFillON","WES+ EspON ");
if (tE) FUN_cout(newE);
#endif
//=========================================
if ( yap7 ) {
// xpu290598 : CTS20212
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debfillonfemess(iFOR,iEG,myPB,myPWES,"yap7 GFillON");
if (tE) {cout<<"yap7(FOR"<<iFOR<<" FCX"<<iFCX<<" EG"<<GI<<") ";
cout<<"TB1=";TopAbs::Print(TB1,cout);cout<<" TB2=";TopAbs::Print(TB2,cout);cout<<endl;}
TopoDS_Shape newE = EspON;
newE.Orientation(neworiE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tEFOR) debaddpwes(iFOR,TB1,iEG,neworiE,myPB,myPWES,"yap7 GFillON","WES+ EspON ");
if (tE) FUN_cout(newE);
#endif
#define M_FORWARD(st) (st == TopAbs_FORWARD)
#define M_REVERSED(st) (st == TopAbs_REVERSED)
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_EXPORT Standard_Boolean TopOpeBRepBuild_GetcontextEINTERNAL();
Standard_EXPORT Standard_Boolean TopOpeBRepBuild_GetcontextEEXTERNAL();
Standard_EXPORT void debfillonf(const Standard_Integer iF);
if (GLOBAL_DS2d == NULL) GLOBAL_DS2d = (TopOpeBRepDS_PDataStructure)new TopOpeBRepDS_DataStructure();
const TopOpeBRepDS_ListOfInterference& lFEI = GLOBAL_DS2d->ShapeInterferences(FOR);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iFOR;Standard_Boolean tFOR=myPB->GtraceSPS(FOR,iFOR);
if (tFOR) debfillonf(iFOR);
if (tFOR) {cout<<endl<<"LI on F"<<iFOR<<":"<<endl;
TopOpeBRepDS_Kind GT,ST;Standard_Integer GI,SI;FDS_data(I,GT,GI,ST,SI);
const TopoDS_Edge& EG=TopoDS::Edge(BDS.Shape(GI));
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iEG=BDS.Shape(EG);
#endif
const TopTools_ListOfShape& lEspON=myPB->Splits(EG,TopAbs_ON);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nEspON=lEspON.Extent();
#endif
for(TopTools_ListIteratorOfListOfShape it(lEspON);it.More();it.Next()) {
Standard_Boolean EGBoundFOR=SSI->GBound();
const TopoDS_Face& FOR=TopoDS::Face(myFace); Standard_Integer iFOR=BDS.Shape(FOR);
const TopoDS_Edge& EG=TopoDS::Edge(BDS.Shape(GI));
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iEG=BDS.Shape(EG);
#endif
const TopoDS_Face& FS=TopoDS::Face(BDS.Shape(SI));
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iFS=BDS.Shape(FS);
// Standard_Boolean isclosedFF=BRep_Tool::IsClosed(EG,FOR);
// Standard_Boolean isclosedFS=BRep_Tool::IsClosed(EG,FS);
// Standard_Integer rankFS=myPB->GShapeRank(FS);
#endif
Standard_Integer rankEG=myPB->GShapeRank(EG);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer rankFOR=myPB->GShapeRank(FOR);
#endif
// TopAbs_State TBEG = (rankEG == 1) ? TB1 : TB2;
TopAbs_State TBEG = FUN_build_TB(myPB,rankEG);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// TopAbs_State TFEbef = TFE.Before();
// TopAbs_State TFEaft = TFE.After();
// Standard_Boolean EGboundFOR =
#endif
Standard_Boolean eghassd = HDS->HasSameDomain(EG);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tFOR=myPB->GtraceSPS(iFOR);
// Standard_Boolean tE=myPB->GtraceSPS(GI);
// Standard_Boolean tEFOR = (tE && tFOR);
Standard_Integer iFCX=SI;
Standard_Boolean FFinSDSO = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean FFinSDDO = Standard_False;
#endif
Standard_Boolean FFinSD= Standard_True;
TopoDS_Face FCX = FS;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// TopAbs_Orientation oFOR = BDS.Shape(iFOR).Orientation();
// TopAbs_Orientation oFS = BDS.Shape(iFS).Orientation();
// TopAbs_Orientation oFCX = BDS.Shape(iFCX).Orientation();
TopAbs_Orientation oegFCXF;Standard_Boolean EGBoundFCX = FUN_tool_orientEinFFORWARD(EG,FCX,oegFCXF);
TopAbs_Orientation oegFCX ;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean ok2 =
#endif
FUN_tool_orientEinF(EG,FCX,oegFCX);
//=========================================
if ( yap6) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tFOR) cout<<"* yap6 = 1"<<endl;
#endif
TopAbs_Orientation neworiE = TopAbs_FORWARD;
Standard_Boolean b = Standard_False;
Standard_Boolean SO = FFinSDSO;//(FFinSDSO && (oFOR == oFCX)) || (FFinSDDO && (oFOR != oFCX));
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer rkToFill = BDS.AncestorRank(myFace); //DEB
#endif
Standard_Boolean rk1 = (rankEG == 1);
else if (EGBoundFOR)
ok = FUN_ds_shareG(myPB->DataStructure(),iFCX,iFOR,GI,TopoDS::Edge(EspON),shareG);
if (!ok) return; // nyiFUNRAISE
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tFOR) cout<<" shareG="<<shareG<<endl;
#endif
TopoDS_Shape newE = EspON;
newE.Orientation(neworiE);
myPWES->AddStartElement(newE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tFOR) cout<<" add spON e"<<GI<<endl;
#endif
return;
// avec un shell qui a ete deja ete place dans le solide interne du
// TopOpeBRepTool_SolidClassifier par LoadShell.
-#ifdef DEB
+#ifdef OCCT_DEBUG
//static Standard_Integer dddjyl = 0;
//static Standard_Integer dddebi = 0;
//static Standard_Integer dddebi2 = 0;
#include <Bnd_Box.hxx>
#include <TopOpeBRepTool_FuseEdges.hxx>
#include <Standard_ProgramError.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GetcontextNOFE();
#endif
const TopTools_ListOfShape& lmergesha1 = Merged(myShape1,myState1);
TopTools_ListIteratorOfListOfShape it(lmergesha1); for(;it.More();it.Next()) B.Add(R,it.Value());
const TopTools_ListOfShape& LOES = Section();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nLOES = LOES.Extent();
#endif
if ( !isbe ) continue;
const TopTools_ListOfShape& loe1 = idmovloe.FindFromIndex(iv);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nloe1 = loe1.Extent();
#endif
TopTools_MapOfShape mose; //une seule fois chaque arete
Standard_Boolean isb = mose.Contains(E); if (isb) continue;
mose.Add(E);loe.Append(E);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nloe = loe.Extent();
#endif
TP(++nP2) = Pv;
}
const TopTools_ListOfShape& lof = idmoelof.FindFromKey(E);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nlof = lof.Extent();
#endif
for (TopTools_ListIteratorOfListOfShape ilof(lof);ilof.More();ilof.Next()) {
gp_Pnt P2(aXmax, aYmax, aZmax);
Standard_Real d = P1.Distance(P2);
if (d > newtol) {
-#ifdef TOPOPEBREPBUILD_DEB
+#ifdef OCCT_DEBUG
cout<<"\npoint P"<<iv<<" "<<Pv.X()<<" "<<Pv.Y()<<" "<<Pv.Z()<<endl;
cout<<"TopOpeBRepBuild_Builder::End BOX newtol "<<newtol<<" -> "<<d<<endl;
#endif
}
Standard_Boolean makeFE = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
makeFE = !TopOpeBRepBuild_GetcontextNOFE();
#endif
#include <Standard_ProgramError.hxx>
#include <TopOpeBRepDS_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GetcontextNOREGUFA();
extern Standard_Boolean TopOpeBRepBuild_GetcontextREGUXPU();
extern Standard_Boolean TopOpeBRepBuild_GettraceSAVFREGU();
const TopoDS_Shape& newFace = itl.Value();
TopTools_ListOfShape newFaceLOF;
RegularizeFace(FF,newFace,newFaceLOF);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nnewFaceLOF = newFaceLOF.Extent(); // DEB
#endif
LOF.Append(newFaceLOF);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nLOF = LOF.Extent(); // DEB
#endif
for (x.Init(fsdFF,TopAbs_EDGE);x.More();x.Next()) {
// for (TopExp_Explorer x(fsdFF,TopAbs_EDGE);x.More();x.Next()) {
const TopoDS_Shape& e = x.Current();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer ie = myDataStructure->Shape(e); //DEB
// Standard_Boolean issect = myDataStructure->DS().IsSectionEdge(TopoDS::Edge(e));
#endif
if (!issplite) continue;
TopTools_ListOfShape& lspe = ChangeSplit(e,stae);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nlspe = lspe.Extent(); // DEB
#endif
TopTools_ListOfShape newlspe;
Standard_Boolean toregu = Standard_True;
Standard_Boolean usewtof = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF;Standard_Boolean tSPSFF=GtraceSPS(FF,iF);
// Standard_Boolean savfregu = TopOpeBRepBuild_GettraceSAVFREGU();
if (TopOpeBRepBuild_GetcontextNOREGUFA()) toregu = Standard_False;
}
}
wtof.MakeFaces(newFace,newfaces);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nnewfaces = newfaces.Extent(); // DEB
#endif
rf = (newfaces.Extent() != 0);
return;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPSFF) { cout<<"RegularizeFace "<<iF<<endl; debregufa(iF); }
#endif
for (; itlfsdFF.More(); itlfsdFF.Next()) {
const TopoDS_Shape& fsdFF = itlfsdFF.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer ifsdFF=0;Standard_Boolean tSPSfsdFF=GtraceSPS(fsdFF,ifsdFF);
if (tSPSfsdFF) debregufa(ifsdFF);
#endif
Standard_Integer rankfsdFF = GShapeRank(fsdFF);
TopAbs_State stafsdFF = (rankfsdFF == 1) ? myState1 : myState2;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean issplitfsdFF = IsSplit(fsdFF,stafsdFF);
#endif
-/*#ifdef DEB
+/*#ifdef OCCT_DEBUG
const TopTools_ListOfShape& lspfsdFF = Splits(fsdFF,stafsdFF);
Standard_Integer nlspfsdFF = lspfsdFF.Extent();
#endif*/
//fsdFFe : 1 edge de fsdFF = 1 face SameDomain de FF
const TopoDS_Shape& fsdFFe = x.Current();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer ifsdFFe = 0;Standard_Boolean tSPSfsdFFe=GtraceSPS(fsdFFe,ifsdFFe);
if (tSPSfsdFFe) debregufa(ifsdFFe);
#endif
if (iiista == 2) stafsdFFe = TopAbs_ON;
TopTools_ListOfShape& lspfsdFFe = ChangeSplit(fsdFFe,stafsdFFe);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean issplitfsdFFe = IsSplit(fsdFFe,stafsdFFe);
// Standard_Integer nlspfsdFFe = lspfsdFFe.Extent();
#endif
#include <TColStd_ListIteratorOfListOfInteger.hxx>
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GettracePURGE();
extern Standard_Boolean TopOpeBRepDS_GettraceSTRANGE();
#include <TopOpeBRepDS_DSX.hxx>
void TopOpeBRepBuild_FaceBuilder::InitFaceBuilder(TopOpeBRepBuild_WireEdgeSet& WES,const TopoDS_Shape& F,const Standard_Boolean ForceClass)
{
myFace = TopoDS::Face(F);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean deb = TopOpeBRepDS_GettraceSPSX(myFace);
if (deb) debifb();
#endif
const TopTools_IndexedDataMapOfShapeShape& mapVon1Edge)
{
// prequesitory : edges described by <mapVon1Edge> are not closed,not degenerated
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSTRANGE();
if (TopOpeBRepBuild_GettracePURGE()) {
cout<<endl<<"* CorrectGclosedWire :"<<endl<<endl;
TopoDS_Vertex newVref = TopoDS::Vertex(aLocalShape);
// TopoDS_Vertex newVref = TopoDS::Vertex(Vref.Oriented(V.Orientation()));
BB.Add(E,newVref);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iV = i,iVref = mapVVref.FindIndex(Vref),iE = mapVon1Edge.FindIndex(V);
if (trc) cout << " replacing V "<<iV<<" with V "<<iVref<<" on edge "<<iE<<endl;
#endif
//=======================================================================
Standard_Integer TopOpeBRepBuild_FaceBuilder::EdgeConnexity(const TopoDS_Shape& /*E*/) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_ProgramError::Raise("FaceBuilder::EdgeConnexity management disactivated");
#endif
return 0;
TopOpeBRepDS_Config ssc = myDataStructure->SameDomainOrientation(S1);
if ( ssc == TopOpeBRepDS_DIFFORIENTED ) {
RevOri = ! RevOri;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iFace = myDataStructure->Shape(S1);
// cout<<endl<<"********** ";
// cout<<"retournement d'orientation de ";TopAbs::Print(t,cout);
TopOpeBRepBuild_WireEdgeSet& WES,
const Standard_Boolean RevOri)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tSPF = TopOpeBRepBuild_GettraceSPF();
// Standard_Integer iFace = myDataStructure->Shape(F1);
if(tSPF){cout<<endl;}
PVS.Append(PV);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
const TopoDS_Edge& EDEB = PVS.Edge();
Standard_Integer iE; Standard_Boolean tSPS = GtraceSPS(EDEB,iE);
if (tSPS) {
#include <ElCLib.hxx>
#include <Precision.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GettraceFUFA();
#endif
const TopTools_ListOfShape& LRF,
const Standard_Integer CXM)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepBuild_GettraceFUFA();
if (trc) cout << "TopOpeBRepBuild_FuseFace::Init" << endl;
#endif
else if(CXM == 2) {
myInternal = Standard_True;
} // CXM
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
if (myInternal) {
cout << " TopOpeBRepBuild_FuseFace::Init : Keep internal connections" << endl;
void TopOpeBRepBuild_FuseFace::PerformFace()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepBuild_GettraceFUFA();
if (trc) cout << "TopOpeBRepBuild_FuseFace::PerformFace()" << endl;
#endif
myModified = Standard_False;
myLFF.Clear();
if (myLRF.IsEmpty()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::PerformFace : Empty list of reconstructed faces"<<endl;
#endif
myModified = Standard_False;
Standard_Integer number = myLRF.Extent();
if (number == 1) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::PerformFace : only 1 reconstructed face"<<endl;
#endif
myModified = Standard_False;
BRepCheck_Analyzer ana(fac);
if (!ana.IsValid(fac)) {
// if (!BRepCheck_Analyzer::IsValid(fac)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::PerformFace : Invalid reconstructed face"<<endl;
#endif
myModified = Standard_False;
// Orientation 3d de l'espace limite par la face
if (Ori3dForward && Ori3dReversed) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::PerformFace : Bad faces 3d orientation"<<endl;
#endif
myModified = Standard_False;
TopTools_DataMapOfShapeListOfShape mapFacLFac;
GroupShape(mylist,Keep_Edge,mapFacLFac);
if (mapFacLFac.IsEmpty()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::PerformFace : Empty list of faces"<<endl;
#endif
myModified = Standard_False;
Standard_Integer n1 = myLRF.Extent();
Standard_Integer n2 = mapFacLFac.Extent();
if (n1 == n2) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::PerformFace : No connection"<<endl;
#endif
myModified = Standard_False;
TopTools_DataMapOfShapeListOfShape mapWirLWir;
GroupShape(LWir,Keep_Edge,mapWirLWir);
if (mapWirLWir.IsEmpty()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::PerformFace : Empty list of wires"<<endl;
#endif
myModified = Standard_False;
TopTools_DataMapOfShapeListOfShape mapEdgLEdg;
GroupShape(LEdg,Keep_Edge,mapEdgLEdg);
if (mapEdgLEdg.IsEmpty()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::PerformFace : Empty list of edges"<<endl;
#endif
myModified = Standard_False;
ori1 = edg1.Orientation();
if (ori1 == TopAbs_REVERSED) {
if (OriReversed) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::PerformFace : Bad faces orientation"<<endl;
#endif
myModified = Standard_False;
}
else if (ori1 == TopAbs_FORWARD) {
if (OriForward) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::PerformFace : Bad faces orientation"<<endl;
#endif
myModified = Standard_False;
BRepLib_MakeWire MW;
MW.Add(myWireLE);
if (!MW.IsDone()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::PerformFace : Failure in making wire"<<endl;
#endif
myModified = Standard_False;
}
if (!MF.IsDone()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::PerformFace : Failure in making face"<<endl;
#endif
myModified = Standard_False;
} // mapFacLFac
if (myLFF.IsEmpty()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::PerformFace : Empty list of fusionned faces"<<endl;
#endif
myModified = Standard_False;
myModified = Standard_True;
myDone = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " TopOpeBRepBuild_FuseFace::PerformFace() : Done" << endl;
#endif
}
void TopOpeBRepBuild_FuseFace::PerformEdge()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepBuild_GettraceFUFA();
if (trc) cout << "TopOpeBRepBuild_FuseFace::PerformEdge()" << endl;
#endif
myModified = Standard_True;
myDone = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " TopOpeBRepBuild_FuseFace::PerformEdge() : Done" << endl;
#endif
}
void TopOpeBRepBuild_FuseFace::ClearEdge()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepBuild_GettraceFUFA();
if (trc) cout << "TopOpeBRepBuild_FuseFace::ClearEdge()" << endl;
#endif
BRepLib_MakeWire MW;
MW.Add(myWireLE);
if (!MW.IsDone()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::ClearEdge : Failure in making wire"<<endl;
#endif
myModified = Standard_False;
// Fin Niveau 2
// Reconstrution de 1 face de LRF
if (myFaceLW.IsEmpty()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::ClearEdge : Empty list of wires"<<endl;
#endif
myModified = Standard_False;
MF.Add(wir1);
}
if (!MF.IsDone()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::ClearEdge : Failure in making face"<<endl;
#endif
myModified = Standard_False;
}
//Fin Niveau 1
if (myLFFnew.IsEmpty()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::ClearEdge : Empty list of fusionned faces"<<endl;
#endif
myModified = Standard_False;
myModified = Standard_True;
myDone = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " TopOpeBRepBuild_FuseFace::ClearEdge() : Done" << endl;
#endif
}
void TopOpeBRepBuild_FuseFace::ClearVertex()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepBuild_GettraceFUFA();
if (trc) cout << "TopOpeBRepBuild_FuseFace::ClearVertex()" << endl;
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " TopOpeBRepBuild_FuseFace::ClearVertex() : Done" << endl;
#endif
}
static void MakeEdge(TopTools_DataMapOfShapeListOfShape& mymapEdgLEdg)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepBuild_GettraceFUFA();
#endif
}
Standard_Integer number = myEdgeLV.Extent();
if (!(number == 2)){
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" TopOpeBRepBuild_FuseFace::MakeEdge : Failure in reconstructing new edge"<<endl;
#endif
return;
Standard_Boolean SameSupport(const TopoDS_Edge& E1,
const TopoDS_Edge& E2)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepBuild_GettraceFUFA();
#endif
typC1 != STANDARD_TYPE(Geom_Ellipse) &&
typC1 != STANDARD_TYPE(Geom_BSplineCurve) &&
typC1 != STANDARD_TYPE(Geom_BezierCurve)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout << " TopOpeBRepBuild_FuseFace : Type de Support non traite" << endl;
#endif
return Standard_False;
#include <TopoDS.hxx>
#include <TopOpeBRepBuild_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GetcontextSPEON();
#endif
Standard_Boolean hassame = myDataStructure->HasSameDomain(S);
Standard_Boolean tosplit = (!issplit) && (facshap || hasgeom || hassame);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iS; Standard_Boolean tSPS = GtraceSPS(S,iS);
if (tSPS) {
cout<<"GToSplit ";GdumpSHA(S);cout<<" ";TopAbs::Print(TB,cout);
}
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GetcontextSPEON()) { //CONTEXT
tSPS = Standard_True; //CONTEXT
Standard_Boolean hasON = Standard_False; //CONTEXT
Standard_Boolean hassame = myDataStructure->HasSameDomain(S);
Standard_Boolean tomerge = (!ismerged && hassame);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iS; Standard_Boolean tSPS = GtraceSPS(S,iS);
if(tSPS){cout<<"GToMerge ";GdumpSHA(S);cout<<" ";TopAbs::Print(TB,cout);}
if(tSPS){cout<<" "<<tomerge<<" : !ismerged "<<(!ismerged)<<" && hassame "<<hassame<<endl;}
TopTools_ListIteratorOfListOfShape it1(L1);
for (i=1 ; i<=nl1; i++) {
const TopoDS_Shape& S1 = it1.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iS1 = myDataStructure->Shape(S1);
#endif
TopTools_ListIteratorOfListOfShape itsd(myDataStructure->SameDomain(S1));
for (; itsd.More(); itsd.Next() ) {
const TopoDS_Shape& S2 = itsd.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iS2 = myDataStructure->Shape(S2);
#endif
Standard_Boolean found = GContains(S2,L2);
TopTools_ListIteratorOfListOfShape it2(L2);
for (i=1 ; i<=nl2; i++) {
const TopoDS_Shape& S2 = it2.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iS2 = myDataStructure->Shape(S2);
#endif
TopTools_ListIteratorOfListOfShape itsd(myDataStructure->SameDomain(S2));
for (; itsd.More(); itsd.Next() ) {
const TopoDS_Shape& S1 = itsd.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iS1 = myDataStructure->Shape(S1);
#endif
Standard_Boolean found = GContains(S1,L1);
it.Initialize(LSO);
if ( ! it.More() ) return;
const TopoDS_Shape& sref = it.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iref = myDataStructure->SameDomainReference(sref);
#endif
TopOpeBRepDS_Config oref = myDataStructure->SameDomainOrientation(sref);
GFindSamDom(LSO,LDO);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iS; Standard_Boolean tSPS = GtraceSPS(sref,iS);
if(tSPS) {
TCollection_AsciiString ss("GFindSamDom result on ");
for (it.Initialize(LSO); it.More(); it.Next() ) {
const TopoDS_Shape& s = it.Value();
TopOpeBRepDS_Config o = myDataStructure->SameDomainOrientation(s);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iS = myDataStructure->Shape(s);
#endif
if ( o == oref && !GContains(s,LLSO) ) LLSO.Append(s);
for (it.Initialize(LDO); it.More(); it.Next() ) {
const TopoDS_Shape& s = it.Value();
TopOpeBRepDS_Config o = myDataStructure->SameDomainOrientation(s);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iS = myDataStructure->Shape(s);
#endif
if ( o == oref && !GContains(s,LLSO) ) LLSO.Append(s);
{
for ( TopTools_ListIteratorOfListOfShape it1(L1); it1.More(); it1.Next() ) {
const TopoDS_Shape& s = it1.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iS = myDataStructure->Shape(s);
#endif
Standard_Integer r = GShapeRank(s);
#include <TopOpeBRepDS_Dumper.hxx>
#include <Standard_ProgramError.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_EXPORT Standard_Boolean TopOpeBRepBuild_GetcontextNOSG();
#endif
TopAbs_State TB1,TB2; G1.StatesON(TB1,TB2);
const TopoDS_Shape& E1 = LE1.First();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iE; Standard_Boolean tSPS1 = GtraceSPS(E1,iE);
if(tSPS1){
cout<<endl;cout<<"--- GMergeEdges "<<endl;
const TopoDS_Shape& E11 = it1.Value();
Standard_Boolean ismerged = IsMerged(E11,TB1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer i1; Standard_Boolean tSPS1 = GtraceSPS(E11,i1);
if(tSPS1){
cout<<endl;cout<<"--- GFillEdgesPVS ";GdumpSHA(E11);
const TopoDS_Shape& E2 = it2.Value();
Standard_Boolean ismerged = IsMerged(E2,TB2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer i2; Standard_Boolean tSPS2 = GtraceSPS(E2,i2);
if(tSPS2){
cout<<endl;
}
// Unused :
-/*#ifdef DEB
+/*#ifdef OCCT_DEBUG
static Standard_Integer FUN_getTRASHA(const Standard_Integer geti,
const TopOpeBRepDS_ListOfInterference& lFOR, const Standard_Integer FOR,
const TopOpeBRepDS_ListOfInterference& lREV, const Standard_Integer REV,
}
#endif*/
-#ifdef DEB
+#ifdef OCCT_DEBUG
void debfillp(const Standard_Integer i) {cout <<"+ + debfillp "<<i<<endl;}
void debfillpon(const Standard_Integer i) {cout <<"+ + debfillpon "<<i<<endl;}
void debfillpin(const Standard_Integer i) {cout <<"+ + debfillpin "<<i<<endl;}
const TopOpeBRepBuild_GTopo& G,
TopOpeBRepBuild_PaveSet& PVS)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// TopAbs_State TB1,TB2;
// G.StatesON(TB1,TB2);
// TopOpeBRepDS_Config GConf1 = G.Config1();
ShapeInterf = t1;
const TopOpeBRepDS_DataStructure& BDS = myDataStructure->DS();
const Standard_Integer iEDS = BDS.Shape(E);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer rkE = BDS.AncestorRank(E);
#endif
Standard_Boolean isSE = BDS.IsSectionEdge(TopoDS::Edge(E));
Standard_Boolean isEd;
isEd = BRep_Tool::Degenerated(TopoDS::Edge(E));
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean hsd = myDataStructure->HasSameDomain(E); //xpu170498
#endif
Standard_Boolean isfafa = BDS.Isfafa(); //xpu120598
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tSPSE=GtraceSPS(iEDS);
TCollection_AsciiString striE=TopOpeBRepDS::SPrint(TopAbs_EDGE,iEDS);
const TopoDS_Shape& EPVS=PVS.Edge();Standard_Integer iEPVS;Standard_Boolean tSPSEPVS=GtraceSPS(EPVS,iEPVS);
Standard_Boolean isspin=(GLOBAL_issp==TheIN), isspou=(GLOBAL_issp==TheOUT), isspon=(GLOBAL_issp==TheON);
if (isSE && (GLOBAL_issp == 0)) return; // splits done in process ProcessSectionEdges
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iefil = BDS.Shape(E);
// Standard_Integer iffil = BDS.Shape(myFaceToFill);
// Standard_Integer ieref = BDS.Shape(myEdgeReference);
const TopOpeBRepDS_ListOfInterference& LICur = tki.Value(Kcur,Gcur);
Standard_Boolean point = (Kcur == TopOpeBRepDS_POINT); //xpu170498
Standard_Boolean vertex = (Kcur == TopOpeBRepDS_VERTEX);//xpu170498
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nLICur = LICur.Extent();
Standard_Boolean trcI = Standard_False;
if(trcI) {TopOpeBRepDS_Dumper DSD(myDataStructure); TCollection_AsciiString aa("lI");
TopOpeBRepDS_ListOfInterference li; li.Append(newI); TopOpeBRepDS_PointIterator itCur(li);
GFillPointTopologyPVS(E,itCur,G,PVS);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) {newI->Dump(cout,"\nnewinterf ","\n\n"); debfillp2(iEDS);}
#endif
{tki.Next(); continue;}
TopAbs_ShapeEnum SB1,SA1;Standard_Integer IB1,IA1;TopOpeBRepDS_Kind GT1,ST1;Standard_Integer G1,S1;
FDS_Idata(I1,SB1,IB1,SA1,IA1,GT1,G1,ST1,S1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) {I1->Dump(cout,"\n? keepinterf ","\n\n"); debfillp2(iEDS);}
#endif
// e27 possede des I de nature 2d et 3d en V8
// on privilegie l'info 3d
if (has2d3d && !isSE) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
const Handle(TopOpeBRepDS_Interference)& i2d =
#endif
l2dFEcur.First();
const Handle(TopOpeBRepDS_Interference)& i3d = l3dFcur.First();
Standard_Boolean id3d = (I1 == i3d);
-#ifdef DEB
- Standard_Boolean id2d = (I1 == i2d);
-#endif
keepinterf1 = id3d;
-#ifdef DEB
+#ifdef OCCT_DEBUG
+ Standard_Boolean id2d = (I1 == i2d);
if (tSPS) {
cout<<"DEB : GFillPointTopologyPVS E"<<iEDS<<" has2d3d"<<endl;
i2d->Dump(cout,"2d : ","\n");
const Handle(TopOpeBRepDS_Interference)& I1=EPit.Value();
TopOpeBRepDS_Kind ST1 = I1->SupportType();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iE; Standard_Boolean tSPSE = GtraceSPS(E,iE);
Standard_Integer iEPVS; Standard_Boolean tSPSEPVS = GtraceSPS(EPVS,iEPVS);
Standard_Boolean tSPS = tSPSE || tSPSEPVS;
Standard_Real par = EPit.Parameter();
TopAbs_Orientation ori = EPit.Orientation(TB);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( tSPS ) debfillp(iE);
#endif
Standard_Boolean samegeom = ::TopOpeBRepBuild_FUN_aresamegeom(E,EPVS);
if (Conf == TopOpeBRepDS_DIFFORIENTED) ori = TopAbs::Complement(ori);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (!TopOpeBRepBuild_GetcontextNOSG()) {
#endif
if (!samegeom) ori = TopAbs::Complement(ori);
-#ifdef DEB
+#ifdef OCCT_DEBUG
}
#endif
Standard_Real parref = par;
const TopoDS_Edge& EE = TopoDS::Edge(E);
GParamOnReference(VPV,EE,parref);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){
cout<<"par "<<par<<" / ";GdumpSHA(E);cout<<" --> parref "<<parref<<" / ";GdumpSHA(EPVS);
cout<<endl;
Standard_Boolean kpbound = Standard_False;
{
TopoDS_Vertex vclo; Standard_Boolean Eclosed = TopOpeBRepTool_TOOL::ClosedE(myEdgeReference,vclo);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer ivclo = myDataStructure->Shape(vclo);
#endif
TopAbs_Orientation oriI = EPit.Orientation(TopAbs_IN);
PVS.Append(PV);
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Pnt P = BRep_Tool::Pnt(VPV);
if(tSPS){cout<<"+";if(ispoint)cout<<" PDS ";else cout<<" VDS ";}
if(tSPS){cout<<iG<<" : ";GdumpORIPARPNT(ori,par,P);cout<<endl;}
PVF -> InterferenceType() = ST1;
PVS.Append(PVF);
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Pnt PF = BRep_Tool::Pnt(VPV);
if(tSPS){cout<<"+";if(ispoint)cout<<" PDS ";else cout<<" VDS ";}
if(tSPS){cout<<iG<<" : ";GdumpORIPARPNT(ovpv,parf,PF);cout<<endl;}
//modified by NIZHNY-MZV Mon Feb 21 14:48:37 2000
PVR -> InterferenceType() = ST1;
PVS.Append(PVR);
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Pnt PR = BRep_Tool::Pnt(VPV);
if(tSPS){cout<<"+";if(ispoint)cout<<" PDS ";else cout<<" VDS ";}
if(tSPS){cout<<iG<<" : ";GdumpORIPARPNT(ovpv,parl,PR);cout<<endl;}
Handle(Geom_Surface) su = BRep_Tool::Surface(myFaceReference);
Handle(Geom_Plane) suplan = Handle(Geom_Plane)::DownCast(su);
if ( suplan.IsNull() ) {
-#ifdef TOPOPEBREPBUILD_DEB
+#ifdef OCCT_DEBUG
cout<<"NYI : GParamOnReference : not planar"<<endl;
#endif
return Standard_False;
case GeomAbs_Parabola:
P = ElCLib::Parameter(AC.Parabola(),p2); break;
default :
-#ifdef TOPOPEBREPBUILD_DEB
+#ifdef OCCT_DEBUG
cout<<"NYI : GParamOnReference : OtherCurve on planar surface"<<endl;
#endif
return Standard_False;
#include <TopOpeBRepBuild_define.hxx>
#ifdef DRAW
-#include <TopOpeBRepDS_DSX.hxx>
Standard_IMPORT void FUN_draw(const TopoDS_Shape& s);
Standard_IMPORT void FUN_draw2de (const TopoDS_Shape& ed,const TopoDS_Shape& fa);
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
+#include <TopOpeBRepDS_DSX.hxx>
extern void* GFABUMAKEFACEPWES_DEB;
#define DEBSHASET(sarg,meth,shaset,str) TCollection_AsciiString sarg((meth));(sarg)=(sarg)+(shaset).DEBNumber()+(str);
Standard_Integer GLOBAL_iexE = 0;
//-------------------------------------------------------------
// Unused :
-/*#ifdef DEB
+/*#ifdef OCCT_DEBUG
//=======================================================================
//function :FUN_BUI_FACESINTERFER
//purpose :
// {I = (T(F),ES,FTRA)} / Fsdm F and ES interfers with E which has splits ON
// E is edge of F
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF;Standard_Boolean tF=BU.GtraceSPS(F,iF);
#endif
if (ok) {
newT.Index(ITRA); TopOpeBRepDS_Config C = TopOpeBRepDS_SAMEORIENTED;
Handle(TopOpeBRepDS_Interference) newI = TopOpeBRepDS_InterferenceTool::MakeFaceEdgeInterference(newT,ITRA,IE,Standard_True,C);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tF) {cout<<"f"<<IF<<" + ";newI->Dump(cout);cout<<endl;}
#endif
pDS2d->AddShapeInterference(F,newI);
if (ok) {
newT.Index(IF); TopOpeBRepDS_Config C = TopOpeBRepDS_SAMEORIENTED;
Handle(TopOpeBRepDS_Interference) newI = TopOpeBRepDS_InterferenceTool::MakeFaceEdgeInterference(newT,IF,IE,Standard_False,C);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tF) {cout<<"f"<<ITRA<<" + ";newI->Dump(cout);cout<<endl;}
#endif
pDS2d->AddShapeInterference(FTRA,newI);
if (ok) {
newT.Index(IF); TopOpeBRepDS_Config C = TopOpeBRepDS_SAMEORIENTED;
Handle(TopOpeBRepDS_Interference) newI = TopOpeBRepDS_InterferenceTool::MakeFaceEdgeInterference(newT,IF,S,Standard_True,C);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tF) {cout<<endl<<"f"<<ITRA<<" + ";newI->Dump(cout);cout<<endl;}
#endif
pDS2d->AddShapeInterference(FTRA,newI);
if (ok) {
newT.Index(ITRA); TopOpeBRepDS_Config C = TopOpeBRepDS_SAMEORIENTED;
Handle(TopOpeBRepDS_Interference) newI = TopOpeBRepDS_InterferenceTool::MakeFaceEdgeInterference(newT,ITRA,S,Standard_False,C);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tF) {cout<<"f"<<iF<<" + ";newI->Dump(cout);cout<<endl;}
#endif
pDS2d->AddShapeInterference(F,newI);
TopAbs_State TB1,TB2; G1.StatesON(TB1,TB2);
const TopoDS_Shape& F1 = LF1.First();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF; Standard_Boolean tSPS = GtraceSPS(F1,iF);
if(tSPS){
cout<<endl<<"--- GMergeFaces "<<endl;
// Build new faces LFM
TopTools_ListOfShape LFM;
-#ifdef DEB
+#ifdef OCCT_DEBUG
GFABUMAKEFACEPWES_DEB = (void*)&WES;
#endif
TopOpeBRepBuild_WireEdgeSet WES(FF,this);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF; Standard_Boolean tSPS = GtraceSPS(FF,iF);
if(tSPS) GdumpSHASTA(iF,TB1,WES,"\n--- GFillFacesWESMakeFaces");
if(tSPS) debfillf(iF);
TopTools_ListIteratorOfListOfShape it1;
for (it1.Initialize(LF1); it1.More(); it1.Next()) {
const TopoDS_Shape& S = it1.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iS; GtraceSPS(S,iS);
#endif
MarkSplit(S,TB1);
TopTools_ListIteratorOfListOfShape it2;
for (it2.Initialize(LF2); it2.More(); it2.Next()) {
const TopoDS_Shape& S = it2.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iS; GtraceSPS(S,iS);
#endif
MarkSplit(S,TB2);
TopAbs_State TB1,TB2; G1.StatesON(TB1,TB2);
Standard_Boolean RevOri1 = G1.IsToReverse1();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF; Standard_Boolean tSPS = GtraceSPS(FOR1,iF);
if(tSPS) GdumpSHASTA(iF,TB1,WES,"--- GFillFaceWES","START");
if(tSPS) debfillf(iF);
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) GdumpSHASTA(iF,TB1,WES,"--- GFillFaceWES","END");
#endif
{
TopAbs_State TB1,TB2; G1.StatesON(TB1,TB2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iW; Standard_Boolean tSPS = GtraceSPS(W,iW);
if(tSPS){
cout<<endl;DEBSHASET(s,"--- GFillWireWES ",WES," ");
for (; exEdge.More(); exEdge.Next()) {
const TopoDS_Shape& EOR = exEdge.Current();
-#ifdef DEB
+#ifdef OCCT_DEBUG
GLOBAL_iexE++;
if (tSPS) {
// const TopoDS_Edge& ed = TopoDS::Edge(EOR);
{
TopAbs_State TB1,TB2; G1.StatesON(TB1,TB2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iE; Standard_Boolean tSPS = GtraceSPS(EOR,iE);
if(tSPS)cout<<endl;
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tosplit =
#endif
GToSplit(EOR,TB1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tomerge =
#endif
GToMerge(EOR);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) GdumpSHASTA(iE,TB1,WES,"--- GFillEdgeWES ");
if(tSPS) cout<<" tosplit "<<tosplit<<" tomerge "<<tomerge<<endl;
if(tSPS) debfille(iE);
// if (cut && TBToFill==OUT) : myFaceToFill is the reference face,
// we keep original edge's orientation
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iEOR; Standard_Boolean tSPS = GtraceSPS(EOR,iEOR);
Standard_Integer iWESF; /*Standard_Boolean tSPSW = */GtraceSPS(WES.Face(),iWESF);
if(tSPS) GdumpSHASTA(iEOR,TB1,WES,"\n--- GSplitEdgeWES","START");
if ( issplit ) {
const TopTools_ListOfShape& LSE = Splits(EOR,TB1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) {
GdumpSHASTA(iEOR,TB1,WES,"--- GSplitEdgeWES","WES+ Split");
cout<<" ";TopAbs::Print(TB1,cout)<<" : "<<LSE.Extent()<<" edge(s) ";
Standard_Boolean so = Standard_True;
Standard_Boolean ok = FUN_tool_curvesSO(newE,par,TopoDS::Edge(EOR),so);
if (!ok) {
-#ifdef TOPOPEBREPBUILD_DEB
+#ifdef OCCT_DEBUG
cout<<"GSplitEdgeWES: cannot orient SDM split of an edge"<<endl;
#endif
//return; // nyiFUNRAISE
}// xpu060598
else newE.Orientation(neworiE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPS) debaddpwes(iWESF,TB1,iEOR,neworiE,(TopOpeBRepBuild_Builder* const)this,&WES,"GSplitEdgeWES " ,"WES+ Eisspl ");
#endif
addON = Standard_True;
}
-#ifdef DEBDEB
+#ifdef OCCT_DEBUG
cout<<"o-o GridFF ffil F"<<ifil<<" se E"<<iEOR<<" / "<<iWESF<<" ";
TopAbs::Print(TB1,cout);cout.flush();
Standard_Boolean tse = TopOpeBRepDS_GettraceSPSX(iEOR);
Standard_Boolean testkeep = Standard_True;
testkeep = hs && (!hg);
if (testkeep) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){cout<<"--- GSplitEdgeWES ";}
#endif
TopAbs_State pos;
else if (Oinref == FORREVOPPO) newE.Orientation(TopAbs_INTERNAL);// xpu120898 (PRO14785 : e36 shared by f34 & f39,
// faces sdm with f16)
else newE.Orientation(neworiE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){
DEBSHASET(ss,"--- GSplitEdgeWES ",WES," WES+ edge ");
GdumpSHA(newE,(Standard_Address)ss.ToCString());
#endif
if (isstart) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPS) debaddpwes(iWESF,TB1,iEOR,neworiE,(TopOpeBRepBuild_Builder* const)this,&WES,"GSplitEdgeWES " ,"WES+ Enospl ");
#endif
WES.AddStartElement(newE);
Standard_Boolean so = Standard_True;
Standard_Boolean ok = FUN_tool_curvesSO(newE,par,TopoDS::Edge(EOR),so);
if (!ok) {
-#ifdef TOPOPEBREPBUILD_DEB
+#ifdef OCCT_DEBUG
cout<<"GSplitEdgeWES: cannot orient SDM split of an edge"<<endl;
#endif
}
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) GdumpSHASTA(iEOR,TB1,WES,"--- GSplitEdgeWES","END");
#endif
Standard_IMPORT const TopOpeBRepBuild_GTopo& FUN_motherope();
Standard_EXPORT Standard_Boolean GLOBAL_IEtoMERGE = 0; // xpu240498
-#ifdef DEB
+#ifdef OCCT_DEBUG
void debmergee(const Standard_Integer /*i*/) {}
#endif
const TopOpeBRepBuild_GTopo& G1,
TopOpeBRepBuild_WireEdgeSet& WES)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iWESF; /*Standard_Boolean tSPSW = */GtraceSPS(WES.Face(),iWESF);
Standard_Integer iEOR; Standard_Boolean tSPS = GtraceSPS(EOR,iEOR);
if(tSPS){ debmergee(iEOR);
TopoDS_Shape newE = it.Value();
newE.Orientation(neworiE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPS) debaddpwes(iWESF,TB1,iEOR,neworiE,(TopOpeBRepBuild_Builder* const)this,&WES,"GMergeEdgeWES " ,"WES+ Emerge ");
#endif
ChangeMerged(EOR,TBEOR) = Splits(EOR,stspEOR);
const TopTools_ListOfShape& ME = Merged(EOR,TBEOR);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){
DEBSHASET(s,"GMergeEdgeWES(1) ",WES," WES+ Merged ");
GdumpSHA(EOR,(Standard_Address)s.ToCString());
WES.AddStartElement(newE);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){
DEBSHASET(sss,"GMergeEdgeWES ",WES," END ");
GdumpSHA(EOR,(Standard_Address)sss.ToCString());cout<<endl;
// work on a FORWARD edge <EF>
TopoDS_Shape EF = EOR; EF.Orientation(TopAbs_FORWARD);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iE; Standard_Boolean tSPS = GtraceSPS(EOR,iE);
if (tSPS) GdumpSHASTA(EOR,TB1,"--- GSplitEdge ","\n");
if (tSPS) GdumpEDG(EF);
Standard_Boolean issplitON = IsSplit(EEF,TopAbs_ON);
Standard_Boolean takeON = (TB1 == TopAbs_IN) && (isse) && (issplitON);
takeON = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPS) cout<<"---- takeON mis a 0"<<endl;
#endif
if ( takeON ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPS) GdumpSHASTA(EOR,TB1,"--- GSplitEdge takeON ","\n");
#endif
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
#define DEBSHASET(sarg,meth,shaset,str) TCollection_AsciiString sarg((meth));(sarg)=(sarg)+(shaset).DEBNumber()+(str);
extern Standard_Boolean TopOpeBRepDS_GettraceSTRANGE();
Standard_EXPORT void debsplitf(const Standard_Integer i){cout<<"++ debsplitf "<<i<<endl;}
if (!ok) return Standard_False; // nyi FUN_Raise
Standard_Integer iEinterf=0; Standard_Integer iG = FUN_getG(p3d,EPIlist,HDS,iEinterf);
if (iG == 0) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean strange = TopOpeBRepDS_GettraceSTRANGE();
if (strange) cout<<"strange : FUN_EPIforEvisoONperiodicF"<<endl;
#endif
Handle(Geom2d_TrimmedCurve) PCsup2pi = new Geom2d_TrimmedCurve(L2d,paronE,pl);
TopOpeBRepDS_SetThePCurve(BB,Esup2pi,F,oriE,PCsup2pi);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = Standard_False;
#ifdef DRAW
if (trc) {TCollection_AsciiString aa("PCinf");FUN_tool_draw(aa,Einf2pi,F,0);}
TopAbs_State TB1,TB2; G1.StatesON(TB1,TB2);
const TopoDS_Shape& SO1 = LSO1.First();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iSO; Standard_Boolean tSPS = GtraceSPS(SO1,iSO);
if(tSPS){
cout<<endl;
for(; it.More(); it.Next()) {
const TopoDS_Shape& S = it.Value();
Standard_Boolean tomerge = !IsMerged(S,TB);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iS; Standard_Boolean tSPS = GtraceSPS(S,iS);
if(tSPS){
cout<<endl;
for (; it.More(); it.Next()) {
const TopoDS_Shape& S = it.Value();
Standard_Boolean tomerge = !IsMerged(S,TB);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iS; Standard_Boolean tSPS = GtraceSPS(S,iS);
if(tSPS){
cout<<endl;
TopAbs_State TB1,TB2; G1.StatesON(TB1,TB2);
Standard_Boolean RevOri1 = G1.IsToReverse1();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iSO; Standard_Boolean tSPS = GtraceSPS(SO1,iSO);
if(tSPS){
cout<<endl;
TopAbs_Orientation neworiSH = Orient(oriSH,RevOri1);
SH.Orientation(neworiSH);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){
DEBSHASET(ss,"--- GFillSolidSFS ",SFS," AddShape SFS+ shell ");
GdumpSHA(SH,(Standard_Address)ss.ToCString());
//function : GFillSurfaceTopologySFS
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::GFillSurfaceTopologySFS(const TopoDS_Shape& SO1,
#else
void TopOpeBRepBuild_Builder::GFillSurfaceTopologySFS(const TopoDS_Shape&,
TopAbs_State TB1,TB2; G1.StatesON(TB1,TB2);
TopAbs_ShapeEnum t1,t2;
G1.Type(t1,t2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopAbs_ShapeEnum ShapeInterf = t1;
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iSO; Standard_Boolean tSPS = GtraceSPS(SO1,iSO);
if(tSPS){
cout<<endl;
else if (TB1 == TopAbs_IN ) TB = TopAbs_OUT;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iSO; Standard_Boolean tSPS = GtraceSPS(SFS.Solid(),iSO);
Standard_Integer iref = myDataStructure->Shape(mySolidReference);
Standard_Integer ifil = myDataStructure->Shape(mySolidToFill);
TopAbs_Orientation ori = SSit.Orientation(TB);
F.Orientation(ori);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPS){
DEBSHASET(ss,"--- GFillSurfaceTopologySFS ",SFS," AddElement SFS+ face ");
GdumpSHA(F,(Standard_Address)ss.ToCString());
{
TopAbs_State TB1,TB2; G1.StatesON(TB1,TB2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer ish; Standard_Boolean tSPS = GtraceSPS(SH,ish);
if(tSPS){
cout<<endl;
} // hsd
} // exFace.More()
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPS) {
SFS.DumpSS();
}
TopAbs_Orientation oriF = FOR.Orientation();
TopAbs_Orientation neworiF = Orient(oriF,RevOri1);
const TopOpeBRepDS_DataStructure& BDS = myDataStructure->DS();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iFOR =
#endif
BDS.Shape(FOR);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iiFOR; Standard_Boolean tSPS = GtraceSPS(FOR,iiFOR);
if(tSPS){
cout<<endl;
Standard_Integer rkAnc = BDS.AncestorRank(iAnc);
TopAbs_Orientation oAnc = BDS.Shape(iAnc).Orientation();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iFanc; Standard_Boolean tSPSa = GtraceSPS(BDS.Shape(iAnc),iFanc);
if (tSPSa) debspanc(iAnc);
#endif
GLOBAL_lfr1->Append(newF);
}
else {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){
DEBSHASET(ss,"--- GSplitFaceSFS ",SFS," AddStartElement SFS+ face ");
GdumpSHA(newF,(Standard_Address)ss.ToCString());
TopoDS_Shape F = FOR;
F.Orientation(neworiF);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){
DEBSHASET(ss,"--- GSplitFaceSFS ",SFS," AddElement SFS+ face ");
GdumpSHA(F,(Standard_Address)ss.ToCString());
(const TopoDS_Shape& FOR,const TopOpeBRepBuild_GTopo& G1,
TopOpeBRepBuild_ShellFaceSet& SFS)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iFOR; Standard_Boolean tSPS = GtraceSPS(FOR,iFOR);
if(tSPS){
cout<<endl;
GFindSameRank(LFSO,rankF,LFSO1); GFindSameRank(LFDO,rankF,LFDO1);
GFindSameRank(LFSO,rankX,LFSO2); GFindSameRank(LFDO,rankX,LFDO2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){
cout<<"--------- merge FACE "<<iFOR<<endl;
GdumpSAMDOM(LFSO1, (char *) "LFSO1 : ");
if (performcom) { PtrLF1 = &LFSO1; PtrLF2 = &LFDO2; }
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) {
cout<<"performcom : "<<performcom<<" ";
cout<<"makecomsam : "<<makecomsam<<" makcomdif : "<<makecomdif<<" ";
TopoDS_Shape newF = it.Value();
newF.Orientation(neworiF);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){
DEBSHASET(ss,"--- GMergeFaceSFS ",SFS," AddStartElement SFS+ face ");
GdumpSHA(newF,(Standard_Address)ss.ToCString());
}
} // performcom
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){cout<<"--------- end merge FACE "<<iFOR<<endl;}
#endif
TopOpeBRepDS_Kind GT,ST;Standard_Integer GI,SI;FDS_data(SSI,GT,GI,ST,SI);
const TopoDS_Face& FS = TopoDS::Face( HDS->Shape(SI));
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iFS =
#endif
HDS->Shape(FS);
if (!FSper) continue;
const TopoDS_Edge& EG = TopoDS::Edge(HDS->Shape(GI));
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iEG =
#endif
HDS->Shape(EG);
TopOpeBRepDS_DataStructure& BDS = HDS->ChangeDS();
TopOpeBRepDS_ListOfInterference EPIlist; FUN_getEPIonEds(FS,HDS,EPIlist);
TopOpeBRepDS_ListOfInterference loCPI;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean recadre =
#endif
FUN_EPIforEvisoONperiodicF(EG,FS,EPIlist, HDS,loCPI);
TopOpeBRepDS_ListOfInterference& lIEG = BDS.ChangeShapeInterferences(EG);
lIEG.Append(loCPI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSTRANGE();
if (trc) {cout<<"!! recadre is "; if (!recadre) cout<<"not ";
cout<<"done on face FS "<<iFS<<" for edge "<<iEG<<endl;}
// work on a FORWARD face <FForward>
TopoDS_Shape FF = FOR; FF.Orientation(TopAbs_FORWARD);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF; Standard_Boolean tSPS = GtraceSPS(FOR,iF);
if(tSPS){
cout<<endl;GdumpSHASTA(FOR,TB1,"--- GSplitFace ");
// Add ON parts (edges ON solid)
GFillONPartsWES(FOR,G1,LSclass,WES);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer n0 = WES.StartElements().Extent();
if(tSPS) cout <<"--> GSplitFace , after GFillONPartsWES nstartelWES = "<<n0<<endl;
#endif
// split the edges of FF : add split edges to WES
GFillFaceWES(FF,LSclass,G1,WES);
Standard_Integer n1 = WES.StartElements().Extent();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) cout <<"--> GSplitFace , after GFillFaceWES nstartelWES = "<<n1<<endl;
#endif
// add edges built on curves supported by FF
GFillCurveTopologyWES(FF,G1,WES);
Standard_Integer n2 = WES.StartElements().Extent();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) cout <<"--> GSplitFace , after GFillCurveTopologyWES nstartelWES = "<<n2<<endl;
#endif
#include <TCollection_AsciiString.hxx>
#include <TopOpeBRepBuild_WireEdgeSet.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceSPSX(const Standard_Integer);
extern Standard_Boolean TopOpeBRepDS_GettraceSPSXX(const Standard_Integer,const Standard_Integer);
static TCollection_AsciiString PRODINS("dins ");
//function : GdumpLS
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::GdumpLS(const TopTools_ListOfShape& L) const
{
TopTools_ListIteratorOfListOfShape it(L);
//function : PrintGeo
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::PrintGeo(const TopoDS_Shape& S)
{
if (S.ShapeType() == TopAbs_VERTEX) PrintPnt(TopoDS::Vertex(S));
//function : PrintSur
//purpose : print the name of a surface
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::PrintSur(const TopoDS_Face& F)
{
BRepAdaptor_Surface STA_Surface(F);
//function : PrintCur
//purpose : print the name of a curve
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::PrintCur(const TopoDS_Edge& E)
{
TopLoc_Location L; Standard_Real f,l;
//function : PrintPnt
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::PrintPnt(const TopoDS_Vertex& V)
{
GdumpPNT(BRep_Tool::Pnt(V));
//function : PrintOri
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::PrintOri(const TopoDS_Shape& S)
{
TopAbs::Print(S.Orientation(),cout);
//function : StringState
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
TCollection_AsciiString TopOpeBRepBuild_Builder::StringState(const TopAbs_State st)
#else
TCollection_AsciiString TopOpeBRepBuild_Builder::StringState(const TopAbs_State)
#endif
{
TCollection_AsciiString s;
-#ifdef DEB
+#ifdef OCCT_DEBUG
switch(st) {
case TopAbs_ON : s.AssignCat("ON"); break;
case TopAbs_IN : s.AssignCat("IN"); break;
//function : GdumpPNT
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::GdumpPNT(const gp_Pnt& P)
{
cout<<P.X()<<" "<<P.Y()<<" "<<P.Z(); cout.flush();
//function : GdumpORIPARPNT
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::GdumpORIPARPNT(const TopAbs_Orientation o,
const Standard_Real p,
const gp_Pnt& Pnt)
//function : GdumpEDGVER
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::GdumpEDGVER(const TopoDS_Shape& E,
const TopoDS_Shape& V,
const Standard_Address s) const
//function : GdumpEDG
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::GdumpEDG(const TopoDS_Shape& E,
const Standard_Address s) const
{
//function : GdumpSHA
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::GdumpSHA(const TopoDS_Shape& S,
const Standard_Address str) const
{
//function : GdumpSHAORI
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::GdumpSHAORI(const TopoDS_Shape& S,
const Standard_Address str) const
{
//function : GdumpSHAORIGEO
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::GdumpSHAORIGEO(const TopoDS_Shape& S,
const Standard_Address str) const
{
//function : GdumpSHASTA
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::GdumpSHASTA(const TopoDS_Shape& S,
const TopAbs_State T,
const TCollection_AsciiString& a,
//function : GdumpSHASTA
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::GdumpSHASTA(const Standard_Integer iS,
const TopAbs_State T,
const TCollection_AsciiString& a,
//function : GdumpSHASTA
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::GdumpSHASTA(const Standard_Integer iS,
const TopAbs_State T,
const TopOpeBRepBuild_ShapeSet& SS,
//=======================================================================
void TopOpeBRepBuild_Builder::GdumpSHASETreset()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
mySHASETindex = 0;
#endif
}
Standard_Integer TopOpeBRepBuild_Builder::GdumpSHASETindex()
{
Standard_Integer n = 0;
-#ifdef DEB
+#ifdef OCCT_DEBUG
n = ++mySHASETindex;
#endif
return n;
//function : GdumpEXP
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::GdumpEXP(const TopOpeBRepTool_ShapeExplorer& Ex) const
{
if ( ! Ex.More() ) return;
//=======================================================================
void TopOpeBRepBuild_Builder::GdumpSOBU(TopOpeBRepBuild_SolidBuilder& /*ME*/) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
#endif
} // GdumpSOBU
-#ifdef DEB
+#ifdef OCCT_DEBUG
void* GFABUMAKEFACEPWES_DEB = NULL;
#endif
//function : GdumpFABU
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_Builder::GdumpFABU(TopOpeBRepBuild_FaceBuilder& ME) const
{
const TopoDS_Shape& face = ME.Face();
//=======================================================================
void TopOpeBRepBuild_Builder::GdumpEDBU(TopOpeBRepBuild_EdgeBuilder& /*ME*/) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
#endif
} // GdumpEDBU
//function : GtraceSPS
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TopOpeBRepBuild_Builder::GtraceSPS(const Standard_Integer iS) const
#else
Standard_Boolean TopOpeBRepBuild_Builder::GtraceSPS(const Standard_Integer ) const
#endif
{
Standard_Boolean b = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer ibid;
b = GtraceSPS(myDataStructure->Shape(iS),ibid);
#endif
//function : GtraceSPS
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TopOpeBRepBuild_Builder::GtraceSPS(const Standard_Integer i,
const Standard_Integer j) const
#else
#endif
{
Standard_Boolean b = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
b = TopOpeBRepDS_GettraceSPSXX(i,j);
#endif
return b;
//function : GtraceSPS
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TopOpeBRepBuild_Builder::GtraceSPS(const TopoDS_Shape& S) const
#else
Standard_Boolean TopOpeBRepBuild_Builder::GtraceSPS(const TopoDS_Shape& ) const
#endif
{
Standard_Boolean b = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iS;
b = GtraceSPS(S,iS);
#endif
//function : GtraceSPS
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TopOpeBRepBuild_Builder::GtraceSPS(const TopoDS_Shape& S,
Standard_Integer& IS) const
#else
#endif
{
IS = 0; Standard_Boolean b = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( ! myDataStructure.IsNull() ) {
if ( ! S.IsNull() ) {
IS = myDataStructure->Shape(S);
//function : GcheckNBOUNDS
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TopOpeBRepBuild_Builder::GcheckNBOUNDS(const TopoDS_Shape& E)
#else
Standard_Boolean TopOpeBRepBuild_Builder::GcheckNBOUNDS(const TopoDS_Shape& )
#endif
{
Standard_Boolean res = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer nf = 0, nr = 0;
TopOpeBRepTool_ShapeExplorer ex(E,TopAbs_VERTEX);
for(; ex.More(); ex.Next()) {
for(;itloe.More();itloe.Next()) {
TopoDS_Shape& E = *((TopoDS_Shape*)(&itloe.Value()));
if(mySectEdgeDSCurve.IsBound(E)) {
-#ifdef TOPOPEBREPBUILD_DEB
+#ifdef OCCT_DEBUG
cout<<"BRepAlgo_DSAccess::MakeEdgeAncestorFromCurve : program error"<<endl;
#endif
}
#include <TopOpeBRepBuild_kpresu.hxx>
#include <Standard_ProgramError.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GettraceKPB();
#endif
static void FUN_Raise() {
-#ifdef DEB
+#ifdef OCCT_DEBUG
cout<<"******************************ERROR"<<endl;
Standard_ProgramError::Raise("KPart.cxx");
#endif
{
KPClearMaps();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TKPB = TopOpeBRepBuild_GettraceKPB();
if(TKPB){cout<<endl<<"--- IsKPart ? ---"<<endl;}
#endif
static void FUN_addf(const TopAbs_State sta, const TopoDS_Shape& ftoadd, TopTools_DataMapOfShapeShape& map)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean isadded = map.IsBound(ftoadd);
#endif
TopoDS_Shape fori = ftoadd;
// with {fcFk} = faces of shape k connexed to Owk
// fcFk has edges {edk}
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// const TopOpeBRepDS_DataStructure& BDS = HDS->DS();
// Standard_Integer rFk = BDS.AncestorRank(Fk);
#endif
return Standard_True;
} // FUN_rebuildfc
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_EXPORT void debiskoletge() {}
#endif
void TopOpeBRepBuild_Builder::MergeKPartiskoletge()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TKPB = TopOpeBRepBuild_GettraceKPB();
if (TKPB) KPreturn(myIsKPart);
debiskoletge();
TopTools_ListOfShape lplhsd2, lcyhsd2; ::FUN_sortplcy(lfhsd2,lplhsd2,lcyhsd2);
const TopoDS_Face& fac1 = TopoDS::Face(lplhsd1.First());
const TopoDS_Face& fac2 = TopoDS::Face(lplhsd2.First());
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF1 =
#endif
myDataStructure->Shape(fac1); //DEB
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF2 =
#endif
myDataStructure->Shape(fac2); //DEB
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TKPB) {cout<<""<<endl;cout<<"face "<<iF1<<" : ";cout<<iF2<<endl;}
#endif
void TopOpeBRepBuild_Builder::MergeKPartisdisj()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TKPB = TopOpeBRepBuild_GettraceKPB();
if (TKPB) KPreturn(myIsKPart);
#endif
return;
}
else {
-#ifdef TOPOPEBREPBUILD_DEB
+#ifdef OCCT_DEBUG
cout<<"TopOpeBRepBuild_MergeKPart soldisj : ires = "<<ires<<endl;
#endif
return;
void TopOpeBRepBuild_Builder::MergeKPartisfafa()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TKPB = TopOpeBRepBuild_GettraceKPB();
if (TKPB) KPreturn(myIsKPart);
#endif
void TopOpeBRepBuild_Builder::MergeKPartissoso()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TKPB = TopOpeBRepBuild_GettraceKPB();
if (TKPB) KPreturn(myIsKPart);
#endif
Standard_Integer TopOpeBRepBuild_Builder::KPiskoletge()
{
-/*#ifdef DEB
+/*#ifdef OCCT_DEBUG
Standard_Boolean TKPB = TopOpeBRepBuild_GettraceKPB();
#endif*/
// ------------------------------------
const TopoDS_Face& f1 = TopoDS::Face(lplhsd1.First());
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean isb1 = myKPMAPf1f2.IsBound(f1); // DEB
#endif
const TopoDS_Face& f2 = TopoDS::Face(lplhsd2.First());
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean isb2 = myKPMAPf1f2.IsBound(f2); // DEB
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF1,iF2;
Standard_Boolean tSPS1 = GtraceSPS(f1,iF1);
Standard_Boolean tSPS2 = GtraceSPS(f2,iF2);
Standard_Integer TopOpeBRepBuild_Builder::KPisdisj()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TKPB = TopOpeBRepBuild_GettraceKPB();
#endif
Standard_Integer isdisj1 = KPisdisjsh(myShape1);
Standard_Integer isdisj2 = KPisdisjsh(myShape2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TKPB) {
cout<<"isdisj : "<<isdisj1<<" "<<isdisj2<<endl;
}
Standard_Integer TopOpeBRepBuild_Builder::KPisfafa()
{
-/*#ifdef DEB
+/*#ifdef OCCT_DEBUG
Standard_Boolean TKPB = TopOpeBRepBuild_GettraceKPB();
#endif*/
Standard_Integer TopOpeBRepBuild_Builder::KPissoso()
{
-/*#ifdef DEB
+/*#ifdef OCCT_DEBUG
Standard_Boolean TKPB = TopOpeBRepBuild_GettraceKPB();
#endif*/
TopAbs_State state = TopAbs_UNKNOWN;
state = myShapeClassifier.StateShapeShape(S1,exLS1,S2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GettraceKPB()) {
const gp_Pnt& P1 = myShapeClassifier.P3D();
cout<<"point P1 "<<P1.X()<<" "<<P1.Y()<<" "<<P1.Z();
{
TopAbs_State state = myShapeClassifier.StateShapeShape(S1,exS1,S2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GettraceKPB()) {
const gp_Pnt& P1 = myShapeClassifier.P3D();
cout<<"point P1 "<<P1.X()<<" "<<P1.Y()<<" "<<P1.Z();
Standard_Boolean TopOpeBRepBuild_Builder::KPiskoletgesh(const TopoDS_Shape& Sarg,TopTools_ListOfShape& lShsd,TopTools_ListOfShape& lfhsd) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TKPB = TopOpeBRepBuild_GettraceKPB();
#endif
const TopOpeBRepDS_DataStructure& BDS = myDataStructure->DS();
Standard_Boolean iskolesh = FUNKP_KPiskolesh((*this),BDS,Sarg,lShsd,lfhsd);
if (!iskolesh) return Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer nfhsd =
#endif
KPlhsd(Sarg,TopAbs_FACE,lfhsd);
}
// if (ne > 1) return Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer isol = myDataStructure->Shape(Sarg); Standard_Integer ifac = myDataStructure->Shape(fac);
if(TKPB){cout<<"isol "<<isol<<endl;}
if(TKPB){cout<<"nfhsd "<<nfhsd<<endl;}
TopTools_ListIteratorOfListOfShape it1(L1);
for (i=1 ; i<=nl1; i++) {
const TopoDS_Shape& S1 = it1.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iS1 = myDataStructure->Shape(S1);
#endif
TopTools_ListIteratorOfListOfShape itsd(myDataStructure->SameDomain(S1));
for (; itsd.More(); itsd.Next() ) {
const TopoDS_Shape& S2 = itsd.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iS2 = myDataStructure->Shape(S2);
#endif
Standard_Boolean found = KPContains(S2,L2);
TopTools_ListIteratorOfListOfShape it2(L2);
for (i=1 ; i<=nl2; i++) {
const TopoDS_Shape& S2 = it2.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iS2 = myDataStructure->Shape(S2);
#endif
TopTools_ListIteratorOfListOfShape itsd(myDataStructure->SameDomain(S2));
for (; itsd.More(); itsd.Next() ) {
const TopoDS_Shape& S1 = itsd.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iS1 = myDataStructure->Shape(S1);
#endif
Standard_Boolean found = KPContains(S1,L1);
ires = RESSHAPE2;
} // SameOriented
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TKPB = TopOpeBRepBuild_GettraceKPB();
if (TKPB) cout<<"ires = "<<ires<<endl;
#endif
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TKPB = TopOpeBRepBuild_GettraceKPB();
if (TKPB) cout<<"ires = "<<ires<<" icla1 "<<icla1<<" icla2 "<<icla2<<endl;
#endif
St1 = KPclassF(F1,F2);
St2 = KPclassF(F2,F1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GettraceKPB()) {
cout<<"Stf1 ";TopAbs::Print(St1,cout); cout<<" ";
cout<<"Stf2 ";TopAbs::Print(St2,cout); cout<<endl;
Standard_Boolean TopOpeBRepBuild_Builder::KPiskoleFF(const TopoDS_Shape& F1,const TopoDS_Shape& F2,TopAbs_State& St1,TopAbs_State& St2)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF1;
Standard_Boolean tSPS1 = GtraceSPS(F1,iF1);
Standard_Integer iF2;
Standard_Integer TopOpeBRepBuild_Builder::KPreturn(const Standard_Integer b)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GettraceKPB()) {
cout<<"--- IsKPart "<<b;
if ( b == 1 ) cout<<" iskole";
#include <BRepCheck.hxx>
#include <BRepCheck_Result.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GettraceSPS();
#endif
//------------
{
Standard_Boolean lesmemes = S1.IsEqual(S2);
if (lesmemes) {
-#ifdef TOPOPEBREPBUILD_DEB
+#ifdef OCCT_DEBUG
cout<<"TopOpeBRepBuild : S1 == S2"<<endl;
#endif
return;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
GdumpSHASETreset();
#endif
// -----------------------------------------
TopOpeBRepBuild_ShellFaceSet SFS;
-#ifdef DEB
+#ifdef OCCT_DEBUG
SFS.DEBNumber(GdumpSHASETindex());
#endif
void TopOpeBRepBuild_Builder::MakeFaces(const TopoDS_Shape& aFace,TopOpeBRepBuild_FaceBuilder& FABU,TopTools_ListOfShape& L)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF = 0; Standard_Boolean tSPS = GtraceSPS(aFace,iF);
if(tSPS){GdumpFABU(FABU);}
#endif
void TopOpeBRepBuild_Builder::MakeEdges(const TopoDS_Shape& anEdge,TopOpeBRepBuild_EdgeBuilder& EDBU,TopTools_ListOfShape& L)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iE; Standard_Boolean tSPS = GtraceSPS(anEdge,iE);
Standard_Integer ne = 0;
#endif
}
} // loop on vertices of new edge newEdge
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){cout<<endl;}
if(tSPS){cout<<"V of new edge "<<++ne<<endl;}
if(tSPS){GdumpEDG(newEdge);}
void TopOpeBRepBuild_Pave::Dump() const
{
-#ifdef TOPOPEBREPBUILD_DEB
+#ifdef OCCT_DEBUG
cout<<Parameter()<<" ";TopAbs::Print(Vertex().Orientation(),cout);
#endif
}
#include <Precision.hxx>
#include <TopExp.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepTool_GettraceVC();
extern Standard_Boolean TopOpeBRepTool_GettraceCLOV();
#endif
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceVC()) {
cout<<endl;
if (myEdgePeriodic) {
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceVC()) {
cout<<"VC_NP : ";
if (myP1 == myP2) cout<<" p1 = p2";
{
if ( ! ToAdjustOnPeriodic() ) return;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Real p1 = myP1, p2 = myP2;
#endif
if (myO2 == TopAbs_FORWARD) myP1 = AdjustCase(myP1,myO1,myP2,myPeriod,tol,myCas1);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceVC()) {
cout<<"p1 "<<p1<<" ";TopAbs::Print(myO1,cout);cout<<" --> "<<myP1<<endl;
cout<<"p2 "<<p2<<" ";TopAbs::Print(myO2,cout);cout<<" --> "<<myP2<<endl;
myCas1 = myCas2 = 7;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceVC()) {
cout<<"VC_P : cas "<<myCas1<<"__"<<myCas2;
cout<<" --> state "; TopAbs::Print(state,cout); cout<<endl;
myP1 = PV1->Parameter();
myP2 = PV2->Parameter();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceVC()) {
cout<<endl<<"VC : "<<myP1<<" "<<myP2<<" ";
TopAbs::Print(myO1,cout); cout<<" "; TopAbs::Print(myO2,cout);
else
state = CompareOnNonPeriodic();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceVC()) {
cout<<"VC : --> final state "; TopAbs::Print(state,cout); cout<<endl;
}
myFirst = P;
mySameParameters = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceVC())
cout<<endl<<"VC : set first parameter "<<myFirst<<endl;
#endif
(const Standard_Boolean Closed)
{
myClosedVertices = Closed;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceCLOV()) {
myEdgePeriodic = Closed;
cout<<"::::::::::::::::::::::::"<<endl;
#include <TopExp.hxx>
#include <gp_Pnt.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepTool_GettraceVC();
#include <TopOpeBRepBuild_Builder.hxx>
#include <gp_Pnt.hxx>
return;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = Standard_False;
trc = trc || TopOpeBRepTool_GettraceVC();
Standard_Integer iv=0;//,nv=myVertices.Extent();
SortPave(List,myVertices);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( TopOpeBRepTool_GettraceVC() ) {
myVerticesIt.Initialize(myVertices);
if ( MoreLoop() ) cout<<"--- PaveSet : Prepare"<<endl;
p2 = it2.Value()->Parameter();
Standard_Real d = Abs(p1-p2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceVC()) {
cout<<"VertexSet : p1,p2 d "<<p1<<","<<p2<<" "<<d<<endl;
}
for (it1.Initialize(myVertices);
(! myHasEqualParameters ) && it1.More();
it1.Next()) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
// const TopoDS_Shape& v1 = it1.Value()->Vertex();
#endif
p1 = it1.Value()->Parameter();
if (d < Precision::PConfusion()) {
myHasEqualParameters = Standard_True;
myEqualParameters = f;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceVC()) {
cout<<"=*=*=*=*=*=*=*=*=*=*=*=*=*=*"<<endl;
cout<<"PaveSet : p1,f d "<<p1<<","<<f<<" "<<d<<endl;
#include <Standard_ProgramError.hxx>
#include <TopOpeBRepDS_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GetcontextNOREGUSO();
extern Standard_Boolean TopOpeBRepBuild_GetcontextREGUXPU();
extern Standard_Boolean TopOpeBRepBuild_GettraceSAVSREGU();
const TopoDS_Shape& newSolid = itl.Value();
TopTools_ListOfShape newSolidLOSO;
RegularizeSolid(SO,newSolid,newSolidLOSO);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nnewSolidLOSO = newSolidLOSO.Extent(); // DEB
#endif
LOSO.Append(newSolidLOSO);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nLOSO = LOSO.Extent(); // DEB
#endif
Standard_Integer nr = myMemoSplit.Extent();
TopTools_ListOfShape newlspf;
TopTools_ListOfShape& lspf = ChangeSplit(f,staf);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nlspf = lspf.Extent(); // DEB
#endif
for (TopTools_ListIteratorOfListOfShape itl1(lspf);itl1.More();itl1.Next()) {
Standard_Boolean toregu = Standard_True;
Standard_Boolean usestos = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iS;Standard_Boolean tSPS=GtraceSPS(SS,iS);
// Standard_Boolean savsregu = TopOpeBRepBuild_GettraceSAVSREGU();
if (TopOpeBRepBuild_GetcontextNOREGUSO()) toregu = Standard_False;
return;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPS) {
cout<<"RegularizeSolid "<<iS<<endl;
debreguso(iS);
TopTools_ListIteratorOfListOfShape itlssdSS(lssdSS);
for (; itlssdSS.More(); itlssdSS.Next()) {
const TopoDS_Shape& ssdSS = itlssdSS.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer issdSS = myDataStructure->Shape(ssdSS); // DEB
#endif
Standard_Integer rankssdSS = GShapeRank(ssdSS);
TopAbs_State stassdSS = (rankssdSS == 1) ? myState1 : myState2;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean issplitssdSS = IsSplit(ssdSS,stassdSS);
// const TopTools_ListOfShape& lspssdSS = Splits(ssdSS,stassdSS);
// Standard_Integer nlspssdSS = lspssdSS.Extent();
//ssdSSf : 1 face de ssdSS = 1 solid SameDomain de Ss
const TopoDS_Shape& ssdSSf = x.Current();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer issdSSf = 0;Standard_Boolean tSPSssdSSf=GtraceSPS(ssdSSf,issdSSf);
if (tSPSssdSSf) debreguso(issdSSf);
#endif
TopAbs_State stassdSSf = stassdSS;
TopTools_ListOfShape& lspssdSSf = ChangeSplit(ssdSSf,stassdSSf);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean issplitssdSSf = IsSplit(ssdSSf,stassdSSf);
// Standard_Integer nlspssdSSf = lspssdSSf.Extent();
#endif
#define MGhc3 Handle(Geom_Curve)
#define MGhc2 Handle(Geom2d_Curve)
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GettraceSPS();
extern Standard_Boolean TopOpeBRepDS_GettraceDSNC();
Standard_EXPORT void debsplitse(const Standard_Integer) {}
const TopOpeBRepDS_DataStructure& BDS = myDataStructure->DS();
Standard_Integer i,n = BDS.NbSectionEdges();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceDSNC() && !mySplitSectionEdgesDone)
cout<<"TopOpeBRepBuild_Builder::SSE : compute "<<n<<" section edges"<<endl;
#endif
Standard_Integer iE = myDataStructure->Shape(E);
Standard_Integer rE = BDS.AncestorRank(E);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tSPS = GtraceSPS(E,iE); if (tSPS) debsplitsemess(iE); Standard_Integer DEBiESD = 1;
#endif
Standard_Integer iESD = myDataStructure->Shape(ESD);
const TopTools_ListOfShape& LESDspon = Splits(ESD,TopAbs_ON);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPS) {
TCollection_AsciiString str("# edge ");str=str+iE+" sd3d edge "+iESD;
TCollection_AsciiString stru(str.Length(),'-');
TopOpeBRepBuild_ListOfShapeListOfShape thelist;
if (!E1b) MEIN.Bind(E1, thelist);
TopOpeBRepBuild_ListOfShapeListOfShape& LE1loslos = MEIN.ChangeFind(E1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nLE1 = LE1loslos.Extent();
#endif
TopOpeBRepBuild_ListOfShapeListOfShape thelist2;
if (!E2b) MEIN.Bind(E2,thelist2);
TopOpeBRepBuild_ListOfShapeListOfShape& LE2loslos = MEIN.ChangeFind(E2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nLE2 = LE2loslos.Extent();
#endif
for (i = 1; i <= n; i++) { // 3
const TopoDS_Edge& E = TopoDS::Edge(BDS.SectionEdge(i));
if(E.IsNull()) continue;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iE = myDataStructure->Shape(E);
// Standard_Integer rE = GShapeRank(E);
Standard_Boolean tSPS = GtraceSPS(E,iE);
if (isbMEOUT) {
const TopTools_ListOfShape& LEOUT = MEOUT.Find(E);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nOUT = LEOUT.Extent();
#endif
GCopyList(LEOUT,LEspon);
if (isbMEIN) {
const TopOpeBRepBuild_ListOfShapeListOfShape& loslos = MEIN.Find(E);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nloslos = loslos.Extent();
#endif
for (TopOpeBRepBuild_ListIteratorOfListOfShapeListOfShape it(loslos); it.More(); it.Next()) {
const TopTools_ListOfShape& los = it.Value().List();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nlos = los.Extent();
#endif
GCopyList(los,LEspon);
BRep_Builder BB;
for (i = 1; i <= n; i++) { // 4
const TopoDS_Edge& E = TopoDS::Edge(BDS.SectionEdge(i)); if(E.IsNull()) continue;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer idebE; Standard_Boolean tSPS = GtraceSPS(E,idebE); if (tSPS) debsplitsemess(idebE);
#endif
const TopTools_ListOfShape& lesd = BDS.ShapeSameDomain(E);
if (lesd.IsEmpty()) continue;
Standard_Integer iE = BDS.Shape(E);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer rE = BDS.AncestorRank(E);
#endif
Standard_Integer RE = BDS.SameDomainRef(E);
TopTools_ListOfShape lF; TopTools_ListIteratorOfListOfShape itlesd;
for(itlesd.Initialize(lesd);itlesd.More();itlesd.Next()) {
const TopoDS_Edge& esd = TopoDS::Edge(itlesd.Value());
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iesd = BDS.Shape(esd);
#endif
const TopTools_ListOfShape& lf = FDSCNX_EdgeConnexitySameShape(esd,myDataStructure);
GCopyList(lf,lF);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nlF = lF.Extent();
#endif
TopoDS_Edge& eon = TopoDS::Edge(itlon.Value());
Standard_Real f,l; Standard_Boolean hasPC = FC2D_HasCurveOnSurface(eon,F);
if (hasPC) continue;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceC2D()) {
cout<<"\n#TopOpeBRepBuild_Builder::SSE : hasPC = 0 ES"<<i<<" E"<<idebE<<" sur F"<<iF<<endl;
cout<<"tsee s "<<iF<<" "<<idebE<<";"<<endl;
Standard_Boolean isface = (FOR.ShapeType() == TopAbs_FACE);
if (!isface) continue;
const TopoDS_Face& FF = TopoDS::Face(FOR);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iFF = BDS.Shape(FF);
#endif
const TopOpeBRepDS_ListOfInterference& LI = BDS.ShapeInterferences(FF); Standard_Integer nLI = LI.Extent();
TopAbs_ShapeEnum shab = TFE.ShapeBefore(),shaa = TFE.ShapeAfter();
if (shaa != TopAbs_FACE || shab != TopAbs_FACE) continue;
const TopoDS_Face& FS = TopoDS::Face( myDataStructure->Shape(SI));
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iFS = myDataStructure->Shape(FS);
#endif
Standard_Boolean FSisper = FUN_periodicS(FS);
if (!FSisper) continue;
const TopoDS_Edge& EG = TopoDS::Edge(myDataStructure->Shape(GI));
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iEG = myDataStructure->Shape(EG);
#endif
Standard_Boolean isrest = myDataStructure->DS().IsSectionEdge(EG); if (!isrest) continue;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Real tolE = BRep_Tool::Tolerance(EG);
#endif
Standard_Boolean haspc = FC2D_HasCurveOnSurface(EG,FS); if (haspc) continue;
Standard_Boolean isface = (FOR.ShapeType() == TopAbs_FACE);
if (!isface) continue;
const TopoDS_Face& FF = TopoDS::Face(FOR);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iFF = BDS.Shape(FF);
#endif
Standard_Boolean FFuper,FFvper; Standard_Boolean FFisper = FUN_periodic(FF,FFuper,FFvper);
if (GB == 1) continue;
const TopoDS_Edge& EG = TopoDS::Edge(myDataStructure->Shape(GI));
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iEG = myDataStructure->Shape(EG);
#endif
Standard_Boolean isrest = myDataStructure->DS().IsSectionEdge(EG); if (!isrest) continue;
//=======================================================================
void TopOpeBRepBuild_Builder::SplitSectionEdge(const TopoDS_Shape& EA)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iE; Standard_Boolean tSPS = GtraceSPS(EA,iE);
if (tSPS) debsplitsemess(iE);
#endif
Standard_Boolean hg = myDataStructure->HasGeometry(EOR);
Standard_Boolean hsd3d = FDS_HasSameDomain3d(BDS,EOR);
Standard_Boolean hsd2d = FDS_HasSameDomain2d(BDS,EOR);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean issplit = IsSplit(EOR,TopAbs_ON);
#endif
if(hsd2d) GLOBAL_hassd=2; //++
if (mySplitSectionEdgesDone) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) {
GdumpSHA(EF, (char *) "SplitSectionEdges done : ");
if (issplit) cout<<" "<<Splits(EOR,TopAbs_ON).Extent()<<" edges splitON"<<endl;
return;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS)GdumpSHASTA(EF,TopAbs_ON,"--- SplitSectionEdges ");
if(tSPS)cout<<" (hg="<<hg<<"||hsd3d="<<hsd3d<<")="<<cond<<endl;
#endif
if (mke) {
MarkSplit(EOR,TopAbs_ON);
TopTools_ListOfShape& LON = ChangeSplit(EOR,TopAbs_ON);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer non = LON.Extent(); // DEB
#endif
TopTools_ListOfShape LESD1,LESD2; GFindSamDom(EOR,LESD1,LESD2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS)GdumpSHASTA(EF,TopAbs_ON,"--- SplitSectionEdges ");
if(tSPS){
cout<<" (hg="<<hg<<"||hsd3d="<<hsd3d<<")="<<cond<<endl;
#endif
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPS) debspseon(iE);
#endif
TopOpeBRepBuild_GTopo G = TopOpeBRepBuild_GTool::GComUnsh(TopAbs_FACE,TopAbs_FACE);
//modified by NIZHNY-MZV Mon Apr 17 16:25:53 2000 else if (rankEF == 2) losOO.Append(GLOBALDS_shape1);
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPS) debspsein(iE);
#endif
TopOpeBRepBuild_GTopo G = TopOpeBRepBuild_GTool::GCutUnsh(TopAbs_FACE,TopAbs_FACE);
}
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPS) debspseou(iE);
#endif
TopOpeBRepBuild_GTopo G = TopOpeBRepBuild_GTool::GCutUnsh(TopAbs_FACE,TopAbs_FACE);
Standard_Boolean issplitON = IsSplit(es,TopAbs_ON);
TopAbs_State staspl=(issplitON)?TopAbs_ON:(issplitIN)?TopAbs_IN:TopAbs_UNKNOWN;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iii; Standard_Boolean tSPS = GtraceSPS(es,iii);
if (tSPS) {
GdumpSHA(es, (char *) "--- Section ");
static TCollection_AsciiString PRODINS("dins ");
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GettraceCHK();
extern Standard_Boolean TopOpeBRepBuild_GettraceCHKOK();
extern Standard_Boolean TopOpeBRepBuild_GettraceCHKNOK();
void TopOpeBRepBuild_ShapeSet::AddShape(const TopoDS_Shape& S)
{
Standard_Boolean chk = CheckShape(S);
-#ifdef DEB
+#ifdef OCCT_DEBUG
DumpCheck(cout," AddShape",S,chk);
#endif
void TopOpeBRepBuild_ShapeSet::AddStartElement(const TopoDS_Shape& S)
{
Standard_Boolean chk = CheckShape(S);
-#ifdef DEB
+#ifdef OCCT_DEBUG
DumpCheck(cout," AddStartElement",S,chk);
#endif
void TopOpeBRepBuild_ShapeSet::AddElement(const TopoDS_Shape& S)
{
Standard_Boolean chk = CheckShape(S);
-#ifdef DEB
+#ifdef OCCT_DEBUG
DumpCheck(cout," AddElement",S,chk);
#endif
{
myCheckShape = checkshape;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GettraceCHK() && !myCheckShape) {
DumpName(cout,"no checkshape set on ");cout<<endl;
}
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
void TopOpeBRepBuild_ShapeSet::DumpCheck(Standard_OStream& OS,
const TCollection_AsciiString& str,
const TopoDS_Shape& S,
{
if (!myCheckShape) return;
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopAbs_ShapeEnum t = S.ShapeType();
if (!chk) {
if (TopOpeBRepBuild_GettraceCHK() ||
#include <Standard_ProgramError.hxx>
#include <BRepAdaptor_Surface.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GettraceCHK();
#endif
TopAbs_State TopOpeBRepBuild_ShellFaceClassifier::CompareShapes
(const TopoDS_Shape& B1, const TopoDS_Shape& B2)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// const TopAbs_ShapeEnum t1 = B1.ShapeType();
// const TopAbs_ShapeEnum t2 = B2.ShapeType();
#endif
TopAbs_State TopOpeBRepBuild_ShellFaceClassifier::CompareElementToShape
(const TopoDS_Shape& F, const TopoDS_Shape& SHE)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// const TopAbs_ShapeEnum t1 = F.ShapeType();
// const TopAbs_ShapeEnum t2 = SHE.ShapeType();
#endif
void TopOpeBRepBuild_ShellFaceClassifier::ResetShape(const TopoDS_Shape& SHE)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// const TopAbs_ShapeEnum t1 = SHE.ShapeType();
#endif
Standard_Boolean TopOpeBRepBuild_ShellFaceClassifier::CompareElement(const TopoDS_Shape& F)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// const TopAbs_ShapeEnum t = F.ShapeType();
#endif
Standard_Boolean bRet = Standard_True;
return bRet;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <BRepTools.hxx>
#include <BRep_Builder.hxx>
#include <TCollection_AsciiString.hxx>
TopAbs_State state;
Standard_Real tol3d = Precision::Confusion();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GettraceCHK()) {
STATIC_ishell++;
TCollection_AsciiString home("/home/wb/mdl/gti/prod/TTOPOPE/src/test/data/");
#include <TopOpeBRepBuild_define.hxx>
#include <TopoDS.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GettraceCHK();
#endif
TopOpeBRepBuild_ShellFaceSet::TopOpeBRepBuild_ShellFaceSet() :
TopOpeBRepBuild_ShapeSet(TopAbs_EDGE)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
myDEBName = "SFS";
#endif
}
//=======================================================================
TopOpeBRepBuild_ShellFaceSet::TopOpeBRepBuild_ShellFaceSet
-#ifdef DEB
+#ifdef OCCT_DEBUG
(const TopoDS_Shape& S,const Standard_Address A) : // DEB
#else
(const TopoDS_Shape& S,const Standard_Address) : // DEB
{
mySolid = TopoDS::Solid(S);
-#ifdef DEB
+#ifdef OCCT_DEBUG
myDEBName = "SFS";
if (A != NULL) {
TopOpeBRepBuild_Builder* pB = ((TopOpeBRepBuild_Builder*)((void*)A));
void TopOpeBRepBuild_ShellFaceSet::DumpSS()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopOpeBRepBuild_ShapeSet::DumpSS();
#endif
}
const TopoDS_Shape& TopOpeBRepBuild_SolidBuilder::Face() const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// const Standard_Integer i = myBlockIterator.Value(); // DEB
#endif
const TopoDS_Shape& F = myBlockBuilder.Element(myBlockIterator);
const TopAbs_State ToBuild1,
const TopAbs_State ToBuild2)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( TopOpeBRepBuild_GetcontextSF2() ) {
SplitEdge2(E,ToBuild1,ToBuild2);
return;
Standard_Boolean tosplit = ToSplit(Eoriented,ToBuild1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iEdge; Standard_Boolean tSPS = GtraceSPS(Eoriented,iEdge);
if(tSPS){
cout<<endl;
LE1.Append(Eforward);
FindSameDomain(LE1,LE2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){GdumpSAMDOM(LE1, (char *) "1 : ");}
if(tSPS){GdumpSAMDOM(LE2, (char *) "2 : ");}
if(tSPS){cout<<endl;}
PVS.InitLoop();
if ( !PVS.MoreLoop() ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) {
cout<<"NO VERTEX split "; TopAbs::Print(ToBuild1,cout);cout<<endl;
}
TopoDS_Shape Eforward = Eoriented;
myBuildTool.Orientation(Eforward,TopAbs_FORWARD);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iEdge; Standard_Boolean tSPS = GtraceSPS(Eoriented,iEdge);
if(tSPS){cout<<endl;}
if(tSPS){GdumpSHASTA(Eoriented,ToBuild1,"--- SplitEdge2 ");}
PVS.InitLoop();
if ( !PVS.MoreLoop() ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) {cout<<"NO VERTEX split ";TopAbs::Print(ToBuild1,cout);cout<<endl;}
#endif
return;
#include <TopOpeBRepBuild_WireEdgeSet.hxx>
#include <TopOpeBRepBuild_FaceBuilder.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_EXPORT void debspf(const Standard_Integer i) {cout<<"++ debspf"<<i<<endl;}
#endif
const TopAbs_State ToBuild1,
const TopAbs_State ToBuild2)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TopOpeBRepBuild_GetcontextSF2()){
SplitFace2(Foriented,ToBuild1,ToBuild2);
return;
// ----------------------------------------------
TopOpeBRepBuild_WireEdgeSet WES(Fforward,this);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tSPF=TopOpeBRepBuild_GettraceSPF();
Standard_Integer iFace=myDataStructure->Shape(Foriented);
if(tSPF){cout<<endl;GdumpSHASTA(Foriented,ToBuild1,"=== SplitFace ");}
// -----------------------------------------
AddIntersectionEdges(Fforward,ToBuild1,RevOri1,WES);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF; Standard_Boolean tSPS = GtraceSPS(Fforward,iF);
if(tSPS) WES.DumpSS();
#endif
Standard_Integer n1 = LF1.Extent();
Standard_Integer n2 = LF2.Extent();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tSPF = TopOpeBRepBuild_GettraceSPF();
// Standard_Integer iFace = myDataStructure->Shape(Foriented);
if (tSPF) {
FindSameRank(LFSO,rankX,LFSO2);
FindSameRank(LFOO,rankX,LFOO2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( tSPF ) {
GdumpSAMDOM(LFSO1, (char *) "LFSO1 : ");
GdumpSAMDOM(LFOO1, (char *) "LFOO1 : ");
// ---------------------------------------------
TopOpeBRepBuild_WireEdgeSet WES(Fforward,this);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tSPF = TopOpeBRepBuild_GettraceSPF();
Standard_Integer iFace = myDataStructure->Shape(Foriented);
if(tSPF){cout<<endl;GdumpSHASTA(Foriented,ToBuild1,"=== SplitFaceOK ");}
TopAbs_ShapeEnum t = aShape.ShapeType();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GettraceSHEX()) GdumpEXP(Ex);
#endif
for (; It.More(); It.Next()) {
newShape = It.Value();
myBuildTool.Orientation(newShape,newori);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// TopAbs_ShapeEnum tns = TopType(newShape);
#endif
//----------------------- IFV
#include <TopOpeBRepBuild_SolidBuilder.hxx>
#include <TopOpeBRepBuild_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#define DEBSHASET(sarg,meth,shaset,str) TCollection_AsciiString sarg((meth));(sarg)=(sarg)+(shaset).DEBNumber()+(str);
Standard_EXPORT Standard_Boolean TopOpeBRepDS_GettraceSTRANGE();
Standard_EXPORT void debsplitf(const Standard_Integer i);
// -----------------------------------------
TopOpeBRepBuild_ShellFaceSet SFS;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tSPS = TopOpeBRepBuild_GettraceSPS();
// Standard_Integer iSolid = myDataStructure->Shape(S1oriented);
if (tSPS) {
TopAbs_Orientation ori = SSurfaces.Orientation(ToBuild1);
myBuildTool.Orientation(aFace,ori);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPS){
DEBSHASET(ss,"--- SplitSolid ",SFS," AddElement SFS+ face ");
GdumpSHA(aFace,(Standard_Address)ss.ToCString());
if (!anAvoidSubshMap.Contains (aSubshMap(i)) )
aSubsh = aSubshMap(i);
if (aSubsh.IsNull()) {
-#ifdef TOPOPEBREPBUILD_DEB
+#ifdef OCCT_DEBUG
cout<<"FindStateThroughVertex: warning: all vertices are avoided"<<endl;
#endif
return TopAbs_UNKNOWN; // failure
aCopyCurve -> Transform(aTrsf);
GeomAPI_ProjectPointOnCurve aPP(aP, aCopyCurve, aCopyCurve->FirstParameter(), aCopyCurve->LastParameter());
-#ifdef DEB
+#ifdef OCCT_DEBUG
// gp_Pnt aNP = aPP.NearestPoint();
#endif
parOri = aPP.LowerDistanceParameter();
#include <TopOpeBRepBuild_Builder.hxx>
#include <TopOpeBRepBuild_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#define TSTRA TopOpeBRepDS_GettraceSTRANGE()
static TCollection_AsciiString PRODINS("dins ");
extern Standard_Boolean TopOpeBRepDS_GettraceSTRANGE();
} //UNKNOWN
if (state == TopAbs_UNKNOWN) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TSTRA) cout<<"TopOpeBRepBuild_Builder::WES::Compare UNKNOWN -> ShapeClassifier "<<endl;
#endif
}
// et que si ils ne se touchent pas, on ne passe pas par le WEC.
// INCOMPLET!!!
-#ifdef DEB
+#ifdef OCCT_DEBUG
// TopAbs_ShapeEnum t1 = B1.ShapeType();
// TopAbs_ShapeEnum t2 = B2.ShapeType();
#endif
Standard_Real t = 0.397891143689; Standard_Real par = ((1-t)*f2 + t*l2);
myPoint2d = C2D->Value(par);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Real f3,l3; Handle(Geom_Curve) C3D = BRep_Tool::Curve(E,f3,l3);
gp_Pnt P3D; if (!C3D.IsNull()) P3D = C3D->Value(par);
#endif
Standard_Real t = 0.33334567; Standard_Real par = ((1-t)*f2 + t*l2);
gp_Pnt2d p2d = C2D->Value(par);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Real f3,l3; Handle(Geom_Curve) C3D = BRep_Tool::Curve(E,f3,l3);
gp_Pnt P3D; if (!C3D.IsNull()) P3D = C3D->Value(par);
#endif
myBCEdge.Edge() = E;
TopAbs_Orientation Eori = E.Orientation();
myFPC.Compare(myBCEdge,Eori);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// TopAbs_State state = myFPC.State();
#endif
return bRet;
#include <TopOpeBRepBuild_define.hxx>
#include <TopOpeBRepTool_2d.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRep_GettraceSHA(const Standard_Integer i);
extern Standard_Boolean TopOpeBRepBuild_GettraceSS();
extern Standard_Boolean TopOpeBRepBuild_GetcontextSSCONNEX();
//=======================================================================
void TopOpeBRepBuild_WireEdgeSet::AddStartElement(const TopoDS_Shape& S)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
#endif
Standard_Boolean tocheck = Standard_True;
//=======================================================================
Standard_Boolean TopOpeBRepBuild_WireEdgeSet::IsClosed(const TopoDS_Shape& E) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer ista=myOMSS.FindIndex(E);Standard_Boolean tsh=(ista)?TopOpeBRep_GettraceSHA(ista):Standard_False;
if (tsh) debwesclo(ista);
#endif
#include <BRep_Tool.hxx>
#include <Standard_ProgramError.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_EXPORT void debfctwes(const Standard_Integer /*i*/) {}
Standard_EXPORT void debfctwesmess(const Standard_Integer i,const TCollection_AsciiString& s = "")
{cout<<"+ + + debfctwes "<<s<<"F"<<i<<endl;debfctwes(i);}
TopAbs_State TB1,TB2; G1.StatesON(TB1,TB2);
TopAbs_ShapeEnum t1,t2,ShapeInterf; G1.Type(t1,t2); ShapeInterf = t1;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF; Standard_Boolean tSPS = GtraceSPS(F1,iF);
if(tSPS) GdumpSHASTA(iF,TB1,WES,"--- GFillCurveTopologyWES");
if(tSPS) {cout<<" ShapeInterf ";TopAbs::Print(ShapeInterf,cout);cout<<endl;}
TopoDS_Face& WESF = *((TopoDS_Face*)((void*)&WES.Face()));
TopoDS_Face& FTF = *((TopoDS_Face*)((void*)&myFaceToFill));
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean FTFeqWESF = myFaceReference.IsEqual(WESF);
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iWESF = myDataStructure->Shape(WESF);
Standard_Integer iref = myDataStructure->Shape(myFaceReference);
Standard_Integer ifil = myDataStructure->Shape(myFaceToFill);
neworiE = TopAbs::Complement(neworiE);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tSPS = GtraceSPS(iWESF);
if(tSPS){
cout<<"ifil : "<<ifil<<" iref : "<<iref<<" iwes : "<<iWESF<<endl;
Standard_Real f2,l2,tolpc; Handle(Geom2d_Curve) C2D;
C2D = FC2D_CurveOnSurface(E,WESF,f2,l2,tolpc);
if (C2D.IsNull()) Standard_ProgramError::Raise("GFillCurveTopologyWES");
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Real tol = Max(tolE,tolpc);
#endif
myBuildTool.PCurve(WESF,E,C2D);
-#ifdef TOPOPEBREPBUILD_DEB
+#ifdef OCCT_DEBUG
EhasPConWESF = FC2D_HasCurveOnSurface(E,WESF);
if (!EhasPConWESF) cout<<"TopOpeBRepBuild_Builder::GFillCurveTopologyWES : Null PCurve on F"<<iWESF<<endl;
#endif
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPS) debaddpwes(iWESF,TB,iG,neworiE,(TopOpeBRepBuild_Builder* const)this,&WES,"GFillCurveTopology " ,"WES+ EofC ");
#endif
#include <BRep_Tool.hxx>
#include <TopoDS.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#define DEBSHASET(sarg,meth,shaset,str) TCollection_AsciiString sarg((meth));(sarg)=(sarg)+(shaset).DEBNumber()+(str);
Standard_EXPORT Standard_Boolean TopOpeBRepBuild_GetcontextNOFUFA();
Standard_EXPORT void debffsfs(const Standard_Integer i){cout<<"+++ debffsfs "<<i<<endl;}
static Standard_Integer FUN_getAncestorFsp(TopOpeBRepBuild_Builder& B,TopOpeBRepTool_ShapeClassifier& SC,const TopTools_ListOfShape& LF,const TopoDS_Shape& fsp,Standard_Boolean& p3ddef,gp_Pnt& p3d);
static Standard_Integer FUN_getAncestorFsp(TopOpeBRepBuild_Builder& B,TopOpeBRepTool_ShapeClassifier& SC,const TopTools_ListOfShape& LF1,const TopTools_ListOfShape& LF2,const TopoDS_Shape& fsp);
-#ifdef DEB
+#ifdef OCCT_DEBUG
//static void FUN_getAncestorFsp(const Handle(TopOpeBRepDS_HDataStructure)& HDS,TopOpeBRepTool_ShapeClassifier& SC,const TopTools_ListOfShape& LF1,const TopTools_ListOfShape& LF2,const TopTools_ListOfShape& spFOR,
// TopTools_DataMapOfShapeInteger* SplitAnc);
#endif
{
TopAbs_State TB1,TB2; Gin.StatesON(TB1,TB2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF; Standard_Boolean tSPS = GtraceSPS(FOR,iF);
if(tSPS)cout<<endl;
#endif
const TopOpeBRepDS_DataStructure& BDS = myDataStructure->DS();
Standard_Boolean tosplit = GToSplit(FOR,TB1);
Standard_Boolean tomerge = GToMerge(FOR);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iFOR = BDS.Shape(FOR);
#endif
Standard_Integer rkFOR = BDS.AncestorRank(FOR);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){
GdumpSHASTA(FOR,TB1,"--- GFillFaceSFS START ");
cout<<" tosplit "<<tosplit<<" tomerge "<<tomerge<<endl;
if (makemerge) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) {
GdumpSHASTA(FOR,TB1,"[[[[[[[[[[[[[[[[[[[[[[[[[[ GFillFaceSFS makemerge START ");
cout<<endl;
#endif
Standard_Boolean performfufa = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
performfufa = !TopOpeBRepBuild_GetcontextNOFUFA();
#endif
if (performfufa) {
GM = Gin;
GM.ChangeConfig(TopOpeBRepDS_SAMEORIENTED,TopOpeBRepDS_SAMEORIENTED);
if (dodo) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){
GdumpSAMDOM(LF1, (char *) "LF1 (LFSO1) : ");
GdumpSAMDOM(LF2, (char *) "LF2 (LFSO2) : ");
GM.ChangeConfig(TopOpeBRepDS_SAMEORIENTED,TopOpeBRepDS_DIFFORIENTED);
FUN_setmotherope(GM); // +12/07
if (dodo) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){
TopAbs_State TB11,TB21; GM.StatesON(TB11,TB21);
cout<<endl;
GM.ChangeConfig(TopOpeBRepDS_SAMEORIENTED,TopOpeBRepDS_DIFFORIENTED);
FUN_setmotherope(GM); // +12/07
if (dodo) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){
TopAbs_State TB12,TB22; GM.StatesON(TB12,TB22);
cout<<endl;
FUN_unsetmotherope(); // +12/07
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) {
GdumpSHASTA(FOR,TB1,"]]]]]]]]]]]]]]]]]]]]]]]]]] GFillFaceSFS makemerge END ");
cout<<endl;
// FuseFace
SFS.ChangeStartShapes().Extent();
if (performfufa) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) debffflo(iF);
#endif
// const TopTools_ListOfShape& lou = Splits(FF,TopAbs_OUT); Standard_Integer nou = lou.Extent();
// const TopTools_ListOfShape& lin = Splits(FF,TopAbs_IN); Standard_Integer nin = lin.Extent();
// GCopyList(lou,*GLOBAL_lfr1);
// GCopyList(lin,*GLOBAL_lfr1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nlfr1 = GLOBAL_lfr1->Extent();
#endif
fufa.PerformFace();
Standard_Boolean isdone = fufa.IsDone();
if (!isdone) return;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean ismodified = fufa.IsModified();
#endif
const TopTools_ListOfShape& lfr2 = fufa.LFuseFace();
for (TopTools_ListIteratorOfListOfShape itlfr2(lfr2);itlfr2.More();itlfr2.Next()) {
const TopoDS_Shape& flfr2 = itlfr2.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){
DEBSHASET(ss,"--- FillFaceSFS apres fufa",SFS," AddStartElement SFS+ face ");
GdumpSHA(flfr2,(Standard_Address)ss.ToCString());
myEdgeAvoid.Clear();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){
GdumpSHASTA(FOR,TB1,"--- GFillFaceSFS END ");cout<<endl;
}
#include <TopOpeBRepTool_EXPORT.hxx>
#include <TopOpeBRepTool_2d.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_EXPORT void debfctwesmess(const Standard_Integer i,const TCollection_AsciiString& s = "");
Standard_EXPORT void debffwesON(const Standard_Integer i);
Standard_EXPORT void debffwesk(const Standard_Integer i) {cout<<"++ debffwesk "<<i<<endl;}
const TopoDS_Shape& F1 = LS1.First();
myFaceReference = TopoDS::Face(F1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF1 =
#endif
BDS.Shape(F1);
Standard_Integer iref = BDS.SameDomainRef(F1);
TopAbs_Orientation oref = BDS.Shape(iref).Orientation();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tSPS = GtraceSPS(F1,iF1);
if(tSPS) cout<<"\n%%%%%%%%%%%%% K = "<<Kfill<<" %%%%%%%%%%%%% ";
if(tSPS) GdumpSHASTA(iF1,TB1,WES,"GFillFacesWESK","myFaceReference");
TB = TB1;
it.Initialize(LS1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){
cout<<"\n^^^^^^^^ GFillFacesWESK : traitement de 1/2";
TopAbs_State TB11,TB21; G.StatesON(TB11,TB21);
GFillFaceWES(S,LS2,G,WES);
}
else if (Kfill == 2) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPS) debfctwesmess(iF1);
#endif
GFillCurveTopologyWES(S,G,WES);
}
else if (Kfill == 3) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPS) debffwesON(iF1);
#endif
GFillONPartsWES(S,G,LS2,WES);
TB = TB2;
it.Initialize(LS2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS){
cout<<"\n^^^^^^^^ GFillFacesWESK : traitement de 2/1";
TopAbs_State TB12,TB22; G.StatesON(TB12,TB22);
GFillCurveTopologyWES(S,G,WES);
}
else if (Kfill == 3) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) debffwesON(iF1);
#endif
GFillONPartsWES(S,G,LS1,WES);
#include <TopOpeBRepBuild_Builder.ixx>
#include <TopOpeBRepDS_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Integer GLOBAL_iexE;
extern Standard_Integer GLOBAL_iexF;
Standard_Boolean STATIC_trace_iexE = Standard_False;
pos = ShapePosition(S,LSclass);
if ( pos != TB ) keep = Standard_False;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iS; Standard_Boolean tSPS = GtraceSPS(S,iS);
Standard_Integer iface = 0, isoli = 0;
Standard_Boolean tSPSface = Standard_False;
// S is used for trace only
//=======================================================================
void TopOpeBRepBuild_Builder::GKeepShapes
-#ifdef DEB
+#ifdef OCCT_DEBUG
(const TopoDS_Shape& S,
#else
(const TopoDS_Shape&,
#endif
const TopTools_ListOfShape& LSclass,const TopAbs_State TB,const TopTools_ListOfShape& Lin,TopTools_ListOfShape& Lou)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iS; Standard_Boolean tSPS = GtraceSPS(S,iS);
if (tSPS) debkeep(iS);
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer n = 0;
#endif
TopTools_ListIteratorOfListOfShape it(Lin);
if ( pos != TB ) keep = Standard_False;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopAbs_ShapeEnum t = SL.ShapeType();
if(tSPS){cout<<"GKeepShapes : ";}
if(tSPS){cout<<"new ";TopAbs::Print(t,cout);cout<<" "<<++n;}
#include <TopOpeBRepBuild_kpresu.hxx>
#include <Standard_ProgramError.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GettraceKPB();
void debiskole() {}
#endif
void TopOpeBRepBuild_Builder::MergeKPartiskole()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TKPB = TopOpeBRepBuild_GettraceKPB();
if (TKPB) KPreturn(myIsKPart);
debiskole();
itm1.Initialize(myKPMAPf1f2);
if ( ! itm1.More() ) return;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TKPB) {
cout<<""<<endl;
for (; itm1.More();itm1.Next()) {
if ( pfOU==NULL) return;
if ( pfIN==NULL) return;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer ifOU; Standard_Boolean tSPS = GtraceSPS(*pfOU,ifOU);
if(tSPS || TKPB) {
// Standard_Integer iOU = myDataStructure->Shape(*pfOU);
ChangeMerged(she1,myState1);
ChangeMerged(she2,myState2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TKPB) { cout<<"stsol1 ";TopAbs::Print(stsol1,cout); cout<<" "; }
if (TKPB) { cout<<"stsol2 ";TopAbs::Print(stsol2,cout); cout<<endl; }
debiskole();
it2.Initialize(lf2);
const TopoDS_Shape& f2 = it2.Value();
-/*#ifdef DEB
+/*#ifdef OCCT_DEBUG
Standard_Integer ii1 = myDataStructure->Shape(f1);
Standard_Integer ii2 = myDataStructure->Shape(f2);
#endif*/
} // === fin RESNEWSHE
else {
-#ifdef TOPOPEBREPBUILD_DEB
+#ifdef OCCT_DEBUG
cout<<"MergeKPartiskole : ires = "<<ires<<endl;
#endif
}
loshe1.Append(shecur);
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nshe1 = loshe1.Extent();
#endif
TopTools_ListIteratorOfListOfShape itloshe1;
loshe2.Append(shecur);
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nshe2 = loshe2.Extent();
#endif
TopTools_ListIteratorOfListOfShape itloshe2;
itlf1.More();itlf1.Next()) {
const TopoDS_Shape& f1 = itlf1.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean isb1 = myKPMAPf1f2.IsBound(f1); // DEB
#endif
lf1.Clear(); lf1.Append(f1);
lf2.Clear(); KPSameDomain(lf1,lf2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer n1 = lf1.Extent();
// Standard_Integer n2 = lf2.Extent();
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF1; Standard_Boolean tSPS1 = GtraceSPS(f1,iF1);
if(tSPS1) {
GdumpSHA(f1, (char *) "KPiskole ");cout<<endl;
itlf2.More(); itlf2.Next() ) {
const TopoDS_Shape& f2 = itlf2.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean isb2 = myKPMAPf1f2.IsBound(f2); // DEB
#endif
TopAbs_State state1,state2;
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TKPB = TopOpeBRepBuild_GettraceKPB();
if (TKPB) cout<<"ires = "<<ires<<" icla1 "<<icla1<<" icla2 "<<icla2<<endl;
#endif
Standard_Integer rankIN = 0;
TopTools_ListOfShape LFSO,LFDO;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF1; Standard_Boolean tSPS = BU.GtraceSPS(Fac1,iF1);
if(tSPS) { BU.GdumpSHA(Fac1, (char *) "KPmakeFace ");cout<<endl; }
#endif
BU.GFindSameRank(LFSO,rankIN,LFIN);
BU.GFindSameRank(LFDO,rankIN,LFIN);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) {
BU.GdumpSAMDOM(LFSO, (char *) "LESO : ");
BU.GdumpSAMDOM(LFDO, (char *) "LEDO : ");
const TopoDS_Face& F1 = TopoDS::Face(Fac1);
wtof.MakeFaces(F1,Lres);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nlres = Lres.Extent(); // DEB
#endif
Standard_Integer rankIN = 0;
TopTools_ListOfShape LFSO,LFDO;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF1;
Standard_Boolean tSPS = GtraceSPS(Fac1,iF1);
if(tSPS) {
GFindSameRank(LFSO,rankIN,LFIN);
GFindSameRank(LFDO,rankIN,LFIN);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) {
GdumpSAMDOM(LFSO, (char *) "LESO : ");
GdumpSAMDOM(LFDO, (char *) "LEDO : ");
TopTools_ListOfShape& lShsd,
TopTools_ListOfShape& lfhsd) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TKPB = TopOpeBRepBuild_GettraceKPB();
#endif
const TopOpeBRepDS_DataStructure& BDS = myDataStructure->DS();
Standard_Boolean iskolesh = FUNKP_KPiskolesh(*this,BDS,Sarg,lShsd,lfhsd);
if (!iskolesh) return Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer nfhsd =
#endif
KPlhsd(Sarg,TopAbs_FACE,lfhsd);
Standard_Integer nehg = KPlhg(fac,TopAbs_EDGE,lehg);
if ( nehg != 0 ) return Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer isol = myDataStructure->Shape(Sarg);
Standard_Integer ifac = myDataStructure->Shape(fac);
if(TKPB){cout<<"isol "<<isol<<endl;}
#include <TopOpeBRepDS_EXPORT.hxx>
#include <TopOpeBRepBuild_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern void debfillp(const Standard_Integer i);
extern void debedbu(const Standard_Integer i) {cout<<"++ debedbu "<<i<<endl;}
#endif
void TopOpeBRepBuild_Builder::GPVSMakeEdges
(const TopoDS_Shape& EF,TopOpeBRepBuild_PaveSet& PVS,TopTools_ListOfShape& LOE) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iE; Standard_Boolean tSPS = GtraceSPS(EF,iE);
if (tSPS) debfillp(iE);
#endif
PVS.InitLoop();
Standard_Boolean novertex = ( ! PVS.MoreLoop() );
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS&&novertex)cout<<"#--- GPVSMakeEdges : no vertex from edge "<<iE<<endl;
#endif
if (novertex) return;
void TopOpeBRepBuild_Builder::GEDBUMakeEdges
(const TopoDS_Shape& EF,TopOpeBRepBuild_EdgeBuilder& EDBU,TopTools_ListOfShape& LOE) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iE; Standard_Boolean tSPS = GtraceSPS(EF,iE);
if(tSPS){cout<<endl;GdumpSHA(EF, (char *) "#--- GEDBUMakeEdges ");cout<<endl;}
if(tSPS){GdumpEDBU(EDBU);}
#include <TopOpeBRepTool_2d.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GetcontextNOPURGE();
extern Standard_Boolean TopOpeBRepBuild_GetcontextNOCORRISO();
extern Standard_Boolean TopOpeBRepBuild_GettraceCHK();
Standard_EXPORT Standard_Boolean FUN_tool_ClosedW(const TopoDS_Wire& W);
// Unused :
-/*#ifdef DEB
+/*#ifdef OCCT_DEBUG
static void FUN_Raise(){cout<<"--------- ERROR in GWESMakeFaces ---------"<<endl;}
#endif*/
void TopOpeBRepBuild_Builder::GWESMakeFaces
(const TopoDS_Shape& FF,TopOpeBRepBuild_WireEdgeSet& WES,TopTools_ListOfShape& LOF)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF; Standard_Boolean tSPS = GtraceSPS(FF,iF);
DEBSHASET(s,"#--- GWESMakeFaces ",WES," ");
if(tSPS){ GdumpSHA(FF,(Standard_Address)s.ToCString());cout<<endl; WES.DumpSS();}
// This can occur when the face has a closing edge. To avoid this,
// we delete the lonesome closing edge from the wire.
Standard_Boolean topurge = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GetcontextNOPURGE()) topurge = Standard_False;
#endif
if (!puok) Standard_Failure::Raise("TopOpeBRepBuild::GWESMakeFaces");
topurge = !MshNOK.IsEmpty();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tSPS) DEBpurclo = Standard_False;
#endif
} // topurge
// translates edge's pcurve to have it in F's UVbounds
// translates edge's pcurve to have it connexed to others in UV space
Standard_Boolean corronISO = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepBuild_GetcontextNOCORRISO()) corronISO = Standard_False;
if (tSPS) debcorriso(iF);
#endif
void TopOpeBRepBuild_Builder::GFABUMakeFaces(const TopoDS_Shape& FF,TopOpeBRepBuild_FaceBuilder& FABU,
TopTools_ListOfShape& LOF,TopTools_DataMapOfShapeInteger& MWisOld)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iF;Standard_Boolean tSPS=GtraceSPS(FF,iF);
if(tSPS) {
cout<<endl;GdumpSHA(FF,(char *) "#--- GFABUMakeFaces ");cout<<endl;
} // !isold
//--ofv.
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( tSPS ) cout<<"#--- GFABUMakeFaces "<<iF<<" : "<<ne<<" edges"<<endl;
#endif
Standard_Boolean topurge = FUN_purgeFon1nonoriE(newFace);
if (topurge) {
-#ifdef TOPOPEBREPBUILD_DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceSTRANGE())
cout<<"Builder::GFABUMakeFaces -> purgeFon1nonoriE\n";
#endif
} // FABU.MoreFace()
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(tSPS) {
cout<<endl;GdumpSHA(FF, (char *) "#--- GFABUMakeFaces avant regularize");cout<<endl;
GdumpFABU(FABU);debgfabu(iF);
#include <TopOpeBRepTool.hxx>
#include <TopOpeBRepBuild_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceSTRANGE();
Standard_EXPORT void debgsobu(const Standard_Integer /*iSO*/) {}
#endif
void TopOpeBRepBuild_Builder::GSFSMakeSolids
(const TopoDS_Shape& SOF,TopOpeBRepBuild_ShellFaceSet& SFS,TopTools_ListOfShape& LOSO)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iSO; Standard_Boolean tSPS = GtraceSPS(SOF,iSO);
if(tSPS){GdumpSHA(SOF, (char *) "#--- GSFSMakeSolids ");cout<<endl;}
#endif
void TopOpeBRepBuild_Builder::GSOBUMakeSolids
(const TopoDS_Shape& SOF,TopOpeBRepBuild_SolidBuilder& SOBU,TopTools_ListOfShape& LOSO)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trcso = TopOpeBRepDS_GettraceSTRANGE();
Standard_Integer iSO; Standard_Boolean tSPS = GtraceSPS(SOF,iSO);
if(tSPS){GdumpSHA(SOF, (char *) "#--- GSOBUMakeSolids ");cout<<endl;}
TopExp_Explorer ex(newSolid,TopAbs_VERTEX);
Standard_Boolean isempty = ex.More();
if (!isempty) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trcso) cout <<"TopOpeBRepBuild_Builder::GSOBUMakeSolids ->EMPTY SOLID\n";
#endif
continue;
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <Standard_Type.hxx>
Standard_EXPORT void TopOpeBRepBuild_SettraceFE(const Standard_Boolean b) { TopOpeBRepBuild_traceFE = b; }
Standard_EXPORT Standard_Boolean TopOpeBRepBuild_GettraceFE() { return TopOpeBRepBuild_traceFE; }
-// #ifdef DEB
+// #ifdef OCCT_DEBUG
#endif
#include <TCollection_AsciiString.hxx>
#include <Geom2d_TrimmedCurve.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceDSNC();
extern Standard_Boolean TopOpeBRepDS_GettraceBUTO();
extern Standard_Boolean TopOpeBRepDS_GettraceTRPE();
// a mettre dans TopOpeBRepDS_Dumper.cxx NYI
//-----------------------------------------------------------------------
-#ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_OStream& PrintSurface(const TopoDS_Face& F, Standard_OStream& s)
{
BRepAdaptor_Surface STA_Surface(F);
//purpose : a mettre dans TopOpeBRepDS_Dumper.cxx NYI
//-----------------------------------------------------------------------
-#ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_Boolean GetOrigin(const Handle(Geom2d_Curve)& PCIN, gp_Pnt2d& o)
{
if (PCIN.IsNull()) return Standard_False;
//purpose : a mettre dans TopOpeBRepDS_Dumper.cxx NYI
//-----------------------------------------------------------------------
-#ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_Boolean GetOrigin(const Handle(Geom_Curve)& CIN, gp_Pnt& o)
{
if (CIN.IsNull()) return Standard_False;
myBuilder.MakeVertex(TopoDS::Vertex(V),P.Point(),P.Tolerance());
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
//-----------------------------------------------------------------------
static Standard_OStream& DUMPPNT(const gp_Pnt& P, Standard_OStream& OS)
//-----------------------------------------------------------------------
if (!BSC.IsNull()) {
if (BSC->Degree() == 1) {
myBuilder.Range(TopoDS::Edge(E),1,BSC->NbPoles());
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceBUTO()) {
cout<<endl<<"TopOpeBRepDS_BuildTool : ";
cout<<"new range of "<< 1 <<" "<<BSC->NbPoles()<<endl;
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceBUTO()) {
cout<<"TopOpeBRepDS_BuildTool : ";
cout<<"vertices on parameter "<<first<<endl;
Standard_Boolean rangedef = C.Range(first,last);
if (rangedef) {
Range(E,first,last);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceBUTO()) {
cout<<"TopOpeBRepDS_BuildTool : ";
cout<<"set edge range : "<<first<<" "<<last<<endl;
// newtol=tol3d;
// if (r1>newtol) newtol=r1;
// if (r2>newtol) newtol=r2;
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
// if (TopOpeBRepDS_GettraceDSNC()) cout<<"newtol = "<<newtol<<endl;
//#endif
inewC = HDS->MakeCurve(C,newC1);
TopOpeBRepDS_Curve& newC = HDS->ChangeCurve(inewC);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean tDSNC = TopOpeBRepDS_GettraceDSNC();
Standard_Boolean tBUTO = TopOpeBRepDS_GettraceBUTO();
#endif
TopoDS_Vertex Vmin,Vmax;Standard_Real parmin,parmax;
GetOrientedEdgeVertices(E,Vmin,Vmax,parmin,parmax);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tBUTO) cout<<"Recompute1 min,max = "<<parmin<<","<<parmax<<endl;
if (tBUTO) DUMPCURVES(C3D,C);
#endif
Standard_Real newtol,newparmin,newparmax;
// MSV Nov 12, 2001: if approx failed than leave old curves of degree 1
if (!approxMade) {
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"TopOpeBRepDS_BuildTool::ApproxCurves : approx failed, leave curves of degree 1"
<<endl;
#endif
Standard_Boolean sam = P3D.IsEqual(P3DC3D,tol);
PCreversed = !sam;
-#ifdef DEB
+#ifdef OCCT_DEBUG
#ifdef DRAW
Standard_Boolean tBUTO = TopOpeBRepDS_GettraceBUTO();
if (tBUTO) {FUN_draw(P3DC3D); FUN_draw(P3D);}
if (!FUN_getUV(surf,C3D,par3dsup,usup,vsup)) return Standard_False;
Standard_Real tol = Precision::Parametric(tol3d);
if (Abs(uinf-usup) > tol) return Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Real deltav = vsup-vinf;
#endif
if (!PC.IsNull()) {
Handle(Geom2d_Line) L = Handle(Geom2d_Line)::DownCast(PC);
L->SetLin2d(gp_Lin2d(origin,vdir));
-#ifdef DEB
+#ifdef OCCT_DEBUG
#ifdef DRAW
Standard_Boolean trc = TopOpeBRepDS_GettraceBUTO();
if (trc) {
const Standard_Boolean comppc2,
const Standard_Boolean compc3d) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean tDSNC = TopOpeBRepDS_GettraceDSNC();
Standard_Boolean tBUTO = TopOpeBRepDS_GettraceBUTO();
Standard_Boolean tTRPE = TopOpeBRepDS_GettraceTRPE();
const TopoDS_Face& F2 = TopoDS::Face(newC.Shape2());
const Handle(Geom_Curve)& C3D = C.Curve();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// const Handle(Geom2d_Curve)& PC1 = C.Curve1();
// const Handle(Geom2d_Curve)& PC2 = C.Curve2();
#endif
TopoDS_Vertex Vmin,Vmax;Standard_Real parmin,parmax;
GetOrientedEdgeVertices(E,Vmin,Vmax,parmin,parmax);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tBUTO) cout<<"Recompute2 min,max = "<<parmin<<","<<parmax<<endl;
if (tBUTO) DUMPCURVES(C3D,C);
#endif
ElCLib::AdjustPeriodic(f,f+period,Precision::PConfusion(),parmin,parmax);
if (compc3d) C3Dnew = new Geom_TrimmedCurve(C3D,parmin,parmax);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tBUTO||tTRPE) cout<<"Recompute2 : parmin,parmax "<<f<<","<<l<<endl;
if (tBUTO||tTRPE) cout<<" --> parmin,parmax "<<parmin<<","<<parmax<<endl;
#endif
if (!PC1new.IsNull()) newC.Curve1(PC1new);
if (!PC2new.IsNull()) newC.Curve2(PC2new);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tBUTO) DUMPCURVES(C3Dnew,newC);
#endif
}
if ( oV == TopAbs_REVERSED ) {
if ( p < f ) {
Standard_Real pp = ElCLib::InPeriod(p,f,f+per);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceBUTO() ) {
cout<<"BuildTool Parameter : "<<p<<" --> "<<pp<<endl;
}
if ( l2n <= f2n ) {
ElCLib::AdjustPeriodic(f1,l1,Precision::PConfusion(),f2n,l2n);
Range(Eou,f2n,l2n);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceBUTO() || TopOpeBRepDS_GettraceTRPE()) {
cout<<endl;
cout<<"UpdateEdge f1,l1 "<<f1<<" "<<l1<<endl;
du = u2 - u1, dv = v2 - v1;
if ( du != 0. || dv != 0.) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceBUTO() || TopOpeBRepDS_GettraceTRPE()) {
cout<<endl;
cout<<"TranslateOnPeriodic : Curve range "<<C3Df<<" "<<C3Dl<<endl;
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
//------------------------------------------------------------------------
static void DUMPPCURVE(const TopoDS_Edge& EE,
const TopoDS_Face& FF,
TopoDS_Edge EE = TopoDS::Edge(E);
Handle(Geom2d_Curve) PCT = PC;
-#ifdef DEB
+#ifdef OCCT_DEBUG
#ifdef DRAW
Standard_Boolean trc = Standard_False;
if (trc) FUN_draw(FF);
// pour iab, ajout de Translate
Standard_Boolean tran = myTranslate;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( TopOpeBRepDS_GettraceSANTRAN()) {
tran = Standard_False;
cout<<"SANS translation de pcurve"<<endl;
myBuilder.UpdateVertex(vi,newpar,EE,FF,tolvi);
} // INTERNAL vertex
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceTRPE()) DUMPPCURVE(EE,FF,PCT);
#endif
}
TopLoc_Location L; Standard_Real Cf,Cl;
Handle(Geom_Curve) C = BRep_Tool::Curve(EE,L,Cf,Cl);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceTRPE()) DUMPPCURVE(EE,FF,PCT);
#endif
TopOpeBRepDS_SetThePCurve(myBuilder,EE,FF,E.Orientation(),PCT);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceTRPE()) DUMPPCURVE(EE,FF,PCT);
#endif
}
TopoDS_Shape& EE,
TopOpeBRepDS_Curve& C2) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tDSNC = TopOpeBRepDS_GettraceDSNC();
Standard_Boolean tBUTO = TopOpeBRepDS_GettraceBUTO();
#endif
TopoDS_Vertex Vmin,Vmax; Standard_Real parmin,parmax;
::GetOrientedEdgeVertices(E,Vmin,Vmax,parmin,parmax);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tBUTO) cout<<"Recompute1 min,max = "<<parmin<<","<<parmax<<endl;
if (tBUTO) DUMPCURVES(C3D,C1);
#endif
TopoDS_Shape& EE,
TopOpeBRepDS_Curve& C2 ) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tDSNC = TopOpeBRepDS_GettraceDSNC();
Standard_Boolean tBUTO = TopOpeBRepDS_GettraceBUTO();
Standard_Boolean tTRPE = TopOpeBRepDS_GettraceTRPE();
TopoDS_Vertex Vmin,Vmax; Standard_Real parmin,parmax;
::GetOrientedEdgeVertices(E,Vmin,Vmax,parmin,parmax);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tBUTO) {cout<<"Recompute2 min,max = "<<parmin<<","<<parmax<<endl;
DUMPCURVES(C3D,C1);}
#endif
else { f = parmax; l = parmin; }
parmin = f; parmax = l;
ElCLib::AdjustPeriodic(f,f+period,Precision::PConfusion(),parmin,parmax);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tBUTO||tTRPE) cout<<"Recompute2 : parmin,parmax "<<f<<","<<l<<endl;
if (tBUTO||tTRPE) cout<<" --> parmin,parmax "<<parmin<<","<<parmax<<endl;
#endif
// Standard_Real isrev1 =
// ::FUN_reversePC(PC1new,F1,P3DC3D,par2d,tol);
//
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
// if (tBUTO && isrev1) cout<<"on retourne PC1"<<endl;
//#endif
//
// Standard_Real isrev2 =
// ::FUN_reversePC(PC2new,F2,P3DC3D,par2d,tol);
//
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
// if (tBUTO && isrev2) cout<<"on retourne PC2"<<endl;
//#endif
// }
if (!PC1new.IsNull()) C2.Curve1(PC1new);
if (!PC2new.IsNull()) C2.Curve2(PC2new);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tBUTO) DUMPCURVES(C3Dnew,C2);
#endif
}*/ // - merge 04-07-97
bI = bI && ChkIntgInterf(LI);
}
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
PrintIntg(cout);
#endif
// CheckEdgeParameter();
case TopOpeBRepDS_SURFACE :
{
if(myHDS->NbSurfaces() < I) {
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"Surpassed index of TopOpeBRepDS_SURFACE. actual index : "<<I;
cout<<". Index max : "<<myHDS->NbSurfaces();
#endif
case TopOpeBRepDS_CURVE :
{
if(myHDS->NbCurves() < I) {
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"Surpassed index of TopOpeBRepDS_CURVE. actual index : "<<I;
cout<<". Index max : "<<myHDS->NbCurves();
#endif
case TopOpeBRepDS_POINT :
{
if(myHDS->NbPoints() < I) {
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"Surpassed index of TopOpeBRepDS_POINT : actual index : "<<I;
cout<<". Index max : "<<myHDS->NbPoints()<<endl;
#endif
// topology
if(myHDS->NbShapes() < I) {
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"Surpassed index of TopOpeBRepDS_Shape_. actual index : "<<I;
cout<<". Index max : "<<myHDS->NbShapes();
#endif
break ;
}
if(S.ShapeType() != se) {
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"Error : Shape "<<I<<" is a ";
TopOpeBRepDS::Print(TopOpeBRepDS::ShapeToKind(S.ShapeType()), cout);
cout<<" and not a ";
const TopoDS_Shape& Sind = myHDS->Shape(i);
const TopTools_ListOfShape& losi = BDS.ShapeSameDomain(Sind);
if(!CheckShapes(losi)) {
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"Shape of ShapeSameDomain (n*n "<<i;
cout<<") is not defined in the DS"<<endl;
#endif
Curr = BDS.SameDomainRef(i);
Loc = BDS.SameDomainRef(Curr);
if(Curr && (Curr != Loc)) {
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"SameDomaineRef of Shape "<<i<<" = "<<Curr;
cout<<". SameDomaineRef of Shape "<<Curr<<" = "<<Loc<<endl;
#endif
// Verification du type des differents Shapes SameDomain
const TopoDS_Shape& Sref = myHDS->Shape(Curr);
if(Sind.ShapeType() != Sref.ShapeType()) {
-#ifdef TOPOPEBREPDS_DEBDEB
+#ifdef OCCT_DEBUG
cout<<"Shapes n*n "<<i<<" and "<<Curr<<" are SameDomain."<<endl;
cout<<"Type of Shape n*n "<<i<<" = ";
PrintShape(Sind.ShapeType(),cout);
liolos.Next();
}
if(!bb) {
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"Shapes n*n "<<i<<" and "<<Curr<<" are SameDomain. ";
cout<<"The reference of "<<i<<", is "<<Curr<<"."<<endl;
cout<<"However, Shape n*n "<<i;
Dist = P1.Distance(P2);
if(Dist <= tol1 + tol2) {
if(sdr1 != sdr2) {
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"Pb Vertex n+n"<<Curr1<<" and n*n"<<Curr2;
cout<<" : same place, not SameDomain"<<endl;
cout<<" Tol of Vertex n*n"<<Curr1<<" = "<<tol1<<endl;
}
}
else if(sdr1 == sdr2) {
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"Pb Vertex "<<Curr1<<" and "<<Curr2;
cout<<" : SameDomain, not same place"<<endl;
cout<<" Tol of Vertex n*n"<<Curr1<<" = "<<tol1<<endl;
const gp_Pnt& Pnt2 = TopOpeBRepTool_ShapeTool::Pnt(S1);
Dist = Pnt1.Distance(Pnt2);
if(Dist <= tol1 + tol2) {
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"Attention : Vertex "<<Curr1<<" and Point "<<PE.Index();
cout<<" are confused"<<endl;
cout<<" Tol of Vertex n*n"<<Curr1<<" = "<<tol1<<endl;
for(j = i+1;j < NbPo;j++) {
const TopOpeBRepDS_Point& dsPnt2 = myHDS->Point(j);
if(dsPnt1.IsEqual(dsPnt2)) {
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"Attention : points "<<i<<" and "<<j<<" are confused"<<endl;
cout<<" Tol of Point n*n"<<i<<" = "<<dsPnt1.Tolerance()<<endl;
cout<<" Tol of Point n*n"<<j<<" = "<<dsPnt1.Tolerance()<<endl;
Handle(TopOpeBRepDS_EdgeVertexInterference) EVI =
Handle(TopOpeBRepDS_EdgeVertexInterference)::DownCast(I1);
if(!EVI.IsNull()) {
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
// Standard_Integer Param = EVI->Parameter();
//#else
Standard_Integer Param = (Standard_Integer ) EVI->Parameter();
Handle(TopOpeBRepDS_CurvePointInterference)::DownCast(I1);
if(!CPI.IsNull()) {
Standard_Integer Param =
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
// TopOpeBRepDS_InterferenceTool::Parameter(CPI);
//#else
(Standard_Integer ) TopOpeBRepDS_InterferenceTool::Parameter(CPI);
return OS;
}
OS<<" ";
-#ifdef DEB
+#ifdef OCCT_DEBUG
const TopoDS_Shape& S =
#endif
myHDS->Shape(index);
-#ifdef DEB
+#ifdef OCCT_DEBUG
PrintShape(S.ShapeType(),cout);
OS<<" "<<index<<" = ";
Print(myMapShapeStatus.Find(index), cout);
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_OStream& TopOpeBRepDS_Curve::Dump (Standard_OStream& OS,
const Standard_Integer index,
const Standard_Boolean compact)const
Standard_OStream& TopOpeBRepDS_CurvePointInterference::Dump
(Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopOpeBRepDS_Kind supporttype = SupportType();
if (supporttype == TopOpeBRepDS_EDGE) OS<<"EPI";
else if (supporttype == TopOpeBRepDS_CURVE) OS<<"CPI";
#ifndef _TopOpeBRepDS_tsx_HeaderFile
#define _TopOpeBRepDS_tsx_HeaderFile
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopOpeBRepDS_define.hxx>
Standard_EXPORT void TopOpeBRepDS_SettraceSPSX(const Standard_Boolean b,Standard_Integer n,char** a);
#include <Geom_Surface.hxx>
//modified by NIZNHY-PKV Tue Oct 30 09:21:44 2001 t
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceSPSX(const Standard_Integer);
#include <TCollection_AsciiString.hxx>
#include <TopOpeBRepDS.hxx>
//=======================================================================
void TopOpeBRepDS_DataStructure::RemoveSurface(const Standard_Integer I)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean in =
#endif
mySurfaces.UnBind(I);
TopOpeBRepDS_CurveData CD(C);
myCurves.Bind(myNbCurves,CD);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// const TopOpeBRepDS_Curve& CCC = Curve(myNbCurves);
#endif
TopOpeBRepDS_ShapeData SD;
iS = myShapes.Add(S,SD);
// a shape is its own reference, oriented as itself
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean b = TopOpeBRepDS_GettraceSPSX(iS);
if (b) {cout<<"DS : add ";TopOpeBRepDS::Print(S.ShapeType(),iS,cout);cout<<endl;}
#endif
TopOpeBRepDS_ShapeData SD;
iS = myShapes.Add(S,SD);
// a shape is its own reference, oriented as itself
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean b = TopOpeBRepDS_GettraceSPSX(iS);
if (b) {
cout<<"DS : add ";TopOpeBRepDS::Print(S.ShapeType(),iS,cout);
//=======================================================================
void TopOpeBRepDS_DataStructure::AddShapeSameDomain(const TopoDS_Shape& S, const TopoDS_Shape& SSD)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// TopAbs_ShapeEnum t = SSD.ShapeType();
#endif
Standard_Boolean append = Standard_True;
//=======================================================================
void TopOpeBRepDS_DataStructure::RemoveShapeSameDomain(const TopoDS_Shape& S, const TopoDS_Shape& SSD)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// TopAbs_ShapeEnum t = SSD.ShapeType();
#endif
TopTools_ListOfShape& L = ChangeShapeSameDomain(S);
else if ( r1 != iS1 && r2 != iS2 ) {
if (r1 != r2) {
// Standard_ProgramError::Raise("FacesFiller::Insert SD 1");
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"FacesFiller::Insert SD 1"<<endl;
#endif
}
//=======================================================================
void TopOpeBRepDS_DataStructure::UnfillShapesSameDomain(const TopoDS_Shape& S1,const TopoDS_Shape& S2)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iS1 = Shape(S1);
// Standard_Integer iS2 = Shape(S2);
// Standard_Integer n1 = ShapeSameDomain(S1).Extent();
RemoveShapeSameDomain(S1,S2);
RemoveShapeSameDomain(S2,S1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer n11 = ShapeSameDomain(S1).Extent();
// Standard_Integer n22 = ShapeSameDomain(S2).Extent();
#endif
const TopOpeBRepDS_Point& TopOpeBRepDS_DataStructure::Point(const Standard_Integer I)const
{
if ( I < 1 || I > myNbPoints ) {
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"acces au POINT "<<I<<" incorrect "<<myNbPoints<<" max"<<endl;
#endif
Standard_ProgramError::Raise("TopOpeBRepDS_DataStructure::Point");
TopOpeBRepDS_Point& TopOpeBRepDS_DataStructure::ChangePoint(const Standard_Integer I)
{
if ( I < 1 || I > myNbPoints ) {
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"acces au POINT "<<I<<" incorrect "<<myNbPoints<<" max"<<endl;
#endif
Standard_ProgramError::Raise("TopOpeBRepDS_DataStructure::Point");
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::PrintType(const Handle(Geom_Curve)&
-#ifdef DEB
+#ifdef OCCT_DEBUG
C
#endif
,Standard_OStream& OS)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (C.IsNull()) {
OS<<"NULL CURVE";
return OS;
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::PrintType(const Handle(Geom2d_Curve)&
-#ifdef DEB
+#ifdef OCCT_DEBUG
C
#endif
,Standard_OStream& OS)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (C.IsNull()) {
OS<<"NULL CURVE2d";
return OS;
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::Print(const gp_Pnt&
-#ifdef DEB
+#ifdef OCCT_DEBUG
P
#endif
,Standard_OStream& OS)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OS<<P.X()<<" "<<P.Y()<<" "<<P.Z()<<" ";
#endif
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::Print(const gp_Pnt2d&
-#ifdef DEB
+#ifdef OCCT_DEBUG
P
#endif
,Standard_OStream& OS)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OS<<P.X()<<" "<<P.Y()<<" ";
#endif
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::Print(const Handle(Geom_BSplineCurve)&
-#ifdef DEB
+#ifdef OCCT_DEBUG
B
#endif
,Standard_OStream& OS
,const Standard_Boolean
-#ifdef DEB
+#ifdef OCCT_DEBUG
compact
#endif
)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer i,l,lb = 0,n;
Standard_Integer degree = B->Degree();
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::Print(const Handle(Geom2d_BSplineCurve)&
-#ifdef DEB
+#ifdef OCCT_DEBUG
B
#endif
,Standard_OStream& OS
,const Standard_Boolean
-#ifdef DEB
+#ifdef OCCT_DEBUG
compact
#endif
)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer i,l,lb=-1,n;
Standard_Integer degree = B->Degree();
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::Print(const Handle(Geom_Curve)&
-#ifdef DEB
+#ifdef OCCT_DEBUG
C
#endif
,Standard_OStream& OS
,const Standard_Boolean
-#ifdef DEB
+#ifdef OCCT_DEBUG
compact
#endif
)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
#define DBSP3D(tut) (*((Handle(Geom_BSplineCurve)*)&(tut)))
if (!C.IsNull()) {
if (C->DynamicType() == STANDARD_TYPE(Geom_BSplineCurve))
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_OStream& TopOpeBRepDS_Dumper::Print(const Handle(Geom2d_Curve)& C,
Standard_OStream& OS,const Standard_Boolean compact)
{
// DUMP OF HDATASTRUCTURE
//-----------------------------------------------------------------------
-#ifdef DEB
+#ifdef OCCT_DEBUG
//unreferenced function, commented
/*static void souligne(const TCollection_AsciiString& t,Standard_OStream& OS,const char c = '-')
{ for(char i=0;i<t.Length();i++)OS<<c; }*/
Standard_OStream& TopOpeBRepDS_Dumper::Dump(Standard_OStream& OS
,const Standard_Boolean
-#ifdef DEB
+#ifdef OCCT_DEBUG
findkeep
#endif
,const Standard_Boolean
-#ifdef DEB
+#ifdef OCCT_DEBUG
compact
#endif
) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OS<<endl<<"==== HDS start filling resume"<<endl;
DumpGeometry(OS,findkeep,compact);
DumpTopology(OS);
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::DumpGeometry(Standard_OStream& OS
,const Standard_Boolean
-#ifdef DEB
+#ifdef OCCT_DEBUG
findkeep
#endif
,const Standard_Boolean
-#ifdef DEB
+#ifdef OCCT_DEBUG
compact
#endif
) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
DumpGeometry(TopOpeBRepDS_POINT,OS,findkeep,compact);
DumpGeometry(TopOpeBRepDS_CURVE,OS,findkeep,compact);
DumpGeometry(TopOpeBRepDS_SURFACE,OS,findkeep,compact);
Standard_OStream& TopOpeBRepDS_Dumper::DumpGeometry
(const TopOpeBRepDS_Kind
-#ifdef DEB
+#ifdef OCCT_DEBUG
K
#endif
,Standard_OStream& OS
,const Standard_Boolean
-#ifdef DEB
+#ifdef OCCT_DEBUG
findkeep
#endif
,const Standard_Boolean
-#ifdef DEB
+#ifdef OCCT_DEBUG
compact
#endif
) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( ! TopOpeBRepDS::IsGeometry(K) ) return OS;
Standard_Integer nt = myHDS->NbGeometry(K);
if (!nt) return OS;
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::DumpGeometry(const TopOpeBRepDS_Kind
-#ifdef DEB
+#ifdef OCCT_DEBUG
K
#endif
,const Standard_Integer
-#ifdef DEB
+#ifdef OCCT_DEBUG
I
#endif
,Standard_OStream& OS,
const Standard_Boolean
-#ifdef DEB
+#ifdef OCCT_DEBUG
findkeep
#endif
,const Standard_Boolean
-#ifdef DEB
+#ifdef OCCT_DEBUG
compact
#endif
) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( ! TopOpeBRepDS::IsGeometry(K) ) return OS;
if ( K == TopOpeBRepDS_POINT ) {
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::DumpTopology(Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
DumpTopology(TopOpeBRepDS_VERTEX,OS);
DumpTopology(TopOpeBRepDS_EDGE,OS);
DumpTopology(TopOpeBRepDS_WIRE,OS);
//purpose :
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::DumpTopology(const TopOpeBRepDS_Kind
-#ifdef DEB
+#ifdef OCCT_DEBUG
K
#endif
,Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( ! TopOpeBRepDS::IsTopology(K) ) return OS;
Standard_Integer nk = myHDS->NbTopology(K);
if ( ! nk ) return OS;
//purpose :
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::DumpTopology(const TopAbs_ShapeEnum
-#ifdef DEB
+#ifdef OCCT_DEBUG
T
#endif
,Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
DumpTopology(TopOpeBRepDS::ShapeToKind(T),OS);
#endif
return OS;
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::DumpSectionEdge(const TopOpeBRepDS_Kind
-#ifdef DEB
+#ifdef OCCT_DEBUG
K
#endif
,Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer nse = myHDS->DS().NbSectionEdges();
if ( ! nse ) return OS;
//purpose :
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::DumpTopology(const TopOpeBRepDS_Kind
-#ifdef DEB
+#ifdef OCCT_DEBUG
K
#endif
,const Standard_Integer
-#ifdef DEB
+#ifdef OCCT_DEBUG
I
#endif
,Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean fk = Standard_False;
const TopOpeBRepDS_DataStructure& DS = myHDS->DS();
if ( ! TopOpeBRepDS::IsTopology(K) ) return OS;
//purpose :
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::DumpTopology(const TopAbs_ShapeEnum
-#ifdef DEB
+#ifdef OCCT_DEBUG
T
#endif
,const Standard_Integer
-#ifdef DEB
+#ifdef OCCT_DEBUG
I
#endif
,Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
DumpTopology(TopOpeBRepDS::ShapeToKind(T),I,OS);
#endif
return OS;
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::DumpRefOri(const TopOpeBRepDS_Kind
-#ifdef DEB
+#ifdef OCCT_DEBUG
K
#endif
,const Standard_Integer
-#ifdef DEB
+#ifdef OCCT_DEBUG
I
#endif
,Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OS<<SDumpRefOri(K,I);OS.flush();
#endif
return OS;
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::DumpRefOri(const TopoDS_Shape&
-#ifdef DEB
+#ifdef OCCT_DEBUG
S
#endif
,Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OS<<SDumpRefOri(S);OS.flush();
#endif
return OS;
Standard_OStream& TopOpeBRepDS_Dumper::DumpLOI(
const TopOpeBRepDS_ListOfInterference&
-#ifdef DEB
+#ifdef OCCT_DEBUG
L
#endif
,Standard_OStream& OS,
const TCollection_AsciiString&
-#ifdef DEB
+#ifdef OCCT_DEBUG
str
#endif
) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OS<<str;
TopOpeBRepDS_InterferenceIterator IT(L); if (!IT.More()) { OS<<"NO INTERFERENCE"<<endl; return OS; }
OS<<endl;
//=======================================================================
Standard_OStream& TopOpeBRepDS_Dumper::DumpI(
const Handle(TopOpeBRepDS_Interference)&
-#ifdef DEB
+#ifdef OCCT_DEBUG
I
#endif
,Standard_OStream& OS
,const TCollection_AsciiString&
-#ifdef DEB
+#ifdef OCCT_DEBUG
str1
#endif
,const TCollection_AsciiString&
-#ifdef DEB
+#ifdef OCCT_DEBUG
str2
#endif
) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean fk = Standard_False;
OS<<str1;
if (I.IsNull()) { OS<<"NULL INTERFERENCE"<<str2; return OS; }
#include <TopOpeBRepDS_repvg.hxx>
#include <TopOpeBRepDS_connex.hxx>
#include <TopOpeBRepTool_TOOL.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopOpeBRepDS_reDEB.hxx>
Standard_EXPORT void debredpnc(const Standard_Integer ie){cout<<"+++ debredpnc e"<<ie<<endl;}
extern Standard_Boolean TopOpeBRepDS_GetcontextNOPNC();
static void FDS_reduceONFACEinterferences(TopOpeBRepDS_ListOfInterference& LI,
const TopOpeBRepDS_DataStructure& /*BDS*/,
const Standard_Integer
-#ifdef DEB
+#ifdef OCCT_DEBUG
EIX
#endif
)
//------------------------------------------------------
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=DSREDUEDGETRCE(EIX);
TRC = Standard_False; //MOINSTRACE
if (TRC) cout<<endl<<"reduceONFACEinterferences on "<<EIX<<" <- "<<LI.Extent()<<endl;
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC){if( hasONFACE)cout<<"egde "<<EIX<<" has (ON,FACE)"<<endl;}
if(TRC){if(!hasONFACE)cout<<"egde "<<EIX<<" has no (ON,FACE)"<<endl;}
#endif
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout<<"reduceONFACEinterferences E"<<EIX<<" -> "<<LI.Extent()<<endl<<endl;
#endif
}
// <LI> -> <reducedLI> + <LI>
{
reducedLI.Clear();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=DSREDUEDGETRCE(SIX);
TRC = Standard_False; //MOINSTRACE
if(TRC) {cout<<endl; debreducer3d(SIX);}
Standard_Boolean sdm = FUN_ds_sdm(BDS,E,E1);
if (sdm) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout<<" NO I3d : e"<<SIX<<" same domain with e"<<S1<<endl;
#endif
it2.Next(); continue;
isComplex = Standard_True;
EFITool.Init(E,E1,F1,I1);
EFITool.Add(E,E1,F1,I1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC){cout<<endl<<"complex T3d E"<<SIX<<endl;I1->Dump(cout,"init :","\n");}
#endif
} // !isComplex
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC) I2->Dump(cout,"add : ","\n");
#endif
EFITool.Add(E,E2,F2,I2);
LI.Remove(it2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC){cout<<"resulting : "; Handle(TopOpeBRepDS_Interference) IBID = new TopOpeBRepDS_Interference();
EFITool.Transition(IBID);IBID->Transition().Dump(cout);cout<<endl;}
#endif
newI = new TopOpeBRepDS_CurvePointInterference(T,TopOpeBRepDS_FACE,IB1,TopOpeBRepDS_POINT,G1,CPI->Parameter());
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC){cout<<"reduced T E"<<SIX<<" ";newI->Dump(cout);cout<<endl;}
#endif
if (!newI.IsNull()) {
it1.Next();
} // it1
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) {
cout<<"ReducerEdge3d E"<<SIX<<" -> nIreduced "<<reducedLI.Extent();
cout<<" + nInonreduced "<<LI.Extent()<<endl<<endl;
TopOpeBRepDS_ListOfInterference& LI,TopOpeBRepDS_ListOfInterference& reducedLI)
//------------------------------------------------------
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=DSREDUEDGETRCE(SIX);
// TRC = Standard_False; //MOINSTRACE
if (TRC) cout<<endl<<"ReducerEdge E"<<SIX<<" <- nI "<<LI.Extent()<<endl;
FDS_reduceONFACEinterferences(LI,BDS,SIX);
FDS_repvg(BDS,SIX,TopOpeBRepDS_POINT,LI,reducedLI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout<<"ReducerEdge E"<<SIX<<" -> nI "<<LI.Extent()<<endl<<endl;
#endif
}
{
reducedLI.Clear();
Standard_Integer nI = LI.Extent();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=DSREDUEDGETRCE(SIX);
TRC = Standard_False; //MOINSTRACE
if (TRC) cout<<endl<<"ReducerSDEdge E"<<SIX<<" <- nI "<<nI<<endl;
LI.Clear(); LI.Append(newLI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout<<"ReducerSDEdge E"<<SIX<<" -> nI "<<LI.Extent()<<endl<<endl;
#endif
}
// I2 = (IN/OU(SE),VG,SE))} -> Ir = (IN/IN(SE),VG,SE)
{
reducedLI.Clear();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer nI = LI.Extent(); // DEB
#endif
const TopoDS_Edge& E = TopoDS::Edge(BDS.Shape(SIX));
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=DSREDUEDGETRCE(SIX);
TRC = Standard_False; //MOINSTRACE
if (TRC) cout<<endl<<"reclSE2 E"<<SIX<<" <- nI "<<nI<<endl;
if (O2 != cO1) {it2.Next(); continue;}
LI.Remove(it2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
nI = LI.Extent(); // DEB
#endif
hascO = Standard_True; break;
if (hascO) {
I1->ChangeTransition().Set(TopAbs_INTERNAL);
reducedLI.Append(I1); LI.Remove(it1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
nI = LI.Extent(); // DEB
#endif
}
else it1.Next();
} //it1
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout<<"reclSE2 E"<<SIX<<" -> nI "<<LI.Extent()<<endl<<endl;
#endif
} // FUN_reclSE2
//------------------------------------------------------
{
TopOpeBRepDS_TKI tki; tki.FillOnGeometry(LOI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=DSREDUEDGETRCE(EIX);
TRC = Standard_False; //MOINSTRACE
if (TRC) cout<<endl<<"reclSE E"<<EIX<<" <- "<<LOI.Extent()<<endl;
TopOpeBRepDS_Kind K; Standard_Integer G; tki.Value(K,G);
if (K != TopOpeBRepDS_VERTEX) continue;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) {tki.DumpTKI(K,G,"","\n");}
#endif
TopOpeBRepDS_ListOfInterference& loi = tki.ChangeValue(K,G); TopOpeBRepDS_ListOfInterference Rloi;
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout<<"reclSE E"<<EIX<<" -> reste "<<LOI.Extent()<<" + reduit "<<RLOI.Extent()<<endl<<endl;
#endif
} // FUN_reclSE
// LI = {I attached to <E> = (T,G,S)}, unkeep I = EVI with G = vertex of <E>
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=DSREDUEDGETRCE(EIX);
TRC = Standard_False; //MOINSTRACE
if (TRC) {cout<<endl;debreducerE(EIX);}
const TopoDS_Vertex& V = TopoDS::Vertex(BDS.Shape(G));
Standard_Integer o = FUN_tool_orientVinE(V,E);
if (o == 0){it.Next(); continue;}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) {cout<<"-> rejet EVI on Gb 1 on "<<EIX<<" : ";I->Dump(cout);cout<<endl;}
#endif
LI.Remove(it);
// ---------------------------------------------------------
//unreferenced function, commented
-/*#ifdef DEB
+/*#ifdef OCCT_DEBUG
static void FUN_reorder(const Standard_Integer EIX, const Handle(TopOpeBRepDS_HDataStructure)& HDS,TopOpeBRepDS_ListOfInterference& LIR, TopOpeBRepDS_ListOfInterference& LI, TopOpeBRepDS_ListOfInterference& LIend)
// ---------------------------------------------------------
// at same G :in <LI> I =(T, G, S)
TopOpeBRepDS_ListOfInterference& loiR = tkiR.ChangeValue(K,G);
TopOpeBRepDS_ListOfInterference& loi = tki.ChangeValue(K,G);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) {TCollection_AsciiString bb("lIreduced");bb += TCollection_AsciiString(G);DSD.DumpLOI(loiR,cout,bb);
TCollection_AsciiString aa("lI");aa+=TCollection_AsciiString(G);DSD.DumpLOI(loi,cout,aa);}
#endif
loiR.Append(loi);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout<<"-> ordered :"<<endl;
#endif
for (tkiR.Init(); tkiR.More(); tkiR.Next()) {
TopOpeBRepDS_Kind K; Standard_Integer G; TopOpeBRepDS_ListOfInterference& loi = tkiR.ChangeValue(K,G);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) {TCollection_AsciiString aa("lI");aa+=TCollection_AsciiString(G);DSD.DumpLOI(loi,cout,aa);}
#endif
LIend.Append(loi);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout<<"-> residual :"<<endl;
#endif
for (tki.Init(); tki.More(); tki.Next()) {
TopOpeBRepDS_Kind K; Standard_Integer G; TopOpeBRepDS_ListOfInterference& loi = tki.ChangeValue(K,G);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) {TCollection_AsciiString aa("lI");aa+=TCollection_AsciiString(G);DSD.DumpLOI(loi,cout,aa);}
#endif
LIend.Append(loi);
*/
static void FUN_keepl3dF(const Standard_Integer
-#ifdef DEB
+#ifdef OCCT_DEBUG
SIX
#endif
,const Handle(TopOpeBRepDS_HDataStructure)&
-#ifdef DEB
+#ifdef OCCT_DEBUG
HDS
#endif
,const TopOpeBRepDS_ListOfInterference& l3dF
//purpose : soit I de l3dF, on cherche IR interf dans LR3dFE de meme geometrie
// si on n'en trouve pas, l3dFkeep += I
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=DSREDUEDGETRCE(SIX);
TRC = Standard_False; //MOINSTRACE
if (TRC) cout<<endl<<"keepl3dF E"<<SIX<<endl;
Standard_Boolean isbound = tkiR.IsBound(K,G);
if (!isbound) {l3dFkeep.Append(loi);}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) {TCollection_AsciiString bb("l3dFkeep");bb += TCollection_AsciiString(G);DSD.DumpLOI(loi,cout,bb);cout<<endl;}
#endif
}
}
static void FUN_ProcessEdgeInterferences(const Standard_Integer EIX
, const TopOpeBRepDS_Kind
-#ifdef DEB
+#ifdef OCCT_DEBUG
K
#endif
,const Standard_Integer
-#ifdef DEB
+#ifdef OCCT_DEBUG
G
#endif
, const Handle(TopOpeBRepDS_HDataStructure)& HDS,
{
TopOpeBRepDS_DataStructure& BDS = HDS->ChangeDS();
const TopoDS_Shape& E = BDS.Shape(EIX);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=DSREDUEDGETRCE(EIX);
if (TRC) {
cout<<endl;debreducerE(EIX);cout<<"EIR E"<<EIX;
TopOpeBRepDS_ListOfInterference lFE; FUN_selectSKinterference(lF,TopOpeBRepDS_EDGE,lFE);
TopOpeBRepDS_ListOfInterference lE; FUN_selectTRASHAinterference(LI,TopAbs_EDGE,lE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopOpeBRepDS_Dumper DSD(HDS);
Standard_Boolean trcl = TRC;
// trcl = Standard_False; // MOINSTRACE
// lF -> lF
// lFE -> lI2dFE + [lFE] / lI2dFE={FEI=(T(FTRASHA),G,SE) : no FFI=(T(FTRASHA),G,FTRASHA)}
FUN_selectpure2dI(lF,lFE,lI2dFE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trcl) {
cout<<endl<<"lI2dFE -> lRI2dFE + lI2dFE"<<endl;
TCollection_AsciiString aa("lI2dFE :"); DSD.DumpLOI(lI2dFE,cout,aa);
}
#endif
::FUN_reducepure2dI(lI2dFE,lRI2dFE); // lI2dFE -> lRI2dFE + lI2dFE
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trcl) { TCollection_AsciiString bb("lRI2dFE :"); DSD.DumpLOI(lRI2dFE,cout,bb);}
#endif
lFE.Append(lI2dFE); lFE.Append(lRI2dFE);
TopOpeBRepDS_ListOfInterference l1dE; FUN_select2dI(EIX,BDS,TopAbs_EDGE,lE,l1dE);
TopOpeBRepDS_ListOfInterference l1dEsd; FUN_select1dI(EIX,BDS,lE,l1dEsd);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trcl) {
cout<<"lFE("<<EIX<<") -> l3dFE (S=EDGE) [+l3dFEresi] + l2dFE + [lFE +lFEresi]"<<endl;
TCollection_AsciiString oo("lFE :");DSD.DumpLOI(lFE,cout,oo);
// ----------
// l3dFE -> lR3dFE [+l3dFE (non reduced 3dI)]
TopOpeBRepDS_ListOfInterference lR3dFE; FUN_ReducerEdge3d(EIX,BDS,l3dFE,lR3dFE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trcl) { cout<<"l3dFE("<<EIX<<") -> lR3dFE + l3dFE"<<endl;
TCollection_AsciiString aa("lR3dFE :");DSD.DumpLOI(lR3dFE,cout,aa);
TCollection_AsciiString bb("l3dFE :"); DSD.DumpLOI(l3dFE,cout,bb);}
}
//FUN_unkeepEVIonGb1(BDS,EIX,LI); // filter :
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC){TCollection_AsciiString aa("reduced->");DSD.DumpLOI(LI,cout,aa);}
#endif
} // ProcessEdgeInterferences
{
TopOpeBRepDS_DataStructure& BDS = myHDS->ChangeDS();
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopOpeBRepDS_Dumper DSD(myHDS);
Standard_Boolean TRC=DSREDUEDGETRCE(EIX);
if (TRC) {cout<<endl;debreducerE(EIX);}
Standard_Real par = FDS_Parameter(I);
Handle(TopOpeBRepDS_Interference) newI = MakeEPVInterference(I->Transition(),S,OOG,par,K,ST,Standard_False);
newloi.Append(newI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) {cout<<"on e"<<EIX;I->Dump(cout);cout<<"gives ";newI->Dump(cout);cout<<endl;}
#endif
}
LI.Append(LInew);
Standard_Boolean performPNC = Standard_False; // JYL 28/09/98 : temporaire
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GetcontextNOPNC()) performPNC = Standard_False;
if (TRC) debredpnc(EIX);
#endif
}
const TopTools_ListOfShape& lfx = FDSCNX_EdgeConnexitySameShape(E,myHDS);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nlfx = lfx.Extent();
#endif
if (curvefound) break;
} // itlfx.More()
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nLI = LI.Extent();
#endif
if (curvefound) {
LI.Append(loi);
}
else {
-#ifdef DEB
+#ifdef OCCT_DEBUG
// if (TRC) {
// debredpnc(EIX);
TCollection_AsciiString ss = "\n--- TopOpeBRepDS_EIR::ProcessEdgeInterferences : suppress pnc of E"; ss = ss + EIX;
#include <TopOpeBRepDS_TOOL.hxx>
#include <TopOpeBRepDS_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopOpeBRepDS_reDEB.hxx>
extern Standard_Boolean TopOpeBRepDS_GettraceSPSX(const Standard_Integer);
Standard_EXPORT void debse1(const Standard_Integer i) {cout<<"+ debse1 se"<<i<<endl;}
#endif
static void FUN_Raise()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// cout<<"FUN_ds_completeforSE"<<endl;
// Standard_ProgramError::Raise("FUN_ds_completeforSE");
#endif
//------------------------------------------------------
Standard_EXPORT void FDS_dumpLI
//------------------------------------------------------
-#ifndef DEB
+#ifndef OCCT_DEBUG
(const TopOpeBRepDS_ListOfInterference& ,const char* )
{
#else
if (I.IsNull()) return Standard_False;
Standard_Boolean ya = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// const TopOpeBRepDS_Transition& T1 = I->Transition();
#endif
TopAbs_ShapeEnum SB1,SA1;Standard_Integer IB1,IA1;TopOpeBRepDS_Kind GT1,ST1;Standard_Integer G1,S1;
else if ( I->IsKind(STANDARD_TYPE(TopOpeBRepDS_CurvePointInterference)) )
p = Handle(TopOpeBRepDS_CurvePointInterference)::DownCast(I)->Parameter();
else {
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"EdgeInterference : mauvais type d'interference"<<endl;
#endif
Standard_Failure::Raise("FDS_Parameter");
TopTools_ListIteratorOfListOfShape it(lssd);
for (; it.More(); it.Next()) {
const TopoDS_Shape& esd = it.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iesd = BDS.Shape(esd);
// Standard_Integer resd = BDS.SameDomainInd(esd);
#endif
TopTools_ListIteratorOfListOfShape it(lssd);
for (; it.More(); it.Next()) {
const TopoDS_Shape& esd = it.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iesd = BDS.Shape(esd);
// Standard_Integer resd = BDS.SameDomainInd(esd);
#endif
}
//unreferenced function, commented
-/*#ifdef DEB
+/*#ifdef OCCT_DEBUG
static Standard_Integer FUN_ds_FaceConnexitySameShape(const TopoDS_Vertex& V, const TopoDS_Edge& E, const Handle(TopOpeBRepDS_HDataStructure)& HDS,
TopTools_ListOfShape& lFcx)
// very expensive, but found no other way (nyi : modify DS_connex.cxx)
{
lFcx.Clear();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// const TopOpeBRepDS_DataStructure& BDS = HDS->DS();
#endif
const TopTools_ListOfShape& lf1 = FDSCNX_EdgeConnexitySameShape(E,HDS);
if (isdgE) continue;
Standard_Integer IE = BDS.Shape(E);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSPSX(IE);
if (trc) debe9(IE);
#endif
if (!foundinsdm) {it.Next(); continue;} // E is IN geometry(F) (cto002D2;e33,f31)
// E is edge of FF sdm with F
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"-> SE9 removing I3dF :";I->Dump(cout);cout<<endl;}
#endif
removed = Standard_True; l3dF.Remove(it);
const TopoDS_Edge& SE = BDS.SectionEdge(i);
Standard_Integer ISE = BDS.Shape(SE);
const TopOpeBRepDS_ListOfInterference& LI = BDS.ShapeInterferences(SE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSPSX(ISE);
if (trc) debse1(ISE);
#endif
it.Initialize(lI3) ;
for ( ;it.More(); it.Next()){
const Handle(TopOpeBRepDS_Interference)& I = it.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// const TopOpeBRepDS_Transition& T = I->Transition();
#endif
TopOpeBRepDS_Kind GT,ST;
// -> do NOT reduce to I = (INTERNAL(IfES),G1,S) (we can have EXTERNAL Tr)
FDS_copy(loi,loicopy);
TopOpeBRepDS_ListOfInterference lI4;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nI4 =
#endif
FUN_selectITRASHAinterference(loicopy,IfES,lI4);
Standard_Boolean B = Standard_False;
if (isevi) B = Handle(TopOpeBRepDS_EdgeVertexInterference)::DownCast(I)->GBound();
Handle(TopOpeBRepDS_Interference) newI = MakeEPVInterference(newT,S,G1,par,K,TopOpeBRepDS_EDGE,B);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
cout<<"completeforSE1 on section edge "<<ISE<<" ";
newI->Dump(cout);
for (Standard_Integer i = 1; i <= nse; i++) {
const TopoDS_Edge& SE = TopoDS::Edge(BDS.SectionEdge(i));
Standard_Integer rkSE = BDS.AncestorRank(SE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer ISE =
#endif
BDS.Shape(SE);
const TopOpeBRepDS_ListOfInterference& LI = BDS.ShapeInterferences(SE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSPSX(ISE);
if (trc) debse2(ISE);
#endif
// has NO {I'=(T'(face'), G not Gbound, face')}
TopOpeBRepDS_ListOfInterference loicopy; FDS_assign(loi,loicopy);
TopOpeBRepDS_ListOfInterference l1;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nI =
#endif
FUN_selectTRASHAinterference(loicopy,TopAbs_FACE,l1);
// I = (T(FTRA),G not Gbound, ES)
const Handle(TopOpeBRepDS_Interference)& I = lFE.First();
Standard_Real par = FDS_Parameter(I);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// const TopOpeBRepDS_Transition& T = I->Transition();
#endif
TopOpeBRepDS_Kind ST; Standard_Integer S; FDS_data(I,K,G,ST,S);
Standard_Boolean B = Standard_False;
if (vertex) B = Handle(TopOpeBRepDS_EdgeVertexInterference)::DownCast(I)->GBound();
newI = MakeEPVInterference(newT,IFCX,G,par,K,TopOpeBRepDS_FACE,B);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"completeforSE2 on section edge "<<ISE<<" ";newI->Dump(cout);cout<<endl;}
#endif
HDS->StoreInterference(newI,SE);
const TopoDS_Edge& SE = BDS.SectionEdge(i);
Standard_Integer ISE = BDS.Shape(SE);
const TopOpeBRepDS_ListOfInterference& LI = BDS.ShapeInterferences(SE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSPSX(ISE);
if (trc) debse3(ISE);
#endif
// delete interferences =(T(face IF),G,S)
TopOpeBRepDS_ListOfInterference lIdel;
FUN_selectITRASHAinterference(loicopy,ITRASHA,lIdel);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {FDS_dumpLI(lIdel,"completeforSE3, delete :");}
#endif
hasnewLI = Standard_True;
TrFE = MakeEPVInterference(Tr, ISE,G,parE,K,TopOpeBRepDS_EDGE,Standard_False);
TrFF = MakeEPVInterference(Tr,ITRASHA,G,parE,K,TopOpeBRepDS_FACE,Standard_False);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"completeforSE3 on section edge "<<ISE<<" ";TrFE->Dump(cout);cout<<endl;}
if (trc) {cout<<"completeforSE3 on section edge "<<ISE<<" ";TrFF->Dump(cout);cout<<endl;}
#endif
if (pardef) parEG = paronEG;
else {
Standard_Real f,l; FUN_tool_bounds(Esp,f,l);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Real x = 0.45678;
// Standard_Real par = (1-x)*f + x*l;
#endif
TopOpeBRepDS_DataStructure& BDS = HDS->ChangeDS();
Standard_Integer ns = BDS.NbShapes();
for (Standard_Integer i= 1; i <= ns; i++) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSPSX(i);
if (trc) debsdm1(i);
#endif
Standard_Integer nse = BDS.NbSectionEdges();
for (Standard_Integer i = 1; i <= nse; i++) {
const TopoDS_Edge& SE = BDS.SectionEdge(i);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer ISE =
#endif
BDS.Shape(SE);
const TopOpeBRepDS_ListOfInterference& LI = BDS.ShapeInterferences(SE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSPSX(ISE);
if (trc) debse4(ISE);
#endif
TopOpeBRepDS_Transition newT(newO); newT.Index(isb);
Standard_Real par = FDS_Parameter(I);
Handle(TopOpeBRepDS_Interference) newI = MakeEPVInterference(newT,S,G,par,K,Standard_False);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"completeforSE4 on section edge "<<ISE<<" ";newI->Dump(cout);cout<<endl;}
#endif
HDS->StoreInterference(newI,SE);
Standard_Integer nse = BDS.NbSectionEdges();
for (Standard_Integer i = 1; i <= nse; i++) {
const TopoDS_Edge& SE = BDS.SectionEdge(i);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer ISE =
#endif
BDS.Shape(SE);
const TopOpeBRepDS_ListOfInterference& LOI = BDS.ShapeInterferences(SE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSPSX(ISE);
if (trc) debse5(ISE);
#endif
for (; it.More(); it.Next()){
const Handle(TopOpeBRepDS_Interference)& I = it.Value();
Handle(TopOpeBRepDS_Interference) newI = I; newI->ChangeTransition().Set(newO);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"completeforSE5 se"<<ISE<<"->";newI->Dump(cout);cout<<endl;}
#endif
newLI.Append(I);
for (Standard_Integer i = 1; i <= nse; i++) {
const TopoDS_Edge& SE = BDS.SectionEdge(i);
Standard_Integer ISE = BDS.Shape(SE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSPSX(ISE);
if (trc) debse6(ISE);
#endif
}
TopOpeBRepDS_ListOfInterference l2dFE; FDS_assign(LIb,LIcopy);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer n2d =
#endif
FUN_ds_hasI2d(ISE,LIcopy,l2dFE);
TopOpeBRepDS_ListOfInterference l1dE; FDS_assign(LIb,LIcopy);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer n1d =
#endif
FUN_selectTRASHAinterference(LIcopy,TopAbs_EDGE,l1dE);
gp_Vec tgEsd; TopOpeBRepTool_TOOL::TggeomE(parEsd,Esd,tgEsd); // dir
gp_Vec tgE ; TopOpeBRepTool_TOOL::TggeomE(parE,SE,tgE); // dir
Standard_Real dot = tgEsd.Dot(tgE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Real tola = Precision::Angular();
if (Abs(dot) < tola) Standard_Failure::Raise("completeforSE6");
#endif
}
newT.Index(iEsd);
Handle(TopOpeBRepDS_Interference) newI1d = MakeEPVInterference(newT,iEsd,G,parE,TopOpeBRepDS_VERTEX,Standard_False);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"completeforS61 on section edge "<<ISE<<" ";newI1d->Dump(cout);cout<<endl;}
#endif
HDS->StoreInterference(newI1d,SE);
Standard_Boolean isdgE = BRep_Tool::Degenerated(E);
if (isdgE) continue;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer IE =
#endif
BDS.Shape(E);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSPSX(IE);
if (trc) debe7(IE);
#endif
TopOpeBRepDS_Kind K; Standard_Integer G; const TopOpeBRepDS_ListOfInterference& loi = tki.Value(K,G);
TopOpeBRepDS_ListOfInterference loicopy; FDS_assign(loi,loicopy);
TopOpeBRepDS_ListOfInterference l1;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer n1 =
#endif
FUN_selectSKinterference(loicopy,TopOpeBRepDS_FACE,l1);
if (iFS != 0) {
TopOpeBRepDS_ListOfInterference& loii = tki.ChangeValue(K,G);
TopOpeBRepDS_ListOfInterference lEFS;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nIFS =
#endif
FUN_selectITRASHAinterference(loii,iFS,lEFS);
for (TopOpeBRepDS_ListIteratorOfListOfInterference iti(lnewI); iti.More(); iti.Next()) {
Handle(TopOpeBRepDS_Interference) newI = iti.Value();
loii.Append(newI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"completeforE7 on edge "<<IE<<" ";newI->Dump(cout);cout<<endl;}
#endif
}
const TopoDS_Edge& SE = BDS.SectionEdge(i);
Standard_Integer ISE = BDS.Shape(SE);
const TopOpeBRepDS_ListOfInterference& LI = BDS.ShapeInterferences(SE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSPSX(ISE);
if (trc) debse8(ISE);
#endif
for (tki.Init(); tki.More(); tki.Next()) {
TopOpeBRepDS_Kind KK; Standard_Integer GG; const TopOpeBRepDS_ListOfInterference& loi = tki.Value(KK,GG);
Standard_Boolean isvertex = (KK == TopOpeBRepDS_VERTEX);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean ispoint = (KK == TopOpeBRepDS_POINT);
#endif
if (isvertex) {
TopOpeBRepDS_ListOfInterference li; FDS_assign(loi,li);
TopOpeBRepDS_ListOfInterference l1dE; Standard_Integer n1d = FUN_selectTRASHAinterference(li,TopAbs_EDGE,l1dE); // li->l1dE+li(<=>lF?)
TopOpeBRepDS_ListOfInterference lFE;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nFE =
#endif
FUN_selectSKinterference(li,TopOpeBRepDS_EDGE,lFE); // li(<=>lF?)->lFE+li(<=>lFF)
TopOpeBRepDS_ListOfInterference l2dFE; Standard_Integer n2d = FUN_selectpure2dI(li,lFE,l2dFE); // lFE->l2dFE+lFE(<=>l3dFE)
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer n3d = lFE.Extent();
#endif
TopOpeBRepDS_Transition newT2d; Standard_Boolean ok = FUN_ds_redu2d1d(BDS,ISE,I2dFE,l1dE, newT2d);
if (!ok) {it.Next(); continue;}
I2dFE->ChangeTransition() = newT2d; al2dFE.Append(I2dFE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"SE8 -> on SE"<<ISE<<" reducedI :";I2dFE->Dump(cout);cout<<endl;}
#endif
l2dFE.Remove(it);
const TopoDS_Edge& SE = BDS.SectionEdge(i);
Standard_Integer rkSE = BDS.AncestorRank(SE);
Standard_Integer ISE = BDS.Shape(SE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSPSX(ISE);
if (trc) debse9(ISE);
#endif
TopOpeBRepDS_ListOfInterference LIcopy; FDS_assign(LI,LIcopy);
TopOpeBRepDS_ListOfInterference LISE;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nise =
#endif
FUN_selectSIinterference(LIcopy,ISE,LISE);
Standard_Integer G;
// const TopOpeBRepDS_ListOfInterference& loi =
tki.Value(K,G);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// const Handle(TopOpeBRepDS_Interference)& I = loi.First();
// TopAbs_Orientation O = I->Transition().Orientation(TopAbs_IN);
#endif
Standard_Real par = BRep_Tool::Parameter(vG,SE);
Handle(TopOpeBRepDS_Interference) newI = MakeEPVInterference(newT,iEsd,G,par,TopOpeBRepDS_VERTEX,TopOpeBRepDS_EDGE,Standard_True);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"completeforSE6 on section edge "<<ISE<<" ";newI->Dump(cout);cout<<endl;}
#endif
HDS->StoreInterference(newI,SE);
if (BDS.Shape(i).ShapeType() != TopAbs_EDGE) continue;
const TopoDS_Edge& E = TopoDS::Edge(BDS.Shape(i));
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean isse = BDS.IsSectionEdge(E);
// Standard_Integer rkE = BDS.AncestorRank(E);
#endif
Standard_Integer IE = BDS.Shape(E);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSPSX(IE);
if (trc) debsamsha(IE);
#endif
TopOpeBRepDS_Kind K; Standard_Integer G; const TopOpeBRepDS_ListOfInterference& loi = tki.Value(K,G);
TopOpeBRepDS_ListOfInterference loicopy; FDS_copy(loi,loicopy); // loi -> l1+l2
TopOpeBRepDS_ListOfInterference l0;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer n0 =
#endif
FUN_selectTRASHAinterference(loicopy,TopAbs_EDGE,l0);//xpu091198(cylcong)
else break;
} //it1(li)
if (newI.IsNull()) continue;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"redusamsha se"<<IE<<"FORWARD/REVERSED ->";newI->Dump(cout);cout<<endl;}
#endif
li.Clear(); li.Append(newI);
TopOpeBRepDS_DataStructure& BDS = HDS->ChangeDS();
Standard_Integer ns = BDS.NbShapes();
for (Standard_Integer i = 1; i <= ns; i++) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSPSX(i);
if (trc) debgb1(i);
#endif
newloi.Append(I);
continue;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"unkeepEVIonGb1 on e"<<i<<" ";I->Dump(cout);cout<<endl;}
#endif
}
Standard_EXPORT Standard_Boolean FDS_LOIinfsup(
const TopOpeBRepDS_DataStructure&
-#ifdef DEB
+#ifdef OCCT_DEBUG
BDS
#endif
,const TopoDS_Edge& E,
Standard_Real& paft,
Standard_Boolean& isonboundper)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer EIX = BDS.Shape(E);
Standard_Boolean TRC=DSREDUEDGETRCE(EIX);
TRC = Standard_False; // xpu170898
TopOpeBRepDS_ListOfInterference LOIsansGDS;
TopOpeBRepDS_TKI tki; tki.FillOnGeometry(LOI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout<<endl<<"FDS_LOIinfsup E"<<EIX<<" tki"<<endl;
if (TRC) tki.DumpTKIIterator("","\n");
if (TRC) debredpvg(EIX);
Standard_Boolean mk = (K == KDS); Standard_Boolean mg = (G == GDS);
Standard_Boolean mkg = (mk && mg); if ( mkg ) continue;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) {tki.DumpTKI(K,G,"","\n");debredpvg(EIX);}
#endif
TopOpeBRepDS_ListOfInterference& loi = tki.ChangeValue(K,G);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer nloi = loi.Extent();
#endif
for (TopOpeBRepDS_ListIteratorOfListOfInterference it(loi);it.More();it.Next()) {
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout<<endl<<"FDS_LOIinfsup.2 E"<<EIX<<" : "<<LOIsansGDS.Extent()<<endl;
if (TRC) debredpvg(EIX);
#endif
const TopoDS_Shape& F = BDS.Shape(I);
if (F. ShapeType() != TopAbs_FACE) continue;
const TopOpeBRepDS_ListOfInterference& LI = BDS.ShapeInterferences(F);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSPSX(I);
if (trc) debgb1(I);
#endif
if (!ok) {it.Next(); continue;}
if (conf == DIFFORIENTED) newO = TopAbs::Complement(newO);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"**FUN_ds_FEIGb1TO0 : IGb1";IGb1->Dump(cout);cout<<" ->";}
#endif
newT.Set(newO);
IGb1->SetGeometry(Gsd); IGb1->SetGBound(Standard_False); IGb1->Transition(newT);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {IGb1->Dump(cout);cout<<endl;}
#endif
LGb0.Append(IGb1); LGb1.Remove(it);
static void FUN_Raise()
{
Standard_ProgramError::Raise("Edge3dInterferenceTool");
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout <<" ************** Failure in Edge3dInterferenceTool"<<endl;
#endif
}
Standard_Real tol1 = BRep_Tool::Tolerance(OOE);
Standard_Real tol2 = tol1*1.e3;
Standard_Real tol = tol2; if (tol > 1.e-2) tol = 1.e-2;
-#ifdef DEBDEB
+#ifdef OCCT_DEBUG
cout<<"$$$$$$$$$$$$$$$$$$$$$$$$ FUN_paronOOE : dist "<<dist<<" tol1 "<<tol1<<endl;
cout<<"$$$$$$$$$$$$$$$$$$$$$$$$ FUN_paronOOE : dist "<<dist<<" tol "<<tol<<endl;
#endif
#include <TopOpeBRepTool_ShapeTool.hxx>
#include <Standard_ProgramError.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_EXPORT Standard_Boolean TopOpeBRepDS_GettracePEI();
#endif
else if ( I->IsKind(STANDARD_TYPE(TopOpeBRepDS_CurvePointInterference)) )
p = Handle(TopOpeBRepDS_CurvePointInterference)::DownCast(I)->Parameter();
else {
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"EdgeInterference : mauvais type d'interference"<<endl;
#endif
Standard_ProgramError::Raise("TopOpeBRepDS_EdgeInterferenceTool1");
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettracePEI() && !VofE) {
cout<<"===================== VofE = False"<<endl;
}
Standard_OStream& TopOpeBRepDS_EdgeVertexInterference::Dump
(Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OS<<"EVI"<<" ";
TopOpeBRepDS_ShapeShapeInterference::Dump(OS);
OS<<" "<<myParam<<" ";
#define MDSke TopOpeBRepDS_EDGE
#define MDSkf TopOpeBRepDS_FACE
-#ifdef DEB
+#ifdef OCCT_DEBUG
void debrededg(const Standard_Integer I) {cout<<"+++ debrededg f"<<I<<endl;}
void debredfac(const Standard_Integer I) {cout<<"+++ debredfac f"<<I<<endl;}
void FUN_dumploiS(const TopoDS_Shape& SG,const TopOpeBRepDS_ListOfInterference& loi,const TopOpeBRepDS_DataStructure& BDS,TCollection_AsciiString str)
}
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceSTRANGE();
extern Standard_Boolean TopOpeBRepDS_GettracePEI();
extern Standard_Boolean TopOpeBRepDS_GettracePFI();
// --------------------------------------------------------
static void FDS_DUMPTRANSITION(const Standard_Boolean
-#ifdef DEB
+#ifdef OCCT_DEBUG
TRCF
#endif
,const TCollection_AsciiString&
-#ifdef DEB
+#ifdef OCCT_DEBUG
str
#endif
,const Standard_Integer
-#ifdef DEB
+#ifdef OCCT_DEBUG
iFI
#endif
,TopOpeBRepDS_FaceInterferenceTool&
-#ifdef DEB
+#ifdef OCCT_DEBUG
FITool
#endif
)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRCF) {
cout<<str<<iFI<<endl;
Handle(TopOpeBRepDS_Interference) IBID = new TopOpeBRepDS_Interference();
// --------------------------------------------------------
static void FDS_ADDEDGE
(const Standard_Boolean
-#ifdef DEB
+#ifdef OCCT_DEBUG
TRCF
#endif
,const TCollection_AsciiString&
-#ifdef DEB
+#ifdef OCCT_DEBUG
str
#endif
,const Standard_Integer
-#ifdef DEB
+#ifdef OCCT_DEBUG
iFI // DEB args
#endif
,TopOpeBRepDS_FaceInterferenceTool& FITool
,const Handle(TopOpeBRepDS_Interference)& I
)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRCF) {TCollection_AsciiString cr("\n"),s=str+iFI+cr;I->Dump(cout,s,cr);}
#endif
FITool.Add(FI,F,Ecpx,isEGsp,I);
-#ifdef DEB
+#ifdef OCCT_DEBUG
FDS_DUMPTRANSITION(TRCF,"--> resultat partiel sur face ",iFI,FITool);
#endif
}
const TopOpeBRepDS_DataMapOfShapeListOfShapeOn1State& )
{
Standard_Boolean TRCF = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRCE = Standard_False;
TRCE = FTRCE(iEG);if (TRCE) debrededg(iEG);
TRCF = FTRCF(iFI);if (TRCF) debredfac(iFI);
// TopOpeBRepDS_Transition T1 = I1->Transition(); TopAbs_Orientation O1 = T1.Orientation(TopAbs_IN); // xpu :090498
// Standard_Boolean revT1 = toreverse && (M_FORWARD(O1) || M_REVERSED(O1)); // xpu :090498
-#ifdef DEB
+#ifdef OCCT_DEBUG
// if ((TRCE || TRCF) && revT1) cout<<"-> REVERSE T"<<endl;
#endif
// if (revT1) I1->ChangeTransition() = T1.Complement(); //xpu :090498
// TopOpeBRepDS_Transition T2 = I2->Transition(); TopAbs_Orientation O2 = T2.Orientation(TopAbs_IN); // xpu :090498
// Standard_Boolean revT2 = toreverse && (M_FORWARD(O2) || M_REVERSED(O2)); // xpu :090498
-#ifdef DEB
+#ifdef OCCT_DEBUG
// if ((TRCE || TRCF) && revT2) cout<<"-> REVERSE T"<<endl;
#endif
// if (revT2) I2->ChangeTransition() = T2.Complement(); //xpu :090498
TopOpeBRepDS_MapOfShapeData mosd;
FUN_GmapS(LI,BDS,mosd);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC = FTRCF(iFI);
if (TRC) FUN_dumpmosd(mosd,BDS,iFI,"");
if (TRC) debredfac(iFI);
Standard_Boolean egissect = BDS.IsSectionEdge(TopoDS::Edge(EG));
Standard_Boolean eghasesd = (! esdeg.IsEmpty());
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer egiref = BDS.SameDomainRef(iEG);
// Standard_Integer egisref = (iEG == egiref);
// TopOpeBRepDS_Config egc = BDS.SameDomainOri(iEG);
// LIEG = toutes les interferences dont le Support() est une
// face possedant une interference dont la Geometry() est EG.
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) FUN_dumploiS(EG,LIEG,BDS," ");
#endif
{
TopOpeBRepDS_DataStructure& BDS = myHDS->ChangeDS();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC = FTRCF(SIX);
if (TRC) debredfac(SIX);
#endif
// F is the Face, LI is list of interferences to compact
-#ifdef DEB
+#ifdef OCCT_DEBUG
// const TopoDS_Shape& F = BDS.Shape(SIX);
#endif
TopOpeBRepDS_ListOfInterference& LI = BDS.ChangeShapeInterferences(SIX);
TopOpeBRepDS_ListOfInterference lw, lE, lFE, lFEF, lF; lw.Assign(LI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer nF, nFE, nFEF, nE;
#endif
::FUN_selectSKinterference(lFE,MDSkf,lFEF);
::FUN_selectTRASHAinterference(lw,TopAbs_EDGE,lE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
nF = lF.Extent();
nFE = lFE.Extent();
nFEF = lFEF.Extent();
FUN_reduceEDGEgeometry(lFEF,BDS,SIX,MEsp);
-#ifdef DEB
+#ifdef OCCT_DEBUG
nF = lF.Extent();
nFE = lFE.Extent();
nFEF = lFEF.Extent();
Standard_OStream& TopOpeBRepDS_FaceEdgeInterference::Dump
(Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OS<<"FEI ";
TopOpeBRepDS_ShapeShapeInterference::Dump(OS);
#endif
#include <TopOpeBRepTool_TOOL.hxx>
#include <TopOpeBRepDS_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceSTRANGE();
extern Standard_Boolean TopOpeBRepDS_GettracePEI();
extern Standard_Boolean TopOpeBRepDS_GettracePFI();
//------------------------------------------------------
// Unused :
-/*#ifdef DEB
+/*#ifdef OCCT_DEBUG
static Standard_Boolean FUN_Parameters
(const Standard_Real& Param,const TopoDS_Shape& E,const TopoDS_Shape& F,Standard_Real& u,Standard_Real& v)
{
//------------------------------------------------------
//unreferenced function, commented
-/*#ifdef DEB
+/*#ifdef OCCT_DEBUG
static void FUN_middleUV(const TopoDS_Shape& F,Standard_Real& u,Standard_Real& v)
{
Handle(Geom_Surface) su = TopOpeBRepTool_ShapeTool::BASISSURFACE(TopoDS::Face(F));
const Handle(TopOpeBRepDS_ShapeShapeInterference)& I = Handle(TopOpeBRepDS_ShapeShapeInterference)::DownCast(Iin); if (I.IsNull()) return;
const TopoDS_Face& FI = TopoDS::Face(FFI);
const TopoDS_Edge& E = TopoDS::Edge(EE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iFI = myPBDS->Shape(FI);
// Standard_Boolean TRCFI = FTRCF(iFI);if (TRCFI) debredfac(iFI);
#endif
const TopoDS_Face& FI = TopoDS::Face(FFI);
const TopoDS_Face& FT = TopoDS::Face(FFT);
const TopoDS_Edge& E = TopoDS::Edge(EE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iFI =
#endif
myPBDS->Shape(FI);
// myPBDS->Shape(FT);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRCFI = FTRCF(iFI);if (TRCFI) debredfac(iFI);
#endif
return;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
// TopAbs_Orientation FTori = FT.Orientation();
#endif
TopOpeBRepDS_Kind GT,ST; Standard_Integer G,S; FDS_data(I,GT,G,ST,S);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean gisb = I->GBound();
#endif
const TopoDS_Edge& EG = TopoDS::Edge(myPBDS->Shape(G));
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean ghassd3d =
#endif
FDS_HasSameDomain3d(*myPBDS,EG);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer gr = myPBDS->SameDomainRef(G);
// const TopoDS_Edge& ER = TopoDS::Edge(myPBDS->Shape(gr));
// Standard_Integer gisr = (G == gr);
#include <TopOpeBRepDS_ListOfInterference.hxx>
#include <TopOpeBRepDS_ListIteratorOfListOfInterference.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettracePEI();
extern Standard_Boolean TopOpeBRepDS_GettracePI();
extern Standard_Boolean TopOpeBRepDS_GettraceSPSX(const Standard_Integer);
#include <TopOpeBRepDS_ListIteratorOfListOfInterference.hxx>
#include <TopOpeBRepDS_ProcessInterferencesTool.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettracePI();
extern Standard_Boolean TopOpeBRepDS_GettracePCI();
static Standard_Boolean TRCC() {
// do NOT delete CPIREV!!
Standard_Boolean remove = (GT2 == GT1) && (G2 == G1) && (O1 == O2);
if ( remove ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( TRCC() ){
cout<<"remove ";I2->Dump(cout);cout<<" from C "<<CIX<<endl;
}
#include <TopOpeBRepDS_ProcessInterferencesTool.hxx>
#include <TopOpeBRepDS_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettracePEI();
extern Standard_Boolean TopOpeBRepDS_GettracePI();
extern Standard_Boolean TopOpeBRepDS_GettraceSPSX(const Standard_Integer);
{
TopOpeBRepDS_DataStructure& BDS = HDS->ChangeDS();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=TRCE(SIX);
if (TRC) debfilter(SIX);
if (TRC) cout<<"FUN_FilterEdge on "<<SIX<<" nI = "<<LI.Extent()<<endl;
FUN_unkeepEinterferences(LI,BDS,SIX);
FUN_reducedoublons(LI,BDS,SIX);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout<<"FUN_FilterEdge on "<<SIX<<" returns nI = "<<LI.Extent()<<endl;
#endif
{
TopOpeBRepDS_DataStructure& BDS = myHDS->ChangeDS();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=TRCE(SIX);if (TRC) debfilterPEI(SIX);
#endif
FUN_purgeDSonSE(myHDS,SIX,lall);
// xpu : 270398 (pro1260, edge 49,ftrasha 93)
-#ifdef DEB
+#ifdef OCCT_DEBUG
//Standard_Integer nUU =
#endif
::FUN_selectTRAUNKinterference(lall,lUU);
lw.Append(lall);
lw.Append(lUU);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer nF =
#endif
::FUN_selectTRASHAinterference(lw,TopAbs_FACE,lF);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer nE =
#endif
::FUN_selectTRASHAinterference(lw,TopAbs_EDGE,lE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC){
if(nE||nF){cout<<endl;cout<<"-----------------------"<<endl;}
if(nF){cout<<"EDGE "<<SIX<<" (FACE) : "<<nF<<endl;::FDS_dumpLI(lF," ");}
}
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout <<" on lF :"<<endl;
#endif
::FUN_FilterEdge(lF,myHDS,SIX);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout <<" on lF :"<<endl;
#endif
// ::FUN_unkeepEsymetrictransitions(lF,BDS,SIX);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout <<" on lE :"<<endl;
#endif
::FUN_FilterEdge(lE,myHDS,SIX);
LI.Append(lF);
LI.Append(lE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) {
cout<<"Filter::ProcessEdgeInterferences on "<<SIX;
cout<<" returns nlF = "<<nF<<" nlE = "<<nE<<endl;
#include <TopOpeBRepDS_ListOfShapeOn1State.hxx>
#include <TopOpeBRepDS_DataMapOfShapeListOfShapeOn1State.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GetcontextNOPFI();
extern Standard_Boolean TopOpeBRepDS_GettracePFI();
extern Standard_Boolean TopOpeBRepDS_GettracePI();
const TopOpeBRepDS_DataMapOfShapeListOfShapeOn1State& MEsp,
TopOpeBRepTool_PShapeClassifier pClassif);
-#ifdef DEB
+#ifdef OCCT_DEBUG
void debfilfac(const Standard_Integer I) {cout<<"+ + + + debfilfac "<<I<<endl;}
void debpfi(const Standard_Integer I) {cout<<"+ + + + debpfi "<<I<<endl;}
#endif
// -------------------------------------------------------
void FUN_FilterFace
// -------------------------------------------------------
-#ifdef DEB
+#ifdef OCCT_DEBUG
(TopOpeBRepDS_ListOfInterference& LI,const TopOpeBRepDS_DataStructure& /*BDS*/,const Standard_Integer SIX)
#else
(TopOpeBRepDS_ListOfInterference& ,const TopOpeBRepDS_DataStructure& ,const Standard_Integer )
#endif
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=TRCF(SIX);
Standard_Integer nI = 0;
if (TRC) debfilfac(SIX);
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
nI = LI.Extent();
if (TRC) cout <<"before FUN_FilterFace on "<<SIX<<" nI = "<<nI<<endl;
#endif
// ::FUN_unkeepFdoubleGBoundinterferences(LI,BDS,SIX);
-#ifdef DEB
+#ifdef OCCT_DEBUG
nI = LI.Extent();
if (TRC) cout <<"after unkeepFinterferences nI = "<<nI<<endl;
#endif
{
TopOpeBRepDS_DataStructure& BDS = myHDS->ChangeDS();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=TRCF(SIX);
Standard_Integer nI = 0;
if (TRC) debpfi(SIX);
TopOpeBRepDS_ListOfInterference& LI = BDS.ChangeShapeInterferences(SIX);
::FUN_reducedoublons(LI,BDS,SIX);
-#ifdef DEB
+#ifdef OCCT_DEBUG
nI = LI.Extent();
if (TRC) cout <<"after reducedoublons nI = "<<nI<<endl;
#endif
TopOpeBRepDS_ListOfInterference lw, lE, lFE, lFEF, lF, lUU, lall; lall.Assign(LI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer nUU =
#endif
::FUN_selectTRAUNKinterference(lall,lUU);
lw.Append(lall);
lw.Append(lUU);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer nF, nFE, nFEF, nE;
#endif
::FUN_selectSKinterference(lFE,TopOpeBRepDS_FACE,lFEF);
::FUN_selectTRASHAinterference(lw,TopAbs_EDGE,lE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
nF = lF.Extent();
nFE = lFE.Extent();
nFEF = lFEF.Extent();
::FUN_FilterFace(lFEF,BDS,SIX);
-#ifdef DEB
+#ifdef OCCT_DEBUG
nF = lF.Extent();
nFE = lFE.Extent();
nFEF = lFEF.Extent();
#include <Geom2d_Curve.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceGAP();
extern Standard_Boolean TopOpeBRepDS_GetcontextNOGAP();
#endif
void TopOpeBRepDS_GapFiller::Perform()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GetcontextNOGAP () != 0) return;
#endif
if (myAsso->HasAssociation(itSI.Value())) return;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceGAP() == 1) {
cout<<endl;
cout<<"-----------------------------------------------------"<<endl;
LI.Append(I);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceGAP() != 0) {
TopOpeBRepDS_ListIteratorOfListOfInterference it(LI);
for (it.Initialize(LI); it.More(); it.Next()) {
LI.Clear();
if (!ISol.IsNull()) {
LI.Append(ISol);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceGAP() == 1){
cout << " Distance Minimum :"<<DistMin<<endl;
}
//=======================================================================
//unreferenced function, commented
/*
-#ifdef DEB
+#ifdef OCCT_DEBUG
static void BuildNewPoint (const TColgp_SequenceOfPnt& LP,
const Standard_Real& TolMax,
TopOpeBRepDS_Point& Point)
TopOpeBRepDS_ListOfInterference& LI = myAsso->Associated(I);
TopOpeBRepDS_ListIteratorOfListOfInterference it(LI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceGAP() == 1) {
cout <<"Points ";
for (it.Initialize(LI); it.More(); it.Next()) {
}
myGapTool->EdgeSupport(it.Value(),CE);
if (!CE.IsSame(E)) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceGAP() == 1){
cout <<"GapFiller : points pas sur la meme edge -> cas non traite"<<endl;
}
// Mise a jour.
Standard_Integer IP = myHDS->ChangeDS().AddPoint(P);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceGAP() == 1) {
cout <<" New Point : "<<IP<<endl;
}
#include <Standard_OutOfRange.hxx>
#include <TopOpeBRepDS_CurvePointInterference.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceGAP();
#endif
}
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepDS_GettraceGAP()) {
cout <<"TopOpeBRepDS_GapTool::Curve Point "<<I->Geometry()<<" -> Pas sur Courbe "<<endl;
}
#include <Standard_ProgramError.hxx>
#include <TopOpeBRepDS_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceISTO();
extern Standard_Boolean TopOpeBRepDS_GettraceEDSF();
extern Standard_Boolean TopOpeBRepDS_GettraceDSF();
return found;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettraceSTRANGE();
extern Standard_Boolean TopOpeBRepDS_GettraceSPSX(const Standard_Integer);
static Standard_Boolean TRC(const Standard_Integer SIX) {
//=======================================================================
void TopOpeBRepDS_HDataStructure::StoreInterference
(const Handle(TopOpeBRepDS_Interference)& I,TopOpeBRepDS_ListOfInterference& LI,
-#ifdef DEB
+#ifdef OCCT_DEBUG
const TCollection_AsciiString& str)
#else
const TCollection_AsciiString& )
#endif
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
const TopOpeBRepDS_Transition& T = I->Transition();
TopAbs_ShapeEnum sb = T.ShapeBefore();
// append I to list LI
LI.Append(I);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean appendtoG = Standard_False;
#endif
Standard_Integer G = I->Geometry();
break;
case TopOpeBRepDS_SURFACE :
-#ifdef DEB
+#ifdef OCCT_DEBUG
appendtoG = Standard_True;
#endif
myDS.ChangeSurfaceInterferences(G).Append(I);
break;
case TopOpeBRepDS_CURVE :
-#ifdef DEB
+#ifdef OCCT_DEBUG
appendtoG = Standard_True;
#endif
myDS.ChangeCurveInterferences(G).Append(I);
break;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = ::traceSTORE();
if (trc) {
cout<<str<<"append "; I->Dump(cout);
//=======================================================================
void TopOpeBRepDS_HDataStructure::StoreInterference
(const Handle(TopOpeBRepDS_Interference)& I,const TopoDS_Shape& S,
-#ifdef DEB
+#ifdef OCCT_DEBUG
const TCollection_AsciiString& str)
#else
const TCollection_AsciiString& )
return;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = ::traceSTORE();
TopOpeBRepDS_Kind ks = TopOpeBRepDS::ShapeToKind(S.ShapeType());
Standard_Integer is = myDS.Shape(S);
void TopOpeBRepDS_HDataStructure::StoreInterference
(const Handle(TopOpeBRepDS_Interference)& I,
const Standard_Integer IS,
-#ifdef DEB
+#ifdef OCCT_DEBUG
const TCollection_AsciiString& str)
#else
const TCollection_AsciiString& )
return;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = ::traceSTORE();
const TopoDS_Shape& S = Shape(IS);
TopOpeBRepDS_Kind ks = TopOpeBRepDS::ShapeToKind(S.ShapeType());
Standard_OStream& TopOpeBRepDS_Interference::DumpS(Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopOpeBRepDS::Print(mySupportType,mySupport,OS,"S=","");
OS.flush();
#endif
Standard_OStream& TopOpeBRepDS_Interference::DumpG(Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopOpeBRepDS::Print(myGeometryType,myGeometry,OS,"G=","");
#endif
return OS;
Standard_OStream& TopOpeBRepDS_Interference::Dump
(Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
myTransition.Dump(OS); OS<<" "; DumpG(OS); OS<<" on "; DumpS(OS);
#endif
return OS;
//function : Dump
//purpose :
//=======================================================================
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_OStream& TopOpeBRepDS_Interference::Dump
(Standard_OStream& OS,
const TCollection_AsciiString& s1,
Standard_Real TopOpeBRepDS_PointIterator::Parameter()const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// cout<<"PointIterator : I = "; Value()->Dump(cout); cout<<endl;
#endif
#include <TopOpeBRepDS_connex.hxx>
#include <TopOpeBRepTool_SC.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettracePEI();
extern Standard_Boolean TopOpeBRepDS_GettracePI();
extern Standard_Boolean TopOpeBRepDS_GettraceSPSX(const Standard_Integer);
// EVI rejetee si OUT FACE before et after
// et si le vertex-geometrie de l'interference collisionne avec
// un des vertex de l'arete (E) accedant l'interference (I)
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean k4I = (((shab == TopAbs_FACE) && (stab == TopAbs_OUT)) &&
// ((shaa == TopAbs_FACE) && (staa == TopAbs_OUT)));
#endif
else if ( Vsd.IsSame(Vr) ) { break; }
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean k4 = ! ( k4I && k4C );
#endif
// res = res && k4;
//------------------------------------------------------
(TopOpeBRepDS_ListOfInterference& LI,const TopOpeBRepDS_DataStructure& BDS,const Standard_Integer SIX)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=TRCE(SIX);
#endif
Standard_Boolean isEd;
isEd = BRep_Tool::Degenerated(TopoDS::Edge(E));
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) {cout<<"FUN_unkeepEinterferences on "<<SIX<<" nI = "<<LI.Extent()<<endl;}
#endif
Standard_Boolean k1 = ::FUN_keepEinterference(BDS,I1,E);
if ( !k1 ) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC) {cout<<endl<<"rejet d'interference "<<SIX<<endl;I1->Dump(cout);cout<<endl;}
#endif
}
Standard_Integer n = LI.Extent();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout<<"FUN_unkeepEinterferences on "<<SIX<<" returns nI = "<<n<<endl;
#endif
//------------------------------------------------------
(TopOpeBRepDS_ListOfInterference& LF,const TopOpeBRepDS_ListOfInterference& LE,const TopOpeBRepDS_DataStructure& BDS,const Standard_Integer SIX)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=TRCE(SIX);
if (TRC) cout<<"FUN_changeFOUT on "<<SIX<<" nI = "<<LE.Extent()<<endl;
#endif
}
it1.Next();
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout<<" FUN_changeFOUT on "<<SIX<<"returns nI = "<<LE.Extent()<<endl;
#endif
// incidentes en un vertex. (cas d'un shell fait de deux faces partageant une arete.)
(TopOpeBRepDS_ListOfInterference& LI,const TopOpeBRepDS_DataStructure& BDS,const Standard_Integer SIX)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=TRCE(SIX);
#endif
Standard_Boolean isEd;
isEd = BRep_Tool::Degenerated(TopoDS::Edge(E));
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) {
cout<<"FUN_unkeepEsymetrictransitions on "<<SIX<<" nI = "<<LI.Extent()<<endl;
::FDS_dumpLI(LI,"debut : ");
else sym = idshape && !idstate;
if ( sym ) { // les 2 interferences ne different que leurs etats (symetriques)
-#ifdef DEB
+#ifdef OCCT_DEBUG
// cout<<"TopOpeBRepDS FUN_unkeepEsymetrictransitions on edge "<<SIX<<endl;
if(TRC){
cout<<"edge "<<SIX<<" : symetrique ";I1->Dump(cout);cout<<endl;
}
} // it1.More()
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC) {
::FDS_dumpLI(LI,"apres elim. des sym. : ");
cout<<"FUN_unkeepEsymetrictransitions on "<<SIX<<" returns nI = "<<LI.Extent()<<endl;
#endif
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
void deborderFF(const Standard_Integer) {};
void deborderFF1(const Standard_Integer) {};
void deborderFF2(const Standard_Integer) {};
// L = L1 + L2;
(TopOpeBRepDS_ListOfInterference& LI,
const Handle(TopOpeBRepDS_HDataStructure)& HDS,
-#ifdef DEB
+#ifdef OCCT_DEBUG
const Standard_Integer SIX)
#else
const Standard_Integer )
#endif
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=TRCE(SIX);
if (TRC) deborderFF(SIX);
Standard_Boolean modif = Standard_False;
TopAbs_ShapeEnum tsb1,tsa1; Standard_Integer isb1,isa1; FDS_Tdata(I1,tsb1,isb1,tsa1,isa1);
// I1->Transition();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) deborderFF1(SIX);
#endif
LI.Append(LIffsd);
LI.Append(LIother);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC && modif){ FDS_dumpLI(LI,"apres groupage fsd : "); }
#endif
} // FUN_orderFFsamedomain
-#ifdef DEB
+#ifdef OCCT_DEBUG
void deborderSTATETRANS(const Standard_Integer) {};
#endif
// L2/ = les autres interfs
// L = L1 + L2;
(TopOpeBRepDS_ListOfInterference& LI,const Handle(TopOpeBRepDS_HDataStructure)& /*HDS*/,
-#ifdef DEB
+#ifdef OCCT_DEBUG
const Standard_Integer SIX)
#else
const Standard_Integer)
#endif
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=TRCE(SIX);
if (TRC) deborderSTATETRANS(SIX);
Standard_Boolean modif = Standard_False;
LI.Clear();
LI.Append(L1);
LI.Append(L2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC && modif){ FDS_dumpLI(LI,"apres groupage STATETRANS : "); }
#endif
} // FUN_orderSTATETRANSonG
// L = L1 + L2;
(TopOpeBRepDS_ListOfInterference& LI,const Handle(TopOpeBRepDS_HDataStructure)& HDS,const Standard_Integer SIX)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=TRCE(SIX);
if (TRC) deborderSTATETRANS(SIX);
#endif
//------------------------------------------------------
(TopOpeBRepDS_ListOfInterference& LI,TopOpeBRepDS_DataStructure& BDS,const Standard_Integer SIX)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=TRCE(SIX); if (TRC) debredunke(SIX);
Standard_Boolean modif = Standard_False;
#endif
Standard_Boolean isunk = T1.IsUnknown();
if (!isunk) continue;
-#ifdef DEB
+#ifdef OCCT_DEBUG
modif = Standard_True;
if(TRC){debredunke(SIX);TCollection_AsciiString s="E";s=s+SIX+" T UNKNOWN ";I1->Dump(cout,s,"\n");}
#endif
Standard_Boolean etgf = idt && idi; // edge tangent a une face en 1 point
if (!etgf) continue;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC){debredunke(SIX);TCollection_AsciiString s="E";s=s+SIX+" etgf ";I1->Dump(cout,s,"\n");}
#endif
TopOpeBRepDS_Transition& newT1 = I1->ChangeTransition();
newT1.Set(stateb,statea,tsb1,tsa1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC){debredunke(SIX);TCollection_AsciiString s="E";s=s+SIX+" T corrected ";I1->Dump(cout,s,"\n");}
#endif
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC && modif){ FDS_dumpLI(LI,"apres correction UNKNOWN : "); }
#endif
FUN_unkeepUNKNOWN(LI,BDS,SIX);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC && modif){ FDS_dumpLI(LI,"sans suppression UNKNOWN residuels : "); }
#endif
}
Standard_EXPORT void FUN_purgeDSonSE(const Handle(TopOpeBRepDS_HDataStructure)& HDS,const Standard_Integer EIX,TopOpeBRepDS_ListOfInterference& LI)
// ----------------------------------------------------------------------
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepDS_GettraceSPSX(EIX);
if (trc) {cout<<endl<<"FUN_purgeDSonSE on "<<EIX<<" nI = "<<LI.Extent()<<endl;}
#endif
Standard_Boolean isse = BDS.IsSectionEdge(SE);
if (!isse) return;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) debpurse(EIX);
#endif
for (tki.Init(); tki.More(); tki.Next()) {
TopOpeBRepDS_Kind Kcur; Standard_Integer Gcur; TopOpeBRepDS_ListOfInterference& loi = tki.ChangeValue(Kcur,Gcur);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean hasfsdmFanc = Standard_False;
#endif
TopOpeBRepDS_ListIteratorOfListOfInterference it(loi);
else newLI.Append(I);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc)
for (TopOpeBRepDS_ListIteratorOfListOfInterference itt(LIface); itt.More(); itt.Next())
{cout<<"rejet d'interference "<<EIX<<" ";itt.Value()->Dump(cout);cout<<endl;}
LI.Clear();
LI.Append(newLI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<"FUN_purgeDSonSE on "<<EIX<<" returns nI = "<<LI.Extent()<<endl;
#endif
}
#define MDShfei Handle(TopOpeBRepDS_FaceEdgeInterference)
#define MAKEFEI(IJKLM) (Handle(TopOpeBRepDS_FaceEdgeInterference)::DownCast(IJKLM))
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GetcontextNOPFI();
extern Standard_Boolean TopOpeBRepDS_GettracePFI();
extern Standard_Boolean TopOpeBRepDS_GettracePI();
Standard_EXPORT void FUN_unkeepFdoubleGBoundinterferences
//------------------------------------------------------
(TopOpeBRepDS_ListOfInterference& LI,const TopOpeBRepDS_DataStructure& /*BDS*/,
-#ifdef DEB
+#ifdef OCCT_DEBUG
const Standard_Integer SIX)
#else
const Standard_Integer )
#endif
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=TRCF(SIX);
#endif
// BDS.Shape(SIX);
isB1 && isB2);
if (cond2) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC){cout<<"face "<<SIX<<" : G2 "<< G2 <<" GBound ";I2->Dump(cout);cout<<endl;}
#endif
cond1 = Standard_True;
} // it2.More()
if (cond1) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC){cout<<"face "<<SIX<<" : G1 "<< G1 <<" GBound ";I1->Dump(cout);cout<<endl;}
#endif
LI.Remove(it1);
const TopOpeBRepDS_DataMapOfShapeListOfShapeOn1State& MEsp,
TopOpeBRepTool_PShapeClassifier pClassif)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=TRCF(SIX); if (TRC) debredunkf(SIX);
Standard_Boolean modif = Standard_False;
#endif
Standard_Boolean isunk = T1.IsUnknown();
if (!isunk) continue;
-#ifdef DEB
+#ifdef OCCT_DEBUG
modif = Standard_True;
if(TRC){debredunkf(SIX);TCollection_AsciiString s="F";s=s+SIX+" T UNKNOWN ";I1->Dump(cout,s,"\n");}
#endif
const TopoDS_Edge& EE = TopoDS::Edge(BDS.Shape(G1));
Standard_Real fE,lE; BRep_Tool::Range(EE,fE,lE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC){debredunkf(SIX);TCollection_AsciiString s="F";s=s+SIX+" etgf ";I1->Dump(cout,s,"\n");}
#endif
}
newT1.Set(stateb,statea,tsb1,tsa1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC){debredunkf(SIX);TCollection_AsciiString s="F";s=s+SIX+" T corrected ";I1->Dump(cout,s,"\n");}
#endif
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC && modif){ FDS_dumpLI(LI,"apres correction UNKNOWN : "); }
#endif
FUN_unkeepUNKNOWN(LI,BDS,SIX);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC && modif){ FDS_dumpLI(LI,"sans suppression UNKNOWN residuels : "); }
#endif
}
//========================== DEB start
-#ifdef DEB
+#ifdef OCCT_DEBUG
//Standard_IMPORT void FUN_ComputeGeomData(const TopoDS_Shape& F,const Standard_Real& u,const Standard_Real& v,gp_Dir& Norm);
//------------------------------------------------------
// Automatic testing for complex faces interference on line with cylinders and planes xpu NYI: general case
cout<<" not treated : prendre un point sur le common des aretes de section SDM"<<endl;
return Standard_True;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
// FUN_ComputeGeomData (F, u, v, normS);
#endif
normS = FUN_tool_nggeomF(gp_Pnt2d(u,v), F);
#include <TopOpeBRepTool_EXPORT.hxx>
#include <TopOpeBRepDS_EXPORT.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepDS_GettracePEI();
extern Standard_Boolean TopOpeBRepDS_GettracePI();
extern Standard_Boolean TopOpeBRepDS_GettraceSPSX(const Standard_Integer);
//------------------------------------------------------
(TopOpeBRepDS_ListOfInterference& LI,const TopOpeBRepDS_DataStructure& BDS,const Standard_Integer SIX)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=TRCE(SIX); if (TRC) debredudoub(SIX);
Standard_Boolean modif = Standard_False;
#endif
TopAbs_ShapeEnum tsb1,tsa1; Standard_Integer isb1,isa1;
FDS_Tdata(I1,tsb1,isb1,tsa1,isa1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) debredudoub1(SIX);
#endif
TopAbs_ShapeEnum tsb2,tsa2; Standard_Integer isb2,isa2;
FDS_Tdata(I2,tsb2,isb2,tsa2,isa2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) debredudoub2(SIX);
#endif
}
if (idT) {
// les 2 interferences I1 et I2 sont identiques : on supprime I2
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC){cout<<"shape "<<SIX<<" : doublon ";I1->Dump(cout);cout<<endl;}
modif = Standard_True;
#endif
it1.Next();
} // it1.More()
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC && !modif){ FDS_dumpLI(LI,"sans doublon : "); }
#endif
} // reducedoublons
//------------------------------------------------------
(TopOpeBRepDS_ListOfInterference& LI,
TopOpeBRepDS_DataStructure& /*BDS*/,
-#ifdef DEB
+#ifdef OCCT_DEBUG
const Standard_Integer SIX)
#else
const Standard_Integer)
#endif
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=TRCE(SIX); if (TRC) debredunk(SIX);
Standard_Boolean modif = Standard_False;
#endif
Standard_Boolean isunk = T1.IsUnknown();
if (isunk) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC) {
if (isunk) debredunk(SIX);
cout<<"shape "<<SIX<<" : UNKNOWN transition ";I1->Dump(cout);cout<<endl;
else it1.Next();
} // it1.More()
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC && !modif){ FDS_dumpLI(LI,"sans UNKNOWN : "); }
#endif
} // unkeepUNKNOWN
l3dFE.Clear();
lFEresi.Clear();
Standard_Integer n3d = 0;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=TRCE(SIX);
#endif
if (!BDS.HasShape(Eshared))
{Standard_Integer OOrank = BDS.AncestorRank(OOv); BDS.AddShape(Eshared,OOrank);}
S1 = BDS.Shape(Eshared); S2 = S1;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) {cout<<" finding out E shared by F"<<IB1<<" and F"<<IB2;
cout<<" new support is E"<<S1<<endl;}
#endif
if (sameSorsharedEbyTRASHA) { // xpu : 09-03-98
Standard_Boolean sdm = FUN_ds_sdm(BDS,BDS.Shape(SIX),BDS.Shape(S1));
if (sdm) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout<<" NO I3d : e"<<SIX<<" same domain with e"<<S1<<endl;
#endif
it2.Next(); continue;
TColStd_MapOfInteger mapftra;
TopOpeBRepDS_ListOfInterference lIE; FDS_copy(BDS.ShapeInterferences(SIX),lIE);
TopOpeBRepDS_ListOfInterference l3dF;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer n3d =
#endif
FUN_selectSKinterference(lIE,TopOpeBRepDS_FACE,l3dF);
// I = (T(face),G=POINT/VERTEX,S=EDGE) in <l3dFE>
// <-> I' = (T(face),G=POINT/VERTEX,S=FACE) in <l3dF>
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer n3dFE =
#endif
::FUN_select3dI(SIX,BDS,lFE,lFEresi,l3dFE);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer n3dFF =
#endif
::FUN_select3dISEsameISF(lFE,l3dFE,l3dFEresi,lF,l3dF);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer n2dFE =
#endif
FUN_select2dI(SIX,BDS,TopAbs_FACE,lFE,l2dFE);
Standard_OStream& TopOpeBRepDS_ShapeShapeInterference::Dump
(Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OS<<"("; TopOpeBRepDS::Print(myC,OS); OS<<")"<<" ";
if (myGBound) OS<<"(Gb 1) ";
else OS<<"(Gb 0) ";
Standard_OStream& TopOpeBRepDS_SolidSurfaceInterference::Dump
(Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OS<<"SSI ";TopOpeBRepDS_Interference::Dump(OS);
#endif
return OS;
#include <TopOpeBRepDS_SurfaceCurveInterference.ixx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopOpeBRepDS_Dumper.hxx>
#endif
Standard_OStream& TopOpeBRepDS_SurfaceCurveInterference::DumpPCurve
(Standard_OStream& OS,
-#ifdef DEB
+#ifdef OCCT_DEBUG
const Standard_Boolean compact
#else
const Standard_Boolean
#endif
)const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Dump(OS); OS<<endl;
OS<<"PCurve ";
Standard_OStream& TopOpeBRepDS_SurfaceCurveInterference::Dump
(Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OS<<"SCI ";TopOpeBRepDS_Dumper::PrintType(myPCurve,OS);OS<<" ";
TopOpeBRepDS_Interference::Dump(OS);
#endif
static void FUN_Raise()
{
-#ifdef TOPOPEBREPDS_DEB
+#ifdef OCCT_DEBUG
cout<<"****************************** TopOpeBRepDS_TOOL"<<endl;
#endif
}
TopTools_MapOfShape mapesd;
TopOpeBRepDS_ListOfInterference l1gb0,l1gb1,l1gbsd; FDS_sortGb(HDS,L1d,l1gb0,l1gb1,l1gbsd);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer ngb0 = l1gb0.Extent();
// Standard_Integer ngb1 = l1gb1.Extent();
// Standard_Integer ngbsd = l1gbsd.Extent();
//=======================================================================
Standard_OStream& TopOpeBRepDS_Transition::DumpB(Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopOpeBRepDS::Print(myStateBefore,OS);
TopOpeBRepDS::Print(TopOpeBRepDS::ShapeToKind(myShapeBefore),myIndexBefore,OS);
#endif
//=======================================================================
Standard_OStream& TopOpeBRepDS_Transition::DumpA(Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopOpeBRepDS::Print(myStateAfter,OS);
TopOpeBRepDS::Print(TopOpeBRepDS::ShapeToKind(myShapeAfter),myIndexAfter,OS);
#endif
//=======================================================================
Standard_OStream& TopOpeBRepDS_Transition::Dump(Standard_OStream& OS) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
OS<<"("; DumpB(OS); OS<<","; DumpA(OS); OS<<")";
#endif
return OS;
Standard_EXPORT void FDSCNX_FaceEdgeConnexFaces(const TopoDS_Shape& F,const TopoDS_Shape& E,const Handle(TopOpeBRepDS_HDataStructure)& HDS,TopTools_ListOfShape& LF)
{
LF.Clear();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer Fi =
#endif
// HDS->Shape(F);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer Ei =
#endif
// HDS->Shape(E);
const TopTools_ListOfShape& lof = FDSCNX_EdgeConnexitySameShape(E,HDS); if (lof.IsEmpty()) return;
for (TopTools_ListIteratorOfListOfShape it(lof);it.More();it.Next()) {
const TopoDS_Shape& f = it.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer fi =
#endif
// HDS->Shape(f);
if (I<1 || I>ns) return;
Standard_Integer i=I;
const TopoDS_Shape& s=BDS.Shape(i);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer is=
#endif
// BDS.Shape(s);
TopTools_ListIteratorOfListOfShape ils(ls);if(!ils.More())return;
for(;ils.More();ils.Next()) {
const TopoDS_Shape& e=ils.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer ie=BDS.Shape(e);
// TopAbs_ShapeEnum te=e.ShapeType();
#endif
TopTools_ListIteratorOfListOfShape ils(ls);if(!ils.More())return;
for(;ils.More();ils.Next()) {
const TopoDS_Shape& e=ils.Value();Standard_Integer ie=BDS.Shape(e);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// TopAbs_ShapeEnum te=e.ShapeType();
#endif
TopTools_ListOfShape lf;FDSCNX_FaceEdgeConnexFaces(s,e,HDS,lf);
#include <TopOpeBRepDS_reDEB.hxx>
#include <TopOpeBRepDS_define.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_EXPORT Standard_Boolean DSREDUEDGETRCE(const Standard_Integer EIX) {
Standard_Boolean b1 = TopOpeBRepDS_GettracePEI();
Standard_Boolean b2 = TopOpeBRepDS_GettracePI();
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifndef _TopOpeBRepDS_reDEB_HeaderFile
+#ifndef OCCT_DEBUG_HeaderFile
#define _TopOpeBRepDS_reDEB_HeaderFile
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopOpeBRepDS_define.hxx>
Standard_EXPORT Standard_Boolean TopOpeBRepDS_GettracePEI();
Standard_EXPORT Standard_Boolean TopOpeBRepDS_GettracePI();
#define MDSdmoiloi TopOpeBRepDS_DataMapOfIntegerListOfInterference
#define MDSdmiodmoiloi TopOpeBRepDS_DataMapIteratorOfDataMapOfIntegerListOfInterference
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopOpeBRepDS_reDEB.hxx>
extern Standard_Boolean TopOpeBRepDS_GetcontextMKTONREG();
#endif
(const TopOpeBRepDS_DataStructure& BDS,const Standard_Integer EIX,const TopOpeBRepDS_Kind GT,TopOpeBRepDS_ListOfInterference& LI,TopOpeBRepDS_ListOfInterference& RLI)
//------------------------------------------------------
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=DSREDUEDGETRCE(EIX);
TRC = Standard_False; //xpu170898
#endif
Standard_Boolean isEd = BRep_Tool::Degenerated(E);
if (isEd) return;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout<<endl<<"repvg1 E"<<EIX<<" <- "<<LI.Extent()<<endl;
if (TRC) debredpvg(EIX);
#endif
Standard_Boolean cond = (G1 == G2); if (!cond) { it2.Next(); continue; }
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC && isvertex && DSREDUEDGETRCE(BDS.Shape(VDS))) debreducerEV(EIX,BDS.Shape(VDS));
#endif
if (!isComplex && memeS) {
Standard_Boolean mktone = Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// NYI XPU : corriger la sequence suivante (avec mkTonE) qui produit une
// NYI transition (ON,ON) dans le cas cto 009 B4 pour l'arete 6* / face *21
// NYI aux PDS 1 et 5, au lieu de (IN,IN).
Standard_Boolean ok = FDS_stateEwithF2d(BDS,E,pE,GT1,G1,F1,TrmemeS); if (!ok) {it2.Next();continue;}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC){cout<<"memeS result ";TrmemeS.Dump(cout);cout<<endl;}
#endif
LI.Remove(it2);
EITool.Init(E,I1);
if (ispoint) EITool.Add(E,PDS,I1);
else if (isvertex) EITool.Add(E1,VDS,I1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC){cout<<endl<<"complex T2d E"<<EIX<<endl;I1->Dump(cout);cout<<endl;}
if (TRC){cout<<"init ";Handle(TopOpeBRepDS_Interference) IBID = new TopOpeBRepDS_Interference();
EITool.Transition(IBID);IBID->Transition().Dump(cout);cout<<endl;}
} // !isComplex && !memeS
if (isComplex && !memeS) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC) I2->Dump(cout,"add ","\n");
#endif
if (ispoint) EITool.Add(E,PDS,I2);
else if (isvertex) EITool.Add(E2,VDS,I2);
LI.Remove(it2);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if(TRC){cout<<"result ";Handle(TopOpeBRepDS_Interference) IBID = new TopOpeBRepDS_Interference();
EITool.Transition(IBID);IBID->Transition().Dump(cout);cout<<endl;}
#endif
if (isComplex && memeS) {
it2.Next();
-#ifdef DEB
+#ifdef OCCT_DEBUG
#endif
} // (isComplex && memeS)
} // it1
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout<<"repvg2 E"<<EIX<<" -> reste "<<LI.Extent()<<" + reduit "<<RLI.Extent()<<endl<<endl;
#endif
} // FDS_repvg2
//------------------------------------------------------
{
TopOpeBRepDS_TKI tki; tki.FillOnGeometry(LOI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean TRC=DSREDUEDGETRCE(EIX);
TRC = Standard_False; //xpu170898
if (TRC) cout<<endl<<"repvg E"<<EIX<<" <- "<<LOI.Extent()<<endl;
/*LOI.Clear();
for (tki.Init(); tki.More(); tki.Next()) {
TopOpeBRepDS_Kind K; Standard_Integer G; tki.Value(K,G);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) {tki.DumpTKI(K,G,"","\n");debredpvg(EIX);}
#endif
TopOpeBRepDS_ListOfInterference& loi = tki.ChangeValue(K,G); TopOpeBRepDS_ListOfInterference Rloi;
}
}*/
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TRC) cout<<"repvg E"<<EIX<<" -> reste "<<LOI.Extent()<<" + reduit "<<RLOI.Extent()<<endl<<endl;
#endif
}
//modified by NIZNHY-PKV Sun Dec 15 17:59:43 2002 t
TopTools_ListIteratorOfListOfShape it(LS1); if (!it.More()) return;
const TopoDS_Shape& sref = it.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Integer iref =
#endif
HDS->SameDomainReference(sref);
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <Standard_Type.hxx>
}
-// #ifdef DEB
+// #ifdef OCCT_DEBUG
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopOpeBRepDS_traceDSX.hxx>
//////////////////////////////////////////////////////////////
#ifndef _TopOpeBRepDS_traceDSX_HeaderFile
#define _TopOpeBRepDS_traceDSX_HeaderFile
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopOpeBRepDS_define.hxx>
#include <TColStd_HArray1OfBoolean.hxx>
Standard_Integer myns;
};
-// #ifdef DEB
+// #ifdef OCCT_DEBUG
#endif
// #define _TopOpeBRepDS_traceDSX_HeaderFile
Standard_OStream& TopOpeBRepTool::Print(const TopOpeBRepTool_OutCurveType t,
Standard_OStream& OS)
{
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
switch (t) {
case TopOpeBRepTool_BSPLINE1 : OS << "BSPLINE1"; break;
case TopOpeBRepTool_APPROX : OS << "APPROX"; break;
#include <TopOpeBRepTool_DRAW.hxx>
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
void debc2dnull(void) {}
Standard_EXPORT Standard_Boolean TopOpeBRepTool_GettraceC2D();
#endif
f2d = f; l2d = l;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceC2D() && C2D.IsNull()) {
cout<<"#FC2D_make2d1 --> PCurve IsNull"<<endl;
}
FC2D_translate(C2D,E,F,EF);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceC2D() && C2D.IsNull()) {
cout<<"#FC2D_make2d2 --> PCurve IsNull"<<endl;
}
#include <TopOpeBRepTool_define.hxx>
#include <Standard_ProgramError.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#define TBOX TopOpeBRepTool_GettraceBOX()
#endif
//=======================================================================
void TopOpeBRepTool_BoxSort::MakeHAB(const TopoDS_Shape& S,const TopAbs_ShapeEnum TS,const TopAbs_ShapeEnum TA)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopAbs_ShapeEnum t =
#endif
S.ShapeType();
AB.ChangeValue(i) = B;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TBOX) {
cout<<"# BS::MakeHAB : ";TopAbs::Print(t,cout);cout<<" : "<<n<<"\n";
cout.flush();
MakeHAB(S,TS,TA);
MakeHABCOB(myHAB,myCOB);
myBSB.Initialize(myCOB,myHAB);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TBOX) {myHBT->DumpB(myCOB);cout<<";# BS::MakeCOB"<<endl;}
#endif
}
else L = &myBSB.Compare(myLastCompareShapeBox);
myIterator.Initialize(*L);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TBOX) {
Standard_Integer nl = (*L).Extent();
cout<<"#------------------------"<<endl;
// (Umin(i), Vmin(i), Umax(i), Vmax(i))
B(i).Get(UV(i,1), UV(i,3), UV(i,2), UV(i,4));
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = Standard_False;
if (trc) {
for (Standard_Integer i = 1; i <= 2; i++)
#include <BRep_ListIteratorOfListOfCurveRepresentation.hxx>
#include <BRep_GCurve.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepTool_GettraceCORRISO();
Standard_EXPORT TopTools_IndexedMapOfShape STATIC_PURGE_mapv;
Standard_EXPORT TopTools_IndexedMapOfOrientedShape STATIC_PURGE_mapeds;
static void FUN_RaiseError()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// Standard_Boolean trc = TopOpeBRepTool_GettraceCORRISO();
FUN_REINIT();
// if (trc) cout <<"*********failure in CORRISO***********\n";
}
static void FUN_Raise()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
// cout <<"*********failure in CORRISO***********\n";
#endif
}
TopExp_Explorer ex(S, TopAbs_EDGE);
for (; ex.More(); ex.Next()){
const TopoDS_Edge& E = TopoDS::Edge(ex.Current());
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iE = STATIC_PURGE_mapeds.Add(E);
(void)iE; // avoid warning
#ifdef DRAW
TopExp_Explorer exv(E, TopAbs_VERTEX);
for (; exv.More(); exv.Next()){
const TopoDS_Vertex& v = TopoDS::Vertex(exv.Current());
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iE = STATIC_PURGE_mapeds.Add(E);
(void)iE; // avoid warning
#ifdef DRAW
Standard_Boolean TopOpeBRepTool_CORRISO::UVClosed() const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceCORRISO();
if (trc) cout<<"** UVClosed"<<endl;
#endif
Standard_Boolean TopOpeBRepTool_CORRISO::PurgeFyClosingE(const TopTools_ListOfShape& ClEds, TopTools_ListOfShape& fyClEds) const
{
fyClEds.Clear();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceCORRISO();
if (trc) cout<<"* PurgeFyClosingE"<<endl;
#endif
Standard_Real tttuvcE = Max(Tol(1,tttolcE),Tol(2,tttolcE));
TopOpeBRepTool_C2DF cE2d; Standard_Boolean isb = UVRep(cE,cE2d);
if (!isb) return Standard_False; // NYIRAISE
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer icE = STATIC_PURGE_mapeds.Add(cE);
if (trc) cout<<"? e"<<icE<<" :"<<endl;
#endif
isonOcE2d = (UVvce1.Distance(UVvOcE2) < tol);
}
if (!isonOcE2d) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<"-> valid edge"<<endl;
#endif
continue;
if (!isb) return Standard_False; // NYIRAISE
Standard_Real parvce = TopOpeBRepTool_TOOL::ParE(ivce,cE); gp_Pnt2d UVvce = TopOpeBRepTool_TOOL::UVF(parvce,cE2d);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// recall in one wire, there are 2 vertices for one non-degenerated closing edge
Standard_Integer ivmapv = STATIC_PURGE_mapv.Add(vce);
if (trc) {cout<<" connexity for v("<<ivce<<")=v"<<ivmapv;FUN_tool_trace(UVvce);}
for (TopTools_ListIteratorOfListOfShape ite(loe); ite.More(); ite.Next()) {
const TopoDS_Edge& E = TopoDS::Edge(ite.Value());
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer iE = STATIC_PURGE_mapeds.Add(E);
if (trc) {cout<<" : on e"<<iE<<endl;}
#endif
Standard_Boolean samev = ve.IsSame(vce);
if (!samev) continue;
Standard_Real parve = TopOpeBRepTool_TOOL::ParE(ive,E); gp_Pnt2d UVve = TopOpeBRepTool_TOOL::UVF(parve,E2d);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<" ve("<<ive<<")";FUN_tool_trace(UVve);}
#endif
if (ive == ivce) continue; // vertex FORWARD connexed to REVERSED one
}
if (sameuv) {
vceok = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc){cout<<" connexity->ok"<<endl;}
#endif
}
if (vceok) break;
} //ite(loe)
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc && !vceok) {cout<<" connexity->KO"<<endl;}
#endif
if (vceok) nvcEok++;
Standard_Boolean isfycE = (nvcEok == 0); // each bound is not connexed to any non-closed edge
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc)
{if (isfycE) cout<<"-> faulty edge"<<endl;
else cout<<"-> valid edge"<<endl;}
Standard_Boolean TopOpeBRepTool_CORRISO::EdgeWithFaultyUV(const TopoDS_Edge& E, Standard_Integer& Ivfaulty) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceCORRISO();
Standard_Integer iE = STATIC_PURGE_mapeds.Add(E);
if (trc) cout<<"? e"<<iE<<" :"<<endl;
TopTools_Array1OfShape vEs(1,2); TopOpeBRepTool_TOOL::Vertices(E, vEs);
Standard_Boolean closed = vEs(1).IsSame(vEs(2));
if (closed) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"closed -> valid edge"<<endl;}
#endif
return Standard_False; // closed edge is assumed valid
TopOpeBRepTool_C2DF C2DF; Standard_Boolean isb = UVRep(E,C2DF);
if (!isb) return Standard_False; //NYIRAISE
gp_Pnt2d UVvE = TopOpeBRepTool_TOOL::UVF(parvE,C2DF);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// recall in one wire, there are 2 vertices for one non-degenerated closing edge
Standard_Integer ivmapv = STATIC_PURGE_mapv.Add(vE);
if (trc) {cout<<" connexity for v("<<ivE<<")=v"<<ivmapv;FUN_tool_trace(UVvE);}
const TopoDS_Edge& e = TopoDS::Edge(ite.Value());
TopAbs_Orientation oe = e.Orientation();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer ie = STATIC_PURGE_mapeds.Add(e);
if (trc) {cout<<" : on e"<<ie<<endl;}
#endif
if (!samev) continue;
Standard_Real pare = TopOpeBRepTool_TOOL::ParE(ive,e); gp_Pnt2d UVve = TopOpeBRepTool_TOOL::UVF(pare,C2DF);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<" ve("<<ive<<")";FUN_tool_trace(UVve);}
#endif
if (ive == ivE) continue;
Standard_Boolean isequal = UVvE.IsEqual(UVve,tttol);
if (isequal) {
vEok = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc){cout<<" connexity->ok"<<endl;}
#endif
break;
} // ite(loe)
if (!vEok) {nfyv++; Ivfaulty = ivE;}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc && !vEok) {cout<<" connexity->KO"<<endl;}
#endif
} // ivE = 1..2
if (nfyv == 2) Ivfaulty = 3;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {if (Ivfaulty == 0) cout<<"-> valid edge"<<endl; else cout<<"-> faulty edge"<<endl;}
#endif
return (Ivfaulty != 0);
TopTools_DataMapOfOrientedShapeInteger& FyEds, const Standard_Boolean stopatfirst) const
{
FyEds.Clear();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer ifault = 0;
Standard_Boolean trc = TopOpeBRepTool_GettraceCORRISO();
if (trc) cout<<endl<<"* EdgesWithFaultyUV"<<endl;
if (!faulty) continue;
Standard_Integer nfyv = (Ivfaulty == 3)? 2 : 1;
-#ifdef DEB
+#ifdef OCCT_DEBUG
ifault++;
if (trc) cout<<"e"<<STATIC_PURGE_mapeds.FindIndex(Echk)<<" has ifyv="<<Ivfaulty<<endl;
#ifdef DRAW
#include <Geom_RectangularTrimmedSurface.hxx>
#include <BRep_Tool.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopOpeBRepTool_KRO.hxx>
TOPKRO KRO_CURVETOOL_APPRO("approximation");
extern Standard_Boolean TopOpeBRepTool_GettraceKRO();
myGeomTool.GetTolerances(tol3d,tol2d,RelativeTol);
Standard_Integer NbPntMax = myGeomTool.NbPntMax();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceKRO()) KRO_CURVETOOL_APPRO.Start();
#endif
GeomLib_CheckBSplineCurve cbsc(Curve, 1.e-7, 0.1);
cbsc.NeedTangentFix(bf, bl);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceCHKBSPL()) {
if(bf || bl) {
cout<<"Problem orientation GeomLib_CheckBSplineCurve : First = "<<bf;
if(!Curve2df.IsNull()) {
GeomLib_Check2dBSplineCurve cbsc2df(Curve2df, 1.e-7, 0.1);
cbsc2df.NeedTangentFix(bf, bl);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceCHKBSPL()) {
if(bf || bl) {
cout<<"Problem orientation GeomLib_CheckBSplineCurve : First = "<<bf;
if(!Curve2ds.IsNull()) {
GeomLib_Check2dBSplineCurve cbsc2ds(Curve2ds, 1.e-7, 0.1);
cbsc2ds.NeedTangentFix(bf, bl);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceCHKBSPL()) {
if(bf || bl) {
cout<<"Problem orientation GeomLib_CheckBSplineCurve : First = "<<bf;
cbsc2ds.FixTangent(bf, bl);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceKRO()) KRO_CURVETOOL_APPRO.Stop();
#endif
// cout << "MakeCurves end" << endl;
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettracePCURV()) {
cout<<"--- IsProjectable : ";
if (projectable) cout<<"projectable"<<endl;
#include <Geom2d_BSplineCurve.hxx>
#include <BSplCLib.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepBuild_GettraceFE();
#endif
void TopOpeBRepTool_FuseEdges::BuildListEdges()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tFE = TopOpeBRepBuild_GettraceFE();
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tFE) cout<<endl<<"FuseEdges : BuildListEdges "<<endl;
#endif
void TopOpeBRepTool_FuseEdges::BuildListResultEdges()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tFE = TopOpeBRepBuild_GettraceFE();
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tFE) cout<<endl<<"FuseEdges : BuildListResultEdges "<<endl;
#endif
for (itLstEdg.Initialize(myMapLstEdg); itLstEdg.More(); itLstEdg.Next()) {
const Standard_Integer& iLst = itLstEdg.Key();
const TopTools_ListOfShape& LmapEdg = myMapLstEdg.Find(iLst);
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopTools_ListIteratorOfListOfShape itEdg;
#endif
C = (*((Handle(Geom_TrimmedCurve)*)&C))->BasisCurve();
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tFE) cout<<endl<<"FuseEdges : Creating New Edge "<<endl;
#endif
// the curve which is not infinite and limited to old vertices
// we try to use ExtendCurveToPoint, then rebuild the NewEdge
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tFE) cout<<endl<<"FuseEdges : MakeEdge failed. Trying to Extend Curve "<<endl;
#endif
Handle(Geom_BoundedCurve) ExtC = Handle(Geom_BoundedCurve)::DownCast(C->Copy());
NewEdge = ME.Edge();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tFE) cout<<endl<<"FuseEdges : Updating pcurve "<<endl;
#endif
if (UpdatePCurve(OldEdge,NewEdge,LmapEdg))
void TopOpeBRepTool_FuseEdges::Perform()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tFE = TopOpeBRepBuild_GettraceFE();
#endif
BuildListResultEdges();
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tFE) cout<<endl<<"FuseEdges : Perform "<<endl;
#endif
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tFE) cout<<endl<<"FuseEdges : Building New Shape "<<endl;
#endif
myShape=(Bsub.Copy(myShape)).First();
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (tFE) cout<<endl<<"FuseEdges : "<< NbVertices() <<" vertices removed"<<endl;
#endif
typC1 != STANDARD_TYPE(Geom_Ellipse) &&
typC1 != STANDARD_TYPE(Geom_BSplineCurve) &&
typC1 != STANDARD_TYPE(Geom_BezierCurve)) {
-#ifdef TOPOPEBREPTOOL_DEB
+#ifdef OCCT_DEBUG
cout << " TopOpeBRepTool_FuseEdge : Type de Support non traite" << endl;
#endif
return Standard_False;
return ng;
}
}
-#ifdef TOPOPEBREPTOOL_DEB
+#ifdef OCCT_DEBUG
cout<<"FUN_tool_nggeomF NYI"<<endl;
#endif
return gp_Dir(0,0,1);
#include <TopOpeBRepTool_define.hxx>
#include <Precision.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#define TBOX TopOpeBRepTool_GettraceBOX()
#endif
//=======================================================================
void TopOpeBRepTool_HBoxTool::AddBox(const TopoDS_Shape& S)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
TopAbs_ShapeEnum t =
#endif
S.ShapeType();
Bnd_Box B;
ComputeBox(S,B);
myIMS.Add(S,B);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TBOX) {
DumpB(Box(S));cout<<"; # HBT::AddBox "<<Index(S)<<" : ";TopAbs::Print(t,cout);cout<<"\n";cout<<endl;
}
//purpose :
//=======================================================================
void TopOpeBRepTool_HBoxTool::DumpB
-#ifdef TOPOPEBREPTOOL_DEB
+#ifdef OCCT_DEBUG
(const Bnd_Box& B)
{
if (B.IsVoid()) cout<<"# IsVoid";
#ifndef _TopOpeBRepTool_KRO_HeaderFile
#define _TopOpeBRepTool_KRO_HeaderFile
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <OSD_Chronometer.hxx>
#include <TCollection_AsciiString.hxx>
#include <Standard_OStream.hxx>
#include <Standard_Failure.hxx>
#include <TopOpeBRepTool_PURGE.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
//Standard_EXPORT Standard_Integer STATIC_PURGE_iwi = 0;
//Standard_EXPORT TopTools_IndexedMapOfShape STATIC_PURGE_mapw, STATIC_PURGE_mapv;
//Standard_EXPORT TopTools_IndexedMapOfOrientedShape STATIC_PURGE_mapeds, STATIC_CORR_mapeds;
// elsewhere : we have to get this information using geometric
// criteriums (TopOpeBRepTool_TOOL::IsonCLO)
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettracePURGE();
if (trc) cout<<"\n* PurgeClosingEdges:\n\n";
#endif
MshNOK.Add(FF);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc && topurge) cout<<"found FAULTY edge = ed"<<endl;
#endif
} // exw
Standard_Boolean ok = (fEin && fe1 && fe2);
if (!ok) return Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
debcorrUV(); // call Draw_Call("av2d;dy fyf;fit;ppcu fyf")
#endif
}
else {
// redefinition des parametres de v1,v2 de Ein tels que des parametres de
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceCORRISO()) {
cout<<"FUN_correctDegeneratedE : !mmd NYI"<<endl;
}
Standard_Boolean TopOpeBRepTool::CorrectONUVISO(const TopoDS_Face& Fin, TopoDS_Face& Fsp)
// <Fref> is x-periodic
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceCORRISO();
if (trc) cout<<"\n#### CorrectONUVISO ####\n\n";
debcorrUV();
return Standard_True;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
cout<<"CorrectONUVISO ";
cout<<"iso faulty "<<tocorrectisoe<<" deg faulty "<<tocorrectdege<<endl;;
#include <TopTools_Array1OfShape.hxx>
#include <gp_Pnt2d.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern void FUN_REINIT();
extern Standard_Integer FUN_addepc(const TopoDS_Shape& ed,const TopoDS_Shape& f);
extern Standard_Integer FUN_addcheckepc(const TopoDS_Shape& ed,const TopoDS_Shape& f);
#define EXTERNAL (4)
#define CLOSING (5)
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepTool_GettraceREGUSO();
static TopTools_IndexedMapOfShape STATIC_mape, STATIC_mapf, STATIC_mapw, STATIC_mapsh;
static Standard_Integer FUN_adds(const TopoDS_Shape& s) {
static void FUN_Raise()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUSO();
if (trc) cout<<"***** Failure in REGUS **********"<<endl;
// Standard_Failure::Raise("REGUS");
Standard_Boolean TopOpeBRepTool_REGUS::MapS()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUSO();
Standard_Integer ish = FUN_adds(S());
if (trc) cout<<"** MAPPING ** shape"<<ish<<endl;
const TopTools_ListOfShape& lof = itm.Value();
Standard_Integer nf = lof.Extent();
if (nf > 2) mymapemult.Add(e);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
cout <<"co(e"<<FUN_adds(e)<<")= ";
TopTools_ListIteratorOfListOfShape it(lof);
Standard_Boolean TopOpeBRepTool_REGUS::WireToFace(const TopoDS_Face& Fanc, const TopTools_ListOfShape& nWs, TopTools_ListOfShape& nFs)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUSO();
#endif
nFs.Clear();
Standard_Boolean classifok = classi.Classilist(nWs,mapWlow);
if (!classifok) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<"** classif fails"<<endl;
#endif
return Standard_False;
Standard_Boolean facesbuilt = TopOpeBRepTool_TOOL::WireToFace(Fanc, mapWlow, nFs);
if (!facesbuilt) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<"** facesbuilt fails"<<endl;
#endif
return Standard_False;
Standard_Boolean TopOpeBRepTool_REGUS::SplitFaces()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUSO();
Standard_Integer ish = FUN_adds(S());
if (trc) cout<<"** SPLITTING FACES ** shape"<<ish<<endl;
}//exe(fsp)
}//itf(lfsp)
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
cout <<"split(f"<<FUN_adds(f)<<")= ";
TopTools_ListIteratorOfListOfShape it(lfsp);
Standard_Boolean TopOpeBRepTool_REGUS::REGU()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUSO();
Standard_Integer ishe = FUN_adds(myS);
if (trc) cout<<"** REGU **"<<ishe<<endl;
Standard_Boolean startBlock = mylFinBlock.IsEmpty();
Standard_Boolean endBlock = myedstoconnect.IsEmpty() && (!startBlock);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean tr=Standard_False;
if (tr) {
TopTools_MapIteratorOfMapOfShape it(myedstoconnect);
Standard_Integer nFcur = mylFinBlock.Extent();
Standard_Boolean unchanged = (nFcur==myoldnF) && (mynF==myoldnF);
if (unchanged) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<"#** shell"<<ishe<<" valid\n";
#endif
return Standard_False; // nyi analysis if we should raise or not
else {
TopoDS_Shell newShe; TopOpeBRepTool_TOOL::MkShell(mylFinBlock,newShe);
Splits.Append(newShe);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"#** shell "<<ishe<<" gives new shell "<<FUN_adds(newShe)<<endl;
for (TopTools_ListIteratorOfListOfShape it(mylFinBlock); it.More(); it.Next()) cout <<";dins f"<<FUN_adds(it.Value());
cout<<endl<<endl;}
const TopTools_ListOfShape& lof = mymapeFs.Find(e);
if (lof.IsEmpty()) {mymapeFs.UnBind(e); continue;}
myf = lof.First();
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUSO();
if (trc) cout<<"* Block : first face = f"<<FUN_adds(myf)<<endl;
#endif
Standard_Boolean TopOpeBRepTool_REGUS::NextinBlock()
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUSO();
#endif
// we try to connect first edge of <myf> bound in <myedstoconnect>
const TopTools_ListOfShape& lof = mymapeFs.Find(e); Standard_Integer nf = lof.Extent();
if (nf == 0) {myedstoconnect.Remove(e); mymapeFs.UnBind(e);
continue;}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"e"<<FUN_adds(e)<<" on "<<nf<<" untouched f:"<<endl;}
#endif
if (nf == 1) myf = lof.First();
if (!ok) return Standard_False;
myf = ffound;
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<"->myf = f"<<FUN_adds(myf)<<endl;
#endif
return Standard_True;
// NYIXPU!!!!!!!! if (xx1 tg xx2) -> use curvatures
//
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUSO();
#endif
ffound.Nullify();
if (!ok) {FUN_Raise(); return Standard_False;}
Standard_Boolean oppo = TopOpeBRepTool_TOOL::Matter(x,y,xxfound,ntfound,tola, angfound);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc&&!oppo) cout<<" f"<<FUN_adds(fref)<<",f"<<FUN_adds(ffound)<<" not oppo"<<endl;
#endif
if (!oppo) {ffound.Nullify(); continue;}
ok = TopOpeBRepTool_TOOL::MatterKPtg(fref,ffound,e,angfound);
if (!ok) {FUN_Raise(); return Standard_False;}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" ang("<<"f"<<FUN_adds(fref)<<",f"<<FUN_adds(ffound)<<")="<<angfound<<endl;
#endif
break;
Standard_Real angi = 0;
Standard_Boolean oppo = TopOpeBRepTool_TOOL::Matter(x,y,xxi,nti,tola, angi);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc&&!oppo) cout<<" f"<<FUN_adds(fref)<<",f"<<FUN_adds(fi)<<" not oppo"<<endl;
#endif
if (!oppo) continue;
ok = TopOpeBRepTool_TOOL::MatterKPtg(fref,fi,e,angi);
if (!ok) {FUN_Raise(); return Standard_False;}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" ang("<<"f"<<FUN_adds(fref)<<",f"<<FUN_adds(fi)<<")="<<angi<<endl;
#endif
if (angi > angfound) continue;
#define M_INTERNAL(ori) (ori == TopAbs_INTERNAL)
#define M_EXTERNAL(ori) (ori == TopAbs_EXTERNAL)
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepTool_GettraceREGUFA();
static TopTools_IndexedMapOfShape STATIC_mapf, STATIC_mapw, STATIC_mapv;
static TopTools_IndexedMapOfOrientedShape STATIC_mapeds;
else {TopTools_ListOfShape los; los.Append(subitem); map.Bind(key,los);}
}
static void FUN_Raise() {
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
if (trc) cout<<"*** Raise REGUW"<<endl;
// Standard_Failure::Raise("REGUW");
Standard_Boolean TopOpeBRepTool_REGUW::SplitEds()
{
if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
if (trc) cout<<"** SPLITTING EDGES **"<<endl;
#endif
if (isdone) splits.Assign(myEsplits.Find(e));
else issp = TopOpeBRepTool_TOOL::SplitE(e,splits);
if (issp) hasnewsplits = Standard_True;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<"e"<<FUN_adds(e)<<" gives splits ="<<endl;
#endif
if (!(issp || isdone)) continue; //nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnyi
TopTools_ListIteratorOfListOfShape ite(splits);
for (; ite.More(); ite.Next()){
const TopoDS_Shape& esp = ite.Value();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<" e"<<FUN_adds(esp);}
#endif
TopExp_Explorer exvv(esp, TopAbs_VERTEX);
co.AddItem(ivv,esp);
}//exvv(exvv,VERTEX)
}//ite(splits)
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<endl;
#endif
}
Standard_Boolean TopOpeBRepTool_REGUW::MapS()
{
if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
if (trc) cout<<"** MAPPING **"<<endl;
#endif
}//exv
}//exe
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
for (Standard_Integer iv = 1; iv <= mymapvEds.Extent(); iv++) {
const TopoDS_Vertex& v = TopoDS::Vertex(mymapvEds.FindKey(iv));
Standard_Boolean TopOpeBRepTool_REGUW::InitBlock()
{
if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
#endif
for (; exv.More(); exv.Next()){
const TopoDS_Shape& vcur = exv.Current();
TopOpeBRepTool_connexity& cco = mymapvEds.ChangeFromKey(vcur);
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
// Standard_Boolean ok =
//#endif
cco.RemoveItem(myed);
// myv, myp2d, mytg2d :
::FUN_nextdata(iStep,myed,pc, myv,myp2d,mytg2d);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
cout<<endl<<" v0 = v"<<FUN_adds(myv0)<<" p2d0 = ("<<myp2d0.X()<<" "<<myp2d0.Y()<<")"<<endl;
cout<<" vcur = v"<<FUN_adds(myv)<<" p2d = ("<<myp2d.X()<<" "<<myp2d.Y()<<")"<<endl;
Standard_Boolean TopOpeBRepTool_REGUW::NearestE(const TopTools_ListOfShape& loe, TopoDS_Edge& efound) const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
#endif
Standard_Real angfound = 1.e7;
if (iStep == 1) angfound = TopOpeBRepTool_TOOL::Matter(mytg2d,tg2dfound);
else angfound = 2.*M_PI - TopOpeBRepTool_TOOL::Matter(tg2dfound,mytg2d);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<"ang(e"<<FUN_adds(myed)<<",e"<<FUN_adds(efound)<<")="<<angfound<<endl;
#endif
if (iStep == 1) angi = TopOpeBRepTool_TOOL::Matter(mytg2d,tg2di);
else angi = 2.*M_PI - TopOpeBRepTool_TOOL::Matter(tg2di,mytg2d);
Standard_Boolean eq = Abs(angi-angfound) < tola;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<"ang(e"<<FUN_adds(myed)<<",e"<<FUN_adds(ei)<<")="<<angi<<endl;
#endif
if (eq) {
Standard_Boolean TopOpeBRepTool_REGUW::NextinBlock()
{
if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
if (trc) cout<<endl<<" vcur = v"<<FUN_adds(myv)<<" p2d = ("<<myp2d.X()<<" "<<myp2d.Y()<<")"<<endl;
#endif
TopTools_ListIteratorOfListOfShape ite(le);
while (ite.More()) {
const TopoDS_Edge& e = TopoDS::Edge(ite.Value());
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" e"<<FUN_adds(e);
#endif
Standard_Boolean issame = e.IsSame(myed);
if (issame) {//xpu240299 FRA60275, fsp4
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<" is same : not valid"<<endl;
#endif
le.Remove(ite); continue;
Standard_Boolean samep2d = p2de.IsEqual(myp2d,mytol2d);
if (!samep2d) le.Remove(ite);
else ite.Next();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {if (samep2d) cout<<" valid"<<endl;
else cout<<" not valid"<<endl;}
#endif
TopExp_Explorer exv(myed, TopAbs_VERTEX);
for (; exv.More(); exv.Next()){
TopOpeBRepTool_connexity& cco = mymapvEds.ChangeFromKey(exv.Current());
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
// Standard_Boolean ok =
//#endif
cco.RemoveItem(myed);
Standard_Real f,l,tol; const Handle(Geom2d_Curve)& pc = c2df.PC(f,l,tol);
::FUN_nextdata(iStep,myed,pc, myv,myp2d,mytg2d);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
cout<<" vcur = v"<<FUN_adds(myv)<<" p2d = ("<<myp2d.X()<<" "<<myp2d.Y()<<")"<<endl;
cout<<" ecur = e"<<FUN_adds(myed)<<endl;
//=======================================================================
Standard_Boolean TopOpeBRepTool_REGUW::REGU(const Standard_Integer istep,
-#ifdef DEB
+#ifdef OCCT_DEBUG
const TopoDS_Shape& Scur,
#else
const TopoDS_Shape& ,
{
if (!HasInit()) Standard_Failure::Raise("TopOpeBRepTool_REGUW : NO INIT");
iStep = istep;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
if (trc) cout<<endl<<"** REGU istep=**"<<iStep<<endl;
#endif
if (isinit0 && !FINI) {
Standard_Boolean ok = InitBlock();
if (!ok) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<"** InitBlock fails"<<endl;
#endif
{FUN_Raise(); return Standard_False;}
// is valid and unchanged.
Standard_Boolean onewok = FINI && loW.IsEmpty() && !hasnewsplits;
if (onewok){
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<"wire "<<FUN_adds(Scur)<<" is found valid\n";
#endif
return Standard_True;
TopoDS_Wire newW; Standard_Boolean wiok = FUN_tool_MakeWire(loEcur, newW);
if (wiok) loW.Append(newW);
else {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<"** FUN_tool_MakeWire fails"<<endl;
#endif
{FUN_Raise(); return Standard_False;}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"#->new wire = wi"<<FUN_adds(newW)<<" = ";
for (TopTools_ListIteratorOfListOfShape it(loEcur); it.More(); it.Next())
cout<<" e"<<FUN_adds(it.Value());
// <v> is in <ed>, <p2d> = <v> current UV representation
Standard_Boolean gotonext = NextinBlock();
if (!gotonext) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<"** NextinBlock fails"<<endl;
#endif
{FUN_Raise(); return Standard_False;}
TopOpeBRepTool_connexity& co = mymapvEds.ChangeFromKey(v);
co.AddItem(OriKey,e);
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
if (trc)
{cout<<"** setting new connexity : v"<<FUN_adds(v)<<" is ";FUN_tro(OriKey);
ok = co.RemoveItem(OriKey,e);
if (!ok) return Standard_False;
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
if (trc)
{cout<<"** removing old connexity : v"<<FUN_adds(v)<<" for e"<<FUN_adds(e);FUN_tool_tori(e.Orientation());
#define M_INTERNAL(sta) (sta == TopAbs_INTERNAL)
#define M_EXTERNAL(sta) (sta == TopAbs_EXTERNAL)
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepTool_GettraceREGUFA();
static TopTools_IndexedMapOfShape STATIC_mapw,STATIC_mapf;
static Standard_Integer FUN_adds(const TopoDS_Shape& s) {
// (Umin(i), Vmin(i), Umax(i), Vmax(i))
B(i).Get(UV(i,1), UV(i,3), UV(i,2), UV(i,4));
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = Standard_False;
if (trc) {
for (Standard_Integer i = 1; i <= 2; i++)
{
// NYI : create maps to store Bnd_Box2d, and faces.
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
if (trc) cout<<"** ClassifW :"<<endl;
STATIC_mapw.Clear();
Standard_Integer sta = FUN_tool_classiBnd2d(Bnd2d);
nite++;
if ((sta == SAME)||(sta == UNKNOWN)) sta = FUN_tool_classiwithp2d(wi);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"#wi :";FUN_tool_coutsta(sta,FUN_adds(wi(1)),FUN_adds(wi(2)));}
#endif
if ((sta == SAME)||(sta == UNKNOWN)) return Standard_False;
// Classifying Ow<i> with Ow<j> :
osta = FUN_tool_classiBnd2d(OBnd2d);
if ((osta == SAME)||(osta == UNKNOWN)) osta = FUN_tool_classiwithp2d(Owi);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"wi : "; FUN_tool_coutsta(osta,FUN_adds(Owi(1)),FUN_adds(Owi(2)));}
#endif
if ((osta == SAME)||(osta == UNKNOWN)) return Standard_False;
// Classifying wi(1) with wi(2) :
sta = FUN_tool_classiBnd2d(Bnd2d);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"wi : "; FUN_tool_coutsta(sta,STATIC_mapw.FindIndex(wi(1)),
STATIC_mapw.FindIndex(wi(2)));}
#endif
TopTools_DataMapOfShapeListOfShape& mapWlow,
TopTools_ListOfShape& aListOfFaces)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
if (trc) cout<<"** MakeFaces :"<<endl;
#endif
aListOfFaces.Append(FF);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {
cout<<"sp(fa"<<FUN_adds(theFace)<<")=";
TopTools_ListIteratorOfListOfShape it(aListOfFaces);
const TopTools_DataMapOfShapeListOfShape& mapOwNw,
TopTools_DataMapOfShapeListOfShape& mapWlow)
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Boolean trc = TopOpeBRepTool_GettraceREGUFA();
if (trc) cout<<"** ClassifW :"<<endl;
#endif
TopTools_ListOfShape ldone; FUN_addOwlw(Ow1,lw1,ldone);
TopTools_ListIteratorOfListOfShape itw(ldone);
for (; itw.More(); itw.Next()) mapdone.Add(itw.Value());
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) cout<<"old wires :wi"<<FUN_adds(Ow1)<<" is OUT all old wires"<<endl;
#endif
lOws.RemoveFirst();
}//OUTall
else {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<"old wires :wi -> ";
FUN_tool_coutsta(sta12,FUN_adds(Ow1),FUN_adds(Ow2));
cout<<endl;}
Standard_Integer stabnd2d = CLASSI.ClassiBnd2d(wsma,wgre,toluv,Standard_True);
Standard_Integer sta = CLASSI.Classip2d(wsma,wgre, stabnd2d);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (trc) {cout<<" wires :wi -> ";
FUN_tool_coutsta(sta,FUN_adds(wsma),FUN_adds(wgre));
cout<<endl;}
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <TopOpeBRepTool_STATE.hxx>
cout<<endl;
}
-// #define DEB
#endif
#ifndef _TopOpeBRepTool_STATE_HeaderFile
#define _TopOpeBRepTool_STATE_HeaderFile
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <Standard_Type.hxx>
#include <TopAbs_State.hxx>
};
-// #define DEB
-#endif
+#endif /* OCCT_DEBUG */
-// #define _TopOpeBRepTool_STATE_HeaderFile
-#endif
+#endif /* _TopOpeBRepTool_STATE_HeaderFile */
Standard_Real p = (1-t)*f2d + t*l2d;
P2D = C2D->Value(p);
-#ifdef DEB
+#ifdef OCCT_DEBUG
C3D = BRep_Tool::Curve(myEdge,f3d,l3d);
if(!C3D.IsNull())
P3D = C3D->Value(p);
// else if (o == TopAbs_INTERNAL) myState == TopAbs_IN;
else if (o == TopAbs_INTERNAL) myState = TopAbs_IN;
else {
-#ifdef TOPOPEBREPTOOL_DEB
+#ifdef OCCT_DEBUG
cout<<"StateP2DReference o<>E,I"<<endl;
#endif
break;
{
myExplorer.Init(S,ToFind,ToAvoid);
-#ifdef DEB
+#ifdef OCCT_DEBUG
myIndex = myNbShapes = 0;
for (;More();Next()) myNbShapes++;
myExplorer.ReInit();
void TopOpeBRepTool_ShapeExplorer::Next()
{
myExplorer.Next();
-#ifdef DEB
+#ifdef OCCT_DEBUG
myIndex++;
#endif
}
Standard_Integer TopOpeBRepTool_ShapeExplorer::NbShapes()const
{
Standard_Integer n = 0;
-#ifdef DEB
+#ifdef OCCT_DEBUG
n = myNbShapes;
#endif
return n;
Standard_Integer TopOpeBRepTool_ShapeExplorer::Index()const
{
Standard_Integer n = 0;
-#ifdef DEB
+#ifdef OCCT_DEBUG
n = myIndex;
#endif
return n;
Standard_OStream& TopOpeBRepTool_ShapeExplorer::DumpCurrent
(Standard_OStream& OS)const
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if ( More() ) {
const TopoDS_Shape& S = Current();
TopAbs_ShapeEnum T = S.ShapeType();
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern Standard_Boolean TopOpeBRepTool_GettraceVC();
extern Standard_Boolean TopOpeBRepTool_GettraceNYI();
#endif
periopar = ADJUST(par,Vfirst,Vlast,tol);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceVC()) {
cout<<"TopOpeBRepTool_ShapeTool PC on edge is ";
if (isoU) cout<<"isoU f,l "<<Ufirst<<" "<<Ulast<<endl;
else {
// prendre u1,v1 et projeter sur 2 pour calcul des normales
// au meme point 3d.
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceNYI()) {
cout<<"TopOpeBRepTool_ShapeTool::SurfacesSameOriented surfaces non traitees : NYI";
cout<<endl;
else {
// prendre p1 et projeter sur 2 pour calcul des normales
// au meme point 3d.
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceNYI()) {
cout<<"TopOpeBRepTool_ShapeTool::CurvesSameOriented non lineaires : NYI";
cout<<endl;
else {
myPClassifier = &myClassifierMap.ChangeFromKey(SOL);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer i =
#endif
myClassifierMap.FindIndex(SOL); // DEB
else {
myPClassifier = &myClassifierMap.ChangeFromKey(SHE);
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_Integer i =
#endif
myClassifierMap.FindIndex(SHE); // DEB
Standard_Real par1 = BRep_Tool::Parameter(v1,E);
Standard_Real par2 = BRep_Tool::Parameter(v2,E);
-#ifdef DEB
+#ifdef OCCT_DEBUG
// if (par1>par2) cout<<"TopOpeBRepTool_TOOL::Vertices ERROR"<<endl;
#endif
Standard_Integer ivparSMA = (par1<par2) ? FORWARD : REVERSED;
Standard_Boolean TopOpeBRepTool_TOOL::TggeomE(const Standard_Real par, const BRepAdaptor_Curve& BC,
gp_Vec& Tg)
{
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
// GeomAbs_CurveType ct =
//#endif
// BC.GetType();
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
// Standard_Boolean apoles = (ct == GeomAbs_BezierCurve)||(ct == GeomAbs_BSplineCurve);
//#endif
gp_Pnt2d uv; Standard_Boolean ok = FUN_tool_paronEF(e,par,f,uv);
if (!ok) return Standard_False;
gp_Dir ng( FUN_tool_nggeomF(uv,f) );
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Dir ngApp;
#endif
ok = TopOpeBRepTool_TOOL::NgApp(par,e,f,tola,Ng);
Standard_Boolean & isoU, Standard_Boolean& isoV, gp_Dir2d& d2d, gp_Pnt2d& o2d)
{
Standard_Real f,l,tol; const Handle(Geom2d_Curve)& PC = C2DF.PC(f,l,tol);
-//#ifdef DEB
+//#ifdef OCCT_DEBUG
// const iso = UVISO(PC,isoU,isoV,d2d,o2d);
//#else
const Standard_Boolean iso = UVISO(PC,isoU,isoV,d2d,o2d);
ngF = ng; return Standard_True;
}
}
-#ifdef TOPOPEBREPTOOL_DEB
+#ifdef OCCT_DEBUG
cout<<"FUN_tool_nggeomF NYI"<<endl;
#endif
return Standard_False;
{
Handle(TopOpeBRepTool_HBoxTool) hbt = FBOX_GetHBoxTool();
hbt->Clear();
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceBOX()) {
cout<<endl<<"TOOLBOX : Prepare"<<endl;
}
{
Handle(TopOpeBRepTool_HBoxTool) hbt = FBOX_GetHBoxTool();
const Bnd_Box& b = hbt->Box(S);
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (TopOpeBRepTool_GettraceBOX()) {
Standard_Integer i = hbt->Index(S);
Standard_Integer n = hbt->Extent();
#include <TopoDS_Shape.hxx>
#include <TopOpeBRepTool_HBoxTool.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
Standard_EXPORT Standard_Boolean TopOpeBRepTool_GettraceBOX();
#endif
#include <TopOpeBRepTool_DRAW.hxx>
#endif
-#ifdef DEB
+#ifdef OCCT_DEBUG
extern TopTools_IndexedMapOfShape STATIC_PURGE_mapv;
extern TopTools_IndexedMapOfOrientedShape STATIC_PURGE_mapeds;
extern Standard_Boolean TopOpeBRepTool_GettracePURGE();
// non ! laisser MMAXUV a 0.01
// MMAXUV=DP;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// printf("\n FaceTolerances3d : TOL1 = %5.5eg TOL2=%5.5eg DEFL=%5.5eg MAXUV=%5.5eg\n",MTOL1,MTOL2,MDEFLECTION,0.01);
#endif
if(MMAXUV>0.01) MMAXUV=0.01;
if(MDEFLECTION>0.1) MDEFLECTION = 0.1;
-#ifdef DEB
+#ifdef OCCT_DEBUG
// printf("TOL1 = %5.5eg TOL2=%5.5eg DEFL=%5.5eg MAXUV=%5.5eg\n",MTOL1,MTOL2,MDEFLECTION,MMAXUV);
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <Standard_Type.hxx>
Standard_EXPORT Standard_Boolean TopOpeBRepTool_GetcontextNOSEW() {
return TopOpeBRepTool_contextNOSEW; }
-// #ifdef DEB
+// #ifdef OCCT_DEBUG
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-#ifdef DEB
+#ifdef OCCT_DEBUG
#include <Standard_Type.hxx>
#include <TopOpeBRepTool_STATE.hxx>
Standard_EXPORT Standard_Boolean TopOpeBRepTool_GettraceCL2DPR()
{ return TopOpeBRepTool_CL2DPR.Get(); }
-// #ifdef DEB
+// #ifdef OCCT_DEBUG
#endif
j = (diff < 0.) ? 1 : 2;
}
}*/
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define M_Unknown (-100)
#else
#define M_Unknown (-100.)
#include <TransferBRep_ShapeMapper.hxx>
#include <TCollection_HAsciiString.hxx>
-#ifdef DEB
+#ifdef OCCT_DEBUG
#define DEBUG
#endif
if (!aOShell.IsNull()) {
aCShell = new StepShape_ClosedShell;
aCShell->Init (aOShell->Name(),aOShell->CfsFaces());
-#ifdef TOPODSTOSTEP_DEB
+#ifdef OCCT_DEBUG
cout<<"Warning: MakeBRepWithVoids: Open shell in the solid; treated as closed"<<endl;
#endif
}
else
S.Append(aCShell);
}
-#ifdef TOPODSTOSTEP_DEB
+#ifdef OCCT_DEBUG
else cout<<"*** MakeBRepWithVoids : Shell not mapped"<<endl;
#endif
}
-#ifdef TOPODSTOSTEP_DEB
+#ifdef OCCT_DEBUG
else cout << "Shell not mapped" << endl;
#endif
/* //:d7
S.Append(aCShell);
}
else {
-#ifdef DEBUG
+#ifdef OCCT_DEBUG
cout << "Shell not mapped" << endl;
#endif
done = Standard_False;
// a 3D Curve is constructed
// -------------------------
-#ifdef TOPODSTOSTEP_DEB
+#ifdef OCCT_DEBUG
cout << "Warning: TopoDSToStep_MakeStepEdge: edge without 3d curve; creating..." << endl;
#endif
if ((SA.GetType() == GeomAbs_Plane) &&
const TopoDS_Wire theOuterWire = BRepTools::OuterWire(ForwardFace);
if (theOuterWire.IsNull()) {
-#ifdef TOPODSTOSTEP_DEB
+#ifdef OCCT_DEBUG
cout<< "Warning : Face without wire not mapped";
#endif
FP->AddWarning(errShape, " Face without wire not mapped");
MkWire.Init(CurrentWire, aTool, FP);
if (MkWire.IsDone()) Loop = Handle(StepShape_Loop)::DownCast(MkWire.Value());
else {
-#ifdef TOPODSTOSTEP_DEB
+#ifdef OCCT_DEBUG
cout << TopoDSToStep::DecodeWireError(MkWire.Error()) << endl;
#endif
FP->AddWarning(errShape, " a Wire not mapped");
void TopoDSToStep_Tool::SetCurrentShell(const TopoDS_Shell& S)
{
-#ifdef TOPODSTOSTEP_DEB
+#ifdef OCCT_DEBUG
cout << "Process a Shell which is ";
switch(S.Orientation())
{
void TopoDSToStep_Tool::SetCurrentFace(const TopoDS_Face& F)
{
-#ifdef TOPODSTOSTEP_DEB
+#ifdef OCCT_DEBUG
cout << " Process a Face which is ";
switch(F.Orientation())
{
void TopoDSToStep_Tool::SetCurrentWire(const TopoDS_Wire& W)
{
-#ifdef TOPODSTOSTEP_DEB
+#ifdef OCCT_DEBUG
cout << " Process a Wire which is ";
switch(W.Orientation())
{
void TopoDSToStep_Tool::SetCurrentEdge(const TopoDS_Edge& E)
{
-#ifdef TOPODSTOSTEP_DEB
+#ifdef OCCT_DEBUG
cout << " Process Edge which is ";
switch(E.Orientation())
{
{
if (theEdge.Orientation() == TopAbs_INTERNAL ||
theEdge.Orientation() == TopAbs_EXTERNAL ) {
-#ifdef TOPODSTOSTEP_DEB
+#ifdef OCCT_DEBUG
cout <<"Warning: TopoDSToStep_WireframeBuilder::GetTrimmedCurveFromEdge: Edge is internal or external; dropped" << endl;
#endif
return Standard_False;
Gpms = MakeTrimmedCurve (gtpL.Value(), pmsP1, pmsP2, 0, length, Standard_True );
// (anEdge.Orientation() == TopAbs_FORWARD));
}
-#ifdef TOPODSTOSTEP_DEB
+#ifdef OCCT_DEBUG
else cout << "Warning: TopoDSToStep_WireframeBuilder::GetTrimmedCurveFromEdge: Null-length curve not mapped" << endl;
#endif
}
for (;It.More();It.Next()) {
TopoDS_Face curFace = TopoDS::Face(It.Value());
if (GetTrimmedCurveFromFace(curFace, aMap, aCurveList)) result = Standard_True;
-#ifdef TOPODSTOSTEP_DEB
+#ifdef OCCT_DEBUG
if(!result) {
cout << "ERROR extracting trimmedCurve from Face" << endl;
//BRepTools::Dump(curFace,cout); cout<<endl;
if(quantity->Name() == aquantity) return quantity;
}
-#ifdef UNITS_DEB
+#ifdef OCCT_DEBUG
cout<<"Warning: BAD Quantity = Units::Quantity(quantity('" << aquantity << "'))" << endl;
#endif
return nullquantity;
}
}
-#ifdef UNITS_DEB
+#ifdef OCCT_DEBUG
cout<<"Warning: BAD Quantity = Units::Quantity(unit('" << symbol << "'))" << endl;
#endif
return NULL;
lastunit = TCollection_AsciiString(aUnit);
Units_UnitSentence unitsentence(aUnit);
if(!unitsentence.IsDone()) {
-#ifdef UNITS_DEB
+#ifdef OCCT_DEBUG
cout<<"can not convert - incorrect unit => return 0.0"<<endl;
#endif
return 0.0;
lastunit = TCollection_AsciiString(aUnit);
Units_UnitSentence unitsentence(aUnit);
if(!unitsentence.IsDone()) {
-#ifdef UNITS_DEB
+#ifdef OCCT_DEBUG
cout<<"Warning: can not convert - incorrect unit => return 0.0"<<endl;
#endif
return 0.0;
}
}
-#ifdef UNITS_DEB
+#ifdef OCCT_DEBUG
cout<<" La grandeur physique "<<aquantity<<" n'existe pas."<<endl;
#endif
}
}
}
-#ifdef UNITS_DEB
+#ifdef OCCT_DEBUG
cout<<" La grandeur physique "<<aquantity<<" n'existe pas."<<endl;
#endif
}
{
ifstream file(afilename, ios::in);
if(!file) {
-#ifdef UNITS_DEB
+#ifdef OCCT_DEBUG
cout<<"unable to open "<<afilename<<" for input"<<endl;
#endif
return;
themeasurement=avalue;
Units_UnitSentence unit(aunit);
if(!unit.IsDone()) {
-#ifdef UNITS_DEB
+#ifdef OCCT_DEBUG
cout<<"can not create Units_Measurement - incorrect unit"<<endl;
#endif
myHasToken = Standard_False;
themeasurement = oldtoken->Multiplied(themeasurement);
themeasurement = newtoken->Divided(themeasurement);
}
-#ifdef UNITS_DEB
+#ifdef OCCT_DEBUG
else {
cout<<" The units don't have the same physical dimensions"<<endl;
}
if(!LastWord.IsIntegerValue()) {
// unknown expression - not create sentene
thesequenceoftokens->Clear();
-#ifdef UNITS_DEB
+#ifdef OCCT_DEBUG
cout<<"Warning: can not create correct sentence from string: "<<astring<<endl;
#endif
return;
( token->Mean()=="0" && ( PrevMean=="M" || PrevMean=="U" || PrevMean=="MU" ) ) ) {
// incorrect situation
thesequenceoftokens->Clear();
-#ifdef UNITS_DEB
+#ifdef OCCT_DEBUG
cout<<"Warning: can not create correct sentence from string: "<<astring<<endl;
#endif
return;
const
{
if(fabs(atoken->Value())<1.e-40) {
-#ifdef UNITS_DEB
+#ifdef OCCT_DEBUG
cout<<"Warning: division on token with value=0 => return initial token."<<endl;
#endif
return this;
ifstream file(afilename, ios::in);
if(!file) {
-#ifdef UNITS_DEB
+#ifdef OCCT_DEBUG
cout<<"unable to open "<<afilename<<" for input"<<endl;
#endif
return;
if(unitssequence->Length())
return unitssequence->Value(1)->SymbolsSequence()->Value(1)->String();
else {
-#ifdef UNITS_DEB
+#ifdef OCCT_DEBUG
cout<<" Pas d'unite active pour "<<aquantity<<endl;
#endif
return "";
if(index2)
return unitssequence->Value(index2)->SymbolsSequence()->Value(1)->String();
else {
-#ifdef UNITS_DEB
+#ifdef OCCT_DEBUG
cout<<" Pas d'unite active pour "<<aquantity<<endl;
#endif
return TCollection_AsciiString() ;
aValue = Units::ToSI(aData,current.ToCString());
aValue = LocalSystemUnits.ConvertSIValueToUserSystem(aQuantity,aValue);
}
-#ifdef UNITSAPI_DEB
+#ifdef OCCT_DEBUG
else {
cout <<"Warning: UnitsAPI,the quantity '" << aQuantity << "' does not exist in the current units system" << endl;
}
TCollection_AsciiString current(CurrentUnits->Value(aQuantity));
aValue = Units::ToSI(aData,current.ToCString());
}
-#ifdef UNITSAPI_DEB
+#ifdef OCCT_DEBUG
else {
cout<<"Warning: UnitsAPI,the quantity '" << aQuantity << "' does not exist in the current units system" << endl;
}
aValue = LocalSystemUnits.ConvertUserSystemValueToSI(aQuantity,aData);
aValue = Units::FromSI(aValue,current.ToCString());
}
-#ifdef UNITSAPI_DEB
+#ifdef OCCT_DEBUG
else {
cout<<"Warning: UnitsAPI,the quantity '" << aQuantity << "' does not exist in the current units system" << endl;
}
TCollection_AsciiString current(CurrentUnits->Value(aQuantity));
aValue = Units::FromSI(aData,current.ToCString());
}
-#ifdef UNITSAPI_DEB
+#ifdef OCCT_DEBUG
else {
cout<<"Warning: UnitsAPI,the quantity '" << aQuantity << "' does not exist in the current units system" << endl;
}
TCollection_AsciiString current(CurrentUnits->Value(aQuantity));
aValue = AnyToAny(aData,current.ToCString(),aUnit);
}
-#ifdef UNITSAPI_DEB
+#ifdef OCCT_DEBUG
else {
cout<<"Warning: UnitsAPI,the quantity '" << aQuantity << "' does not exist in the current units system" << endl;
}
TCollection_AsciiString current(CurrentUnits->Value(aQuantity));
aValue = AnyToAny(aData,aUnit,current.ToCString());
}
-#ifdef UNITSAPI_DEB
+#ifdef OCCT_DEBUG
else {
cout<<"Warning: UnitsAPI,the quantity '" << aQuantity << "' does not exist in the current units system" << endl;
}
if( quantity ) {
aValue = LocalSystemUnits.ConvertSIValueToUserSystem(quantity,aValue);
}
-#ifdef UNITSAPI_DEB
+#ifdef OCCT_DEBUG
else
cout<<"Warning: BAD Quantity returns in UnitsAPI::AnyToLS(" << aData << "," << aUnit << ")" << endl;
#endif
if( quantity ) {
aValue = LocalSystemUnits.ConvertSIValueToUserSystem(quantity,aValue);
}
-#ifdef UNITSAPI_DEB
+#ifdef OCCT_DEBUG
else
cout<<"Warning: BAD Quantity returns in UnitsAPI::AnyToLS(" << aData << "," << aUnit << "," << aDim << ")" << endl;
#endif
if( quantity ) {
aValue = LocalSystemUnits.ConvertUserSystemValueToSI(quantity,aValue);
}
-#ifdef UNITSAPI_DEB
+#ifdef OCCT_DEBUG
else
cout<<"Warning: BAD Quantity returns in UnitsAPI::AnyToLS(" << aData << "," << aUnit << ")" << endl;
#endif
if( CurrentUnits->Find(aQuantity) ) {
aValue = LocalSystemUnits.ConvertUserSystemValueToSI(aQuantity,aData);
}
-#ifdef UNITSAPI_DEB
+#ifdef OCCT_DEBUG
else {
cout<<"Warning: UnitsAPI,the quantity '" << aQuantity << "' does not exist in the current units system" << endl;
}
if( CurrentUnits->Find(aQuantity) ) {
aValue = LocalSystemUnits.ConvertSIValueToUserSystem(aQuantity,aValue);
}
-#ifdef UNITSAPI_DEB
+#ifdef OCCT_DEBUG
else {
cout<<"Warning: UnitsAPI,the quantity '" << aQuantity << "' does not exist in the current units system" << endl;
}
aCurve2d = aBSpline2d;
}
else if (aCurve2d->IsKind(STANDARD_TYPE(Geom2d_Parabola))) {
-#ifdef UNITSMETHODS_DEB
+#ifdef OCCT_DEBUG
cout << "PCURVE of Parabola type in U or V Periodic Surface" << endl;
cout << "Parameters Not transformed to Degree" << endl;
#endif
}
else if (aCurve2d->IsKind(STANDARD_TYPE(Geom2d_Hyperbola))) {
-#ifdef UNITSMETHODS_DEB
+#ifdef OCCT_DEBUG
cout << "PCURVE of Hyperbola type in U or V Periodic Surface" << endl;
cout << "Parameters Not transformed to Degree" << endl;
#endif
return myNewBSpline2d;
}
else {
-#ifdef UNITSMETHODS_DEB
+#ifdef OCCT_DEBUG
cout << "PCURVE of Other Types of Bounded Curve in U or V Periodic Surface" << endl;
cout << "Parameters Not transformed to Degree" << endl;
#endif
aPcurve = aBSpline2d;
}
else if (aPcurve->IsKind(STANDARD_TYPE(Geom2d_Parabola))) {
-#ifdef UNITSMETHODS_DEB
+#ifdef OCCT_DEBUG
cout << "PCURVE of Parabola type" << endl;
cout << "Parameters Not Yet transformed according to LenghtUnit" << endl;
#endif
return aPcurve;
}
else if (aPcurve->IsKind(STANDARD_TYPE(Geom2d_Hyperbola))) {
-#ifdef UNITSMETHODS_DEB
+#ifdef OCCT_DEBUG
cout << "PCURVE of Hyperbola type" << endl;
cout << "Parameters Not Yet transformed according to LenghtUnit" << endl;
#endif
aPcurve = aBSpline2d;
}
else {
-#ifdef UNITSMETHODS_DEB
+#ifdef OCCT_DEBUG
cout << "DegreeToRadian : Type " << aPcurve->DynamicType();
cout << " not yet implemented" << endl;
#endif
TCollection_AsciiString checkValid = check.Value();
Standard_Boolean ToCheck = Standard_True;
if (!checkValid.IsEmpty()) {
-#ifdef VIEWERTEST_DEB
+#ifdef OCCT_DEBUG
cout <<"DONT_SWITCH_IS_VALID positionnee a :"<<checkValid.ToCString()<<"\n";
#endif
if ( checkValid=="true" || checkValid=="TRUE" ) {
ToCheck= Standard_False;
}
} else {
-#ifdef VIEWERTEST_DEB
+#ifdef OCCT_DEBUG
cout <<"DONT_SWITCH_IS_VALID non positionne"<<"\n";
#endif
}
ViewerTest::Commands(theDI);
ViewerTest::AviCommands(theDI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
theDI << "Draw Plugin : OCC V2d & V3d commands are loaded" << "\n";
#endif
}
TopExp::Vertices(anEdgeFromA, aVertex1, aVertex2);
gp_Pnt A=BRep_Tool::Pnt(aVertex1);
-#ifdef DEB
+#ifdef OCCT_DEBUG
gp_Pnt C = BRep_Tool::Pnt(aVertex2);
#endif
MyGraphicDriver->Layer (MyCLayer);
MyCLayer.ptrLayer->layerData = this;
-#ifdef VISUAL3D_DEB
+#ifdef OCCT_DEBUG
cout << "Visual3d_Layer::Visual3d_Layer" << endl;
call_def_ptrLayer ptrLayer;
ptrLayer = (call_def_ptrLayer) MyCLayer.ptrLayer;
#ifdef TRACE_CALL
cout << "Visual3d_Layer::End" << endl;
#endif
-#ifdef VISUAL3D_DEB
+#ifdef OCCT_DEBUG
cout << "Visual3d_Layer::End" << endl;
call_def_ptrLayer ptrLayer;
ptrLayer = (call_def_ptrLayer) MyCLayer.ptrLayer;
// Flush all graphics
MyGraphicDriver->EndLayer ();
theLayerState = Standard_False;
-#ifdef VISUAL3D_DEB
+#ifdef OCCT_DEBUG
cout << "Visual3d_Layer::End" << endl;
ptrLayer = (call_def_ptrLayer) MyCLayer.ptrLayer;
if (ptrLayer == NULL)
#ifdef TRACE_CALL
cout << "Visual3d_Layer::CLayer" << endl;
#endif
-#ifdef VISUAL3D_DEB
+#ifdef OCCT_DEBUG
cout << "Visual3d_Layer::CLayer" << endl;
call_def_ptrLayer ptrLayer;
ptrLayer = (call_def_ptrLayer) MyCLayer.ptrLayer;
const VrmlData_Scene * myScene;
const char * myName; ///< name of the node
-#ifdef _DEBUG
+#ifdef OCCT_DEBUG
Standard_Integer myLineCount;
#endif
Handle(TDataStd_TreeNode) Node;
if (! L.FindAttribute(XCAFDoc::ShapeRefGUID(), Node) ||
! Node->HasFather()) {
-#ifdef XCAFDOC_DEB
+#ifdef OCCT_DEBUG
cout<<"Error: XCAFDoc_ShapeTool, SetLabelNameByLink(): NO NODE"<<endl;
#endif
return;
Handle(Standard_Transient) XCAFDrivers::Factory(const Standard_GUID& aGUID) {
if(aGUID == XCAFSchemaID) {
-#ifdef XCAFDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "XCAFSchema : Plugin" << endl;
#endif
static Handle(XCAFSchema) model_ss;
if(aGUID == XSStorageDriver)
{
-#ifdef XCAFDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "XCAFDrivers : Storage Plugin" << endl;
#endif
static Handle(XCAFDrivers_DocumentStorageDriver) model_sd
}
if(aGUID == XSRetrievalDriver)
{
-#ifdef XCAFDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "XCAFDrivers : Retrieval Plugin" << endl;
#endif
static Handle (XCAFDrivers_DocumentRetrievalDriver) model_rd
continue;
// set style for all component from Next Usage Occurrence.
-#ifdef XCAFPRS_DEB
+#ifdef OCCT_DEBUG
cout << "Set the style for SHUO next_usage-occurrance" << endl;
#endif
/*
XDEDRAW::Init(theDI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
theDI << "Draw Plugin : All TKXDEDRAW commands are loaded" << "\n";
#endif
}
char string9[260];
Sprintf (string9, "%40.40s", "exception" );
di << string9;
-#ifdef DEB
+#ifdef OCCT_DEBUG
//fflush ( stdout );
di << ": ";
di << Standard_Failure::Caught()->GetMessageString();
TCollection_AsciiString str ( seq );
str += ".exec.op";
if ( ! rsc->Find ( str.ToCString() ) ) {
-#ifdef XSALGO_DEB
+#ifdef OCCT_DEBUG
{
static Standard_Integer time = 0;
if ( ! time )
}
}
catch (Standard_Failure) {
-#ifdef XSALGO_DEB
+#ifdef OCCT_DEBUG
cout << "Error: XSAlgo_AlgoContainer::ProcessShape(): Exception in ShapeFix::Shape" << endl;
Standard_Failure::Caught()->Print(cout); cout << endl;
#endif
}
}
catch (Standard_Failure) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
cout << "Error: XSAlgo_AlgoContainer::PerformFixShape(): Exception in ShapeFix::Shape" << endl;
#endif
}
Standard_Real DV = Abs (PUV1.Y() - PUV2.Y());
if ( DU/8. > (UL/6. - UF/6.) || DV/8. > (VL/6. - VF/6.) ) {
ShapeBuild_Edge().RemovePCurve(E,face);
-#ifdef XSALGO_DEB
+#ifdef OCCT_DEBUG
cout<<"Removing pcuve periodic"<<endl;
#endif
return Standard_False;
if (!((Dist11 <= preci) && (Dist22 <= preci))) {
ShapeBuild_Edge().RemovePCurve(E,face);
-#ifdef XSALGO_DEB
+#ifdef OCCT_DEBUG
cout<<"Removing pcurve points"<<endl;
#endif
return Standard_False;
else if ( TransientListBinder->NbTransients() > 1 ) {
resBinder->AddResult(TransientListBinder);
// resBinder->SetNext(TransientListBinder, Standard_True);
-#ifdef XSALGO_DEB
+#ifdef OCCT_DEBUG
cout<<"Info: TransientListBinder created for splitted shape"<<endl;
}
else {
XSDRAWSTEP::InitCommands(theDI);
XSDRAWSTLVRML::InitCommands(theDI);
XSDRAW::LoadDraw(theDI);
-#ifdef DEB
+#ifdef OCCT_DEBUG
theDI << "Draw Plugin : All TKXSDRAW commands are loaded" << "\n";
#endif
}
{
if (theGUID == XmlStorageDriver)
{
-#ifdef XMLDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "XmlDrivers : Storage Plugin" << endl;
#endif
static Handle(XmlDrivers_DocumentStorageDriver) model_sd =
if (theGUID == XmlRetrievalDriver)
{
-#ifdef XMLDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "XmlDrivers : Retrieval Plugin" << endl;
#endif
static Handle (XmlDrivers_DocumentRetrievalDriver) model_rd =
{
if (theGUID == XmlLStorageDriver)
{
-#ifdef XMLLDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "XmlLDrivers : Storage Plugin" << endl;
#endif
static Handle(XmlLDrivers_DocumentStorageDriver) model_sd =
if (theGUID == XmlLRetrievalDriver)
{
-#ifdef XMLLDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "XmlLDrivers : Retrieval Plugin" << endl;
#endif
static Handle (XmlLDrivers_DocumentRetrievalDriver) model_rd =
if (time(&nowbin) == (time_t) - 1)
{
-#ifdef XMLLDRIVERS_DEB
+#ifdef OCCT_DEBUG
cerr << "Storage ERROR : Could not get time of day from time()" << endl;
#endif
}
if (strftime(nowstr, SLENGTH, "%Y-%m-%d", nowstruct) == (size_t) 0)
{
-#ifdef XMLLDRIVERS_DEB
+#ifdef OCCT_DEBUG
cerr << "Storage ERROR : Could not get string from strftime()" << endl;
#endif
}
try
{
OCC_CATCH_SIGNALS
-#if defined(DEB) && !defined(TAKE_TIMES)
+#ifdef OCCT_DEBUG
TCollection_ExtendedString aMessage ("PasteDocument");
aMsgDriver -> Write (aMessage.ToExtString());
#endif
aResourceDir += "/src/XmlOcafResource" ;
aToSetCSFVariable = Standard_True; //CSF variable to be set later
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
else {
TCollection_ExtendedString aWarn = FAILSTR "Neither ";
aWarn = (aWarn + aCSFVariable[0] + ", nor " + aCSFVariable[1]
if (aToSetCSFVariable) {
OSD_Environment aCSFVarEnv ( aCSFVariable[0], aResourceDir );
aCSFVarEnv.Build();
-#ifdef DEB
+#ifdef OCCT_DEBUG
TCollection_ExtendedString aWarn1 = "Variable ";
aWarn1 = (aWarn1 + aCSFVariable[0]
+ " has not been explicitly defined. Set to " + aResourceDir);
}
}
}
-#ifdef DEB
+#ifdef OCCT_DEBUG
else {
TCollection_ExtendedString aWarn = FAILSTR "Schema definition file ";
aWarn += (aResourceFileName + " was not found");
// Retrieve from DOM_Document
XmlMDF::FromTo (aTDF, theElement, myRelocTable, myDrivers);
-#if defined(DEB) && !defined(TAKE_TIMES)
+#ifdef OCCT_DEBUG
aMessage = "First step successfull";
aMessageDriver -> Write (aMessage.ToExtString());
#endif
return myRelocTable.Extent();
}
-#ifdef XMLLDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "First step failed" << endl; // No MessageDriver available
#endif
return -1; // error
// Paste
aDriver -> Paste (tAtt, pAtt, theRelocTable);
}
-#ifdef XMLMDF_DEB
+#ifdef OCCT_DEBUG
else if (!UnsuppTypesMap().Contains (aType))
{
cout << "attribute driver for type "<< aType -> Name()<< " not found"<< endl;
#ifdef DATATYPE_MIGRATION
TCollection_AsciiString newName;
if(Storage_Schema::CheckTypeMigration(aName, newName)) {
-#ifdef DATATYPE_MIGRATION_DEB
+#ifdef OCCT_DEBUG
cout << "CheckTypeMigration:OldType = " <<aName.GetString() << " Len = "<<strlen(aName.GetString())<<endl;
cout << "CheckTypeMigration:NewType = " <<newName << " Len = "<< newName.Length()<<endl;
#endif
else if (isBound == Standard_False)
theRelocTable.Bind (anID, tAtt);
}
-#ifdef XMLMDATASTD_DEB
+#ifdef OCCT_DEBUG
else
{
const TCollection_AsciiString anAsciiName = aName;
else
aDelta = (Standard_Boolean)aDeltaValue;
}
-#ifdef XMLMDATASTD_DEB
+#ifdef OCCT_DEBUG
else if(XmlMDataStd::DocumentVersion() == -1)
cout << "Current DocVersion field is not initialized. " <<endl;
#endif
else
aDelta = (Standard_Boolean)aDeltaValue;
}
-#ifdef XMLMDATASTD_DEB
+#ifdef OCCT_DEBUG
else if(XmlMDataStd::DocumentVersion() == -1)
cout << "Current DocVersion field is not initialized. " <<endl;
#endif
else
aDelta = (Standard_Boolean)aDeltaValue;
}
-#ifdef XMLMDATASTD_DEB
+#ifdef OCCT_DEBUG
else if(XmlMDataStd::DocumentVersion() == -1)
cout << "Current DocVersion field is not initialized. " <<endl;
#endif
else
aDelta = (Standard_Boolean)aDeltaValue;
}
-#ifdef XMLMDATASTD_DEB
+#ifdef OCCT_DEBUG
else if(XmlMDataStd::DocumentVersion() == -1)
cout << "Current DocVersion field is not initialized. " <<endl;
#endif
else
aDelta = (Standard_Boolean)aDeltaValue;
}
-#ifdef XMLMDATASTD_DEB
+#ifdef OCCT_DEBUG
else if(XmlMDataStd::DocumentVersion() == -1)
cout << "Current DocVersion field is not initialized. " <<endl;
#endif
if (anEntry.Length() > 0) {
TDF_Tool::Label(aNg->Label().Data(), anEntry, tLab, Standard_True);
aNgName.ContextLabel(tLab);
-#ifdef XMLMNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "Retrieving Context Label = " << anEntry.ToCString() <<endl;
#endif
}
}
-#ifdef XMLMNAMING_DEB
+#ifdef OCCT_DEBUG
else
cout << "Retrieving Context Label is NULL" <<endl;
#endif
}
// or. end
}
-#ifdef XMLMNAMING_DEB
+#ifdef OCCT_DEBUG
else if(XmlMNaming::DocumentVersion() == -1)
cout << "Current DocVersion field is not initialized. " <<endl;
else
XmlObjMgt_DOMString aDOMString;
XmlObjMgt::SetTagEntryString (aDOMString, anEntry);
anElem.setAttribute(::ContextLabelString(), aDOMString);
-#ifdef XMLMNAMING_DEB
+#ifdef OCCT_DEBUG
cout << "XmlMNaming_NamingDriver::Store: ContextLabel Entry = " << anEntry << endl;
if (aDOMString != NULL)
{
// The location is not identity
if( myLocations == 0 )
{
-#ifdef XMLMXCAFDOC_DEB
+#ifdef OCCT_DEBUG
cout<<"Pointer to LocationSet is NULL\n";
#endif
return;
{
if(aGUID == XmlStorageDriver)
{
-#ifdef XMLTOBJDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "XmlTObjDrivers : Storage Plugin" << endl;
#endif
static Handle(XmlTObjDrivers_DocumentStorageDriver) model_sd
if(aGUID == XmlRetrievalDriver)
{
-#ifdef XMLTOBJDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "XmlTObjDrivers : Retrieval Plugin" << endl;
#endif
static Handle (XmlTObjDrivers_DocumentRetrievalDriver) model_rd
{
if(aGUID == XSStorageDriver)
{
-#ifdef XMLXCAFDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "XmlXCAFDrivers : Storage Plugin" << endl;
#endif
static Handle(XmlXCAFDrivers_DocumentStorageDriver) model_sd
}
if(aGUID == XSRetrievalDriver)
{
-#ifdef XMLXCAFDRIVERS_DEB
+#ifdef OCCT_DEBUG
cout << "XmlXCAFDrivers : Retrieval Plugin" << endl;
#endif
static Handle (XmlXCAFDrivers_DocumentRetrievalDriver) model_rd
// 10/09/97 : PMN : Correction BUC40192 (pb avec les matrices negatives)
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_OutOfRange
#define No_Standard_ConstructionError
#endif
// 10/09/97 : PMN : Correction BUC40192 (pb avec les matrices negatives)
-#ifndef DEB
+#ifndef OCCT_DEBUG
#define No_Standard_OutOfRange
#define No_Standard_ConstructionError
#endif
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// lpa le 20/08/91
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
#define EPSEPS 2e-14
#define MAXBIS 100
-# ifdef DEB
+#ifdef OCCT_DEBUG
static Standard_Boolean myDebug = 0;
static Standard_Integer nbsolve = 0;
-# endif
+#endif
static void AppendRoot(TColStd_SequenceOfReal& Sol,
TColStd_SequenceOfInteger& NbStateSol,
Standard_Integer n=Sol.Length();
Standard_Real t;
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (myDebug) {
cout << " Ajout de la solution numero : " << n+1 << endl;
cout << " Valeur de la racine :" << X << endl;
const Standard_Real dX,
TColStd_SequenceOfReal& Sol,
TColStd_SequenceOfInteger& NbStateSol) {
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (myDebug) {
cout <<"--> Resolution :" << ++nbsolve << endl;
cout <<" x1 =" << x1 << " y1 =" << y1 << endl;
F.Value(b,fb);
fb-=K;
}
-#ifdef MATH_DEB
+#ifdef OCCT_DEBUG
cout<<" Non Convergence dans math_FunctionRoots.cxx "<<endl;
#endif
}
const Standard_Real EpsNull,
const Standard_Real K )
{
-#ifdef DEB
+#ifdef OCCT_DEBUG
if (myDebug) {
cout << "---- Debut de math_FunctionRoots ----" << endl;
nbsolve = 0;
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// pmn 10/06/97 refonte totale du traitement des bords + ajustement des init
// et des tolerances pour brent...
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
*/
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
*/
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
#define _MEMORY_H
#endif
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
// Implementation de la classe resolvant les equations en cosinus-sinus.
// Equation de la forme a*cos(x)*cos(x)+2*b*cos(x)*sin(x)+c*cos(x)+d*sin(x)+e
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError
if(Abs(va)>Eps) {
bko=Standard_True;
nbko++;
-#ifdef DEB
+#ifdef OCCT_DEBUG
//if(nbko==1) {
// cout<<"Pb ds math_TrigonometricFunctionRoots CC="
// <<A<<" CS="<<B<<" C="<<C<<" S="<<D<<" Cte="<<E<<endl;
// coordonnee car il est plus long d utiliser les methodes deja ecrites
// de la classe Matrix avec un passage par valeur.
-//#ifndef DEB
+//#ifndef OCCT_DEBUG
#define No_Standard_RangeError
#define No_Standard_OutOfRange
#define No_Standard_DimensionError