0027525: Coding - eliminate warnings on Windows for OCCT with static type of libraries
[occt.git] / src / TopOpeBRepDS / TopOpeBRepDS_FIR.cxx
index a248b85..34ff41d 100644 (file)
 #define MDSke TopOpeBRepDS_EDGE
 #define MDSkf TopOpeBRepDS_FACE
 
-#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) 
-{
-  cout<<str<<"   G : "<<BDS.Shape(SG)<<"   S : ";
-  for(TopOpeBRepDS_ListIteratorOfListOfInterference it(loi);it.More();it.Next()) cout<<it.Value()->Support()<<" "; 
-  cout<<endl;cout.flush();
-}
-void FUN_dumpmosd(TopOpeBRepDS_MapOfShapeData& mosd,const TopOpeBRepDS_DataStructure& BDS,const Standard_Integer F,TCollection_AsciiString str) 
-{
-  cout<<str<<"GmapS sur ";TopAbs::Print(BDS.Shape(F).ShapeType(),cout);
-  cout<<" "<<F<<" : "<<mosd.Extent()<<" (GK EDGE)(SK FACE)"<<endl;
-  for(Standard_Integer i=1,n=mosd.Extent();i<=n;i++) {
-    FUN_dumploiS(mosd.FindKey(i),mosd.FindFromIndex(i).Interferences(),BDS,str);
-  }
-}
-#endif
-
-#ifdef OCCT_DEBUG
-extern Standard_Boolean TopOpeBRepDS_GettraceSTRANGE();
-extern Standard_Boolean TopOpeBRepDS_GettracePEI();
-extern Standard_Boolean TopOpeBRepDS_GettracePFI();
-extern Standard_Boolean TopOpeBRepDS_GettracePI();
-extern Standard_Boolean TopOpeBRepDS_GettraceSPSX(const Standard_Integer);
-static Standard_Boolean FTRCF(const Standard_Integer F) {
-  Standard_Boolean b1 = TopOpeBRepDS_GettracePFI();
-  Standard_Boolean b2 = TopOpeBRepDS_GettracePI();
-  Standard_Boolean b3 = TopOpeBRepDS_GettraceSPSX(F);
-  return (b1 || b2 || b3);
-}
-static Standard_Boolean FTRCE(const Standard_Integer E) {
-  Standard_Boolean b1 = TopOpeBRepDS_GettracePEI();
-  Standard_Boolean b2 = TopOpeBRepDS_GettracePI();
-  Standard_Boolean b3 = TopOpeBRepDS_GettraceSPSX(E);
-  return (b1 || b2 || b3);
-}
-#endif
-
 Standard_EXPORT Standard_Boolean FUN_Parameters(const gp_Pnt& Pnt,const TopoDS_Shape& F,Standard_Real& u,Standard_Real& v);
 Standard_EXPORT Standard_Boolean FUN_edgeofface(const TopoDS_Shape& E,const TopoDS_Shape& F);
 
@@ -157,48 +118,9 @@ Standard_Boolean FUN_findPonF(const TopoDS_Edge& E,const TopOpeBRepDS_DataStruct
 }
 
 // --------------------------------------------------------
-static void FDS_DUMPTRANSITION(const Standard_Boolean
-#ifdef OCCT_DEBUG
-                                                      TRCF
-#endif 
-                               ,const TCollection_AsciiString&
-#ifdef OCCT_DEBUG
-                                                      str
-#endif 
-                               ,const Standard_Integer
-#ifdef OCCT_DEBUG
-                                                      iFI
-#endif 
-                               ,TopOpeBRepDS_FaceInterferenceTool&
-#ifdef OCCT_DEBUG
-                                                                   FITool
-#endif 
-                               )
-{
-#ifdef OCCT_DEBUG
-  if (TRCF) {
-    cout<<str<<iFI<<endl;
-    Handle(TopOpeBRepDS_Interference) IBID = new TopOpeBRepDS_Interference();
-    FITool.Transition(IBID);
-    IBID->Transition().Dump(cout);cout<<endl;
-  }
-#endif
-}
-
-// --------------------------------------------------------
-static void FDS_ADDEDGE
-(const Standard_Boolean
-#ifdef OCCT_DEBUG
-                        TRCF
-#endif 
- ,const TCollection_AsciiString&
-#ifdef OCCT_DEBUG
-                                 str
-#endif 
- ,const Standard_Integer
-#ifdef OCCT_DEBUG
-                        iFI // DEB args
-#endif 
+static void FDS_ADDEDGE (const Standard_Boolean
+ , const TCollection_AsciiString&
+ , const Standard_Integer
  ,TopOpeBRepDS_FaceInterferenceTool& FITool
  ,const TopoDS_Shape& FI
  ,const TopoDS_Shape& F
@@ -207,13 +129,7 @@ static void FDS_ADDEDGE
  ,const Handle(TopOpeBRepDS_Interference)& I
 )
 {
-#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 OCCT_DEBUG
-  FDS_DUMPTRANSITION(TRCF,"--> resultat partiel sur face ",iFI,FITool);
-#endif
 }
 
 //------------------------------------------------------
@@ -224,12 +140,6 @@ void FUN_reduceEDGEgeometry1
  const TopOpeBRepDS_DataMapOfShapeListOfShapeOn1State& )
 {
   Standard_Boolean TRCF = Standard_False;
-#ifdef OCCT_DEBUG
-  Standard_Boolean TRCE = Standard_False;
-  TRCE = FTRCE(iEG);if (TRCE) debrededg(iEG);
-  TRCF = FTRCF(iFI);if (TRCF) debredfac(iFI);
-#endif
-
   TopOpeBRepDS_ListIteratorOfListOfInterference ili(LI); if (!ili.More()) return; 
 
   // choix de l'arete Ecpx, lieu de resolution de la transition complexe
@@ -287,9 +197,6 @@ void FUN_reduceEDGEgeometry1
         
 //     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 OCCT_DEBUG
-//     if ((TRCE || TRCF) && revT1) cout<<"-> REVERSE T"<<endl;
-#endif
 //     if (revT1) I1->ChangeTransition() = T1.Complement();  //xpu :090498
        FITool.Init(FI,Ecpx,isEGsp,I1);
        FDS_ADDEDGE(TRCF,"\ninit transition complexe F",iFI,FITool,FI,F1,Ecpx,isEGsp,I1);
@@ -298,9 +205,6 @@ void FUN_reduceEDGEgeometry1
     
 //      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 OCCT_DEBUG
-//     if ((TRCE || TRCF) && revT2) cout<<"-> REVERSE T"<<endl;
-#endif 
 //      if (revT2) I2->ChangeTransition() = T2.Complement();  //xpu :090498
       FDS_ADDEDGE(TRCF,"add transition complexe F",iFI,FITool,FI,F2,Ecpx,isEGsp,I2);
 //      if (revT2) I2->ChangeTransition() = T2.Complement();  //xpu :090498 
@@ -309,7 +213,6 @@ void FUN_reduceEDGEgeometry1
     }
     if (isComplex) {
       FITool.Transition(I1);
-      FDS_DUMPTRANSITION(TRCF,"--> result transition on face ",iFI,FITool); // DEB
     }
     it1.Next();
   }  // it1.More()
@@ -360,12 +263,6 @@ const TopOpeBRepDS_DataMapOfShapeListOfShapeOn1State& MEsp)
   TopOpeBRepDS_MapOfShapeData mosd; 
   FUN_GmapS(LI,BDS,mosd);
 
-#ifdef OCCT_DEBUG
-  Standard_Boolean TRC = FTRCF(iFI); 
-  if (TRC) FUN_dumpmosd(mosd,BDS,iFI,"");
-  if (TRC) debredfac(iFI);
-#endif
-  
   TopOpeBRepDS_ListOfInterference LIout;
   //modified by NIZNHY-PKV Thu Mar 16 09:44:24 2000 f
   Standard_Integer i, aN;
@@ -381,21 +278,10 @@ const TopOpeBRepDS_DataMapOfShapeListOfShapeOn1State& MEsp)
     Standard_Boolean egissect = BDS.IsSectionEdge(TopoDS::Edge(EG));
     Standard_Boolean eghasesd = (! esdeg.IsEmpty());
 
-#ifdef OCCT_DEBUG
-//    Standard_Integer egiref = BDS.SameDomainRef(iEG);
-//    Standard_Integer egisref = (iEG == egiref);
-//    TopOpeBRepDS_Config egc = BDS.SameDomainOri(iEG);
-#endif
-
     TopOpeBRepDS_ListOfInterference& LIEG = mosd.ChangeFromKey(EG).ChangeInterferences();
     Standard_Integer nExt = LIEG.Extent();
     // LIEG = toutes les interferences dont le Support() est une 
     // face possedant une interference dont la Geometry() est EG.
-    
-#ifdef OCCT_DEBUG
-    if (TRC) FUN_dumploiS(EG,LIEG,BDS,"   ");
-#endif
-    
     if      (nExt == 0) {
       continue;
     }
@@ -522,58 +408,15 @@ void TopOpeBRepDS_FIR::ProcessFaceInterferences
 (const Standard_Integer SIX,const TopOpeBRepDS_DataMapOfShapeListOfShapeOn1State& MEsp)
 {
   TopOpeBRepDS_DataStructure& BDS = myHDS->ChangeDS();
-
-#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 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 OCCT_DEBUG
-  Standard_Integer nF, nFE, nFEF, nE;
-#endif
-
   ::FUN_selectTRASHAinterference(lw,TopAbs_FACE,lF);
   ::FUN_selectGKinterference(lF,MDSke,lFE);
   ::FUN_selectSKinterference(lFE,MDSkf,lFEF);
   ::FUN_selectTRASHAinterference(lw,TopAbs_EDGE,lE);
-
-#ifdef OCCT_DEBUG
-  nF = lF.Extent();
-  nFE = lFE.Extent();
-  nFEF = lFEF.Extent();
-  nE = lE.Extent();
-  if(TRC){
-    if(nF||nFE||nFEF||nE){cout<<endl;cout<<"-----------------------"<<endl;}
-    if(nF) {cout<<"FACE "<<SIX<<" (FACE) : "<<nF<<endl;FDS_dumpLI(lF,"  ");}
-    if(nFE){cout<<"FACE "<<SIX<<" (FACE)(GK EDGE) : "<<nFE<<endl;FDS_dumpLI(lFE,"  ");}
-    if(nFEF){cout<<"FACE "<<SIX<<" (FACE)(GK EDGE)(SK FACE) : "<<nFEF<<endl;FDS_dumpLI(lFEF,"  ");}
-    if(nE) {cout<<"FACE "<<SIX<<" (EDGE) : "<<nE<<endl;FDS_dumpLI(lE,"  ");}
-  }
-#endif
-
   FUN_reduceEDGEgeometry(lFEF,BDS,SIX,MEsp);
 
-#ifdef OCCT_DEBUG
-  nF = lF.Extent();
-  nFE = lFE.Extent();
-  nFEF = lFEF.Extent();
-  nE = lE.Extent();
-  if(TRC){
-    if(nF||nFE||nFEF||nE)cout<<endl;
-    if(nF) {cout<<"FACE "<<SIX<<" (FACE) : "<<nF<<endl;FDS_dumpLI(lF,"  ");}
-    if(nFE){cout<<"FACE "<<SIX<<" (FACE)(GK EDGE) : "<<nFE<<endl;FDS_dumpLI(lFE,"  ");}
-    if(nFEF){cout<<"FACE "<<SIX<<" (FACE)(GK EDGE)(SK FACE) : "<<nFEF<<endl;FDS_dumpLI(lFEF,"  ");}
-    if(nE) {cout<<"FACE "<<SIX<<" (EDGE) : "<<nE<<endl;FDS_dumpLI(lE,"  ");}
-    cout<<"-----------------------"<<endl;
-  }
-#endif
-
   LI.Clear();
   LI.Append(lF);
   LI.Append(lFE);