const Standard_Boolean AcceptEraseOfObj ) {
if ( !IsCurrent( myLastPicked ) )
if ( !myLastPicked.IsNull() ) {
-#ifdef DEB
- AIS2D_TypeOfDetection HiMod = myLastPicked -> HasHighlightMode() ?
- myLastPicked->HighlightMode() : myLastPicked->DefaultHighlightMode();
-#endif
myLastPicked->Unhighlight();
}
if ( GoodIndex == myCurLocalIndex ) {
myCurLocalIndex = HighestIndex();
-#ifdef DEB
- const Handle(AIS2D_LocalContext)& LocCtx = myLocalContexts(myCurLocalIndex);
-#endif
}
}
break;
}
case AIS2D_DS_Erased: {
-#ifdef DEB
- Standard_Integer HiMode = anIObj->HasHighlightMode() ?
- anIObj->HighlightMode() : anIObj->DefaultHighlightMode();
-#endif
anIObj->Highlight(myCollectorVwr->InitializeColor( mySelectionColor ));
if ( updateVwr ) myCollectorVwr->Update();
break;
}
case AIS2D_DS_Erased: {
#ifdef DEB
- Standard_Integer HiMode = anIObj->HasHighlightMode()? anIObj->HighlightMode():0;
Standard_Integer indCol = myCollectorVwr->InitializeColor( aCol );
#endif
if ( updateVwr) myCollectorVwr->Update();
myLocalContexts( myCurLocalIndex )->SetSelected( myLastPicked, UpdateVwr );
return AIS2D_SOP_OneSelected;
}
-#ifdef DEB
- AIS2D_StatusOfPick PS( AIS2D_SOP_NothingSelected );
-#endif
-
+
if ( ! mySeqOfDetIO->IsEmpty() ) {
Handle(AIS2D_InteractiveObject) theIO;
Handle(AIS2D_HSequenceOfPrimArchit) thePA;
}
if ( !myLastPicked.IsNull() )
if ( !myLastPicked->State() ) {
-#ifdef DEB
- AIS2D_TypeOfDetection HiMod = myLastPicked->HasHighlightMode() ?
- myLastPicked->HighlightMode() : myLastPicked->DefaultHighlightMode();
-#endif
- myLastPicked->Unhighlight();
+ myLastPicked->Unhighlight();
UpdVwr = Standard_True;
} // end if the last picked object isn't selected one
}
case AIS2D_TOD_VERTEX: {
myLastPickPrim = myLastPicked->Primitive(myLastPicked->PickedIndex());
-#ifdef DEB
- Standard_Integer pInd = myLastPicked->PickedIndex();
-#endif
if ( myLastPickPrim != myLastSelPrim ||
( myLastPickPrim == myLastSelPrim &&
myLastPickPrim->PickedIndex() != myLastSelElInd ) ||
}
}
-#ifdef DEB
- AlienImage_X11XColor *p = ( AlienImage_X11XColor * )myColors ;
-#endif
-
#ifdef TRACE
if ( Verbose ) {
AlienImage_X11XColor *p = ( AlienImage_X11XColor * )myColors;
static Standard_Integer nbappel = 0;
Standard_Integer i;
Standard_Integer nbpoles = C.NbPoles();
- Standard_Integer deg = C.Degree();
Handle(Geom_BezierCurve) BSp;
Handle(Geom2d_BezierCurve) BSp2d;
Param(1) = u1; Param(2) = v1;
Param(3) = u2; Param(4) = v2;
math_FunctionSetRoot Rsnld(MyIntersectionOn2S.Function());
-#ifdef DEB
- IntImp_ConstIsoparametric ChoixIso = MyIntersectionOn2S.Perform(Param,Rsnld);
-#else
MyIntersectionOn2S.Perform(Param,Rsnld);
-#endif
if (!MyIntersectionOn2S.IsDone()) {
MyHasBeenComputed = MyHasBeenComputedbis = Standard_False;
return(Standard_False);
BOPTools_ListIteratorOfListOfCommonBlock anItCB(aLCB);
for (; anItCB.More(); anItCB.Next()) {
BOPTools_CommonBlock& aCB=anItCB.Value();
- BOPTools_PaveBlock& aPB1=aCB.PaveBlock1(nE1);
+ //BOPTools_PaveBlock& aPB1=aCB.PaveBlock1(nE1);
BOPTools_PaveBlock& aPB2=aCB.PaveBlock2(nE1);
nE=aPB2.OriginalEdge();
if (nE==nE2) {
for( iKey = 1; iKey <= nbKeys; iKey++ ) {
const TopoDS_Vertex& iV = TopoDS::Vertex(mapVE.FindKey(iKey));
if( iV.IsNull() ) continue;
- Standard_Real TolV = BRep_Tool::Tolerance(iV);
+ //Standard_Real TolV = BRep_Tool::Tolerance(iV);
const TopTools_ListOfShape& iLE = mapVE.FindFromIndex(iKey);
Standard_Integer nbE = iLE.Extent();
if( nbE != 2 ) {
const TopoDS_Face& aF1 = BS1.Face();
- Standard_Real maxTolE1 = 1.e-7, maxTolV1 = 1.e-7;
+ Standard_Real maxTolE1 = 1.e-7;
Standard_Integer nbE1 = 0, nbOnE1 = 0;
for(anExpE.Init(aF1, TopAbs_EDGE); anExpE.More(); anExpE.Next()) {
const TopoDS_Edge& aE = TopoDS::Edge(anExpE.Current());
return Standard_False;
const TopoDS_Face& aF2 = BS1.Face();
- Standard_Real maxTolE2 = 1.e-7, maxTolV2 = 1.e-7;
+ Standard_Real maxTolE2 = 1.e-7;
Standard_Integer nbE2 = 0, nbOnE2 = 0;
for(anExpE.Init(aF2, TopAbs_EDGE); anExpE.More(); anExpE.Next()) {
const TopoDS_Edge& aE = TopoDS::Edge(anExpE.Current());
// define face/face intersection tolerances
Standard_Boolean forcetoli = Standard_False;
if (forcetoli) {
-#ifndef DEB
Standard_Real tolarc=0,toltang=0;
-#else
- Standard_Real tolarc,toltang;
-#endif
TopOpeBRep_ShapeIntersector& tobsi = DSFiller.ChangeShapeIntersector();
TopOpeBRep_FacesIntersector& tobfi = tobsi.ChangeFacesIntersector();
tobfi.ForceTolerances(tolarc,toltang);
math_Matrix gradsol(1, 2, 1, 2);
Standard_Real prm = P.Parameter();
-#ifdef DEB
- Standard_Integer NbSpan = (Poles.Length() - 1) / 2;
-#endif
Standard_Integer low = Poles.Lower();
Standard_Integer upp = Poles.Upper();
Standard_Boolean istgt;
math_Matrix gradsol(1, 2, 1, 2);
Standard_Real prm = P.Parameter();
-#ifdef DEB
- Standard_Integer NbSpan = (Poles.Length() - 1) / 2;
-#endif
Standard_Integer low = Poles.Lower();
Standard_Integer upp = Poles.Upper();
Standard_Boolean istgt;
Standard_Real normd1gui = d1gui.Magnitude();
Standard_Real unsurnormd1gui = 1./normd1gui;
gp_Vec nplan = d1gui.Multiplied(unsurnormd1gui);
-#ifdef DEB
- Standard_Real theD = -(nplan.XYZ().Dot(ptgui.XYZ()));
-#endif
gp_Vec dnplan;
dnplan.SetLinearForm(-nplan.Dot(d2gui),nplan,d2gui);
dnplan.Multiply(unsurnormd1gui);
ray=sg1*ray;
dray=sg1*dray;
gp_Vec nplan = d1gui.Multiplied(unsurnormd1gui);
-#ifdef DEB
- Standard_Real theD = -(nplan.XYZ().Dot(ptgui.XYZ()));
-#endif
gp_Vec dnplan;
dnplan.SetLinearForm(-nplan.Dot(d2gui),nplan,d2gui);
dnplan.Multiply(unsurnormd1gui);
math_Matrix gradsol(1,3,1,3);
Standard_Real prm = P.Parameter();
-#ifdef DEB
- Standard_Integer NbSpan=(Poles.Length()-1)/2;
-#endif
Standard_Integer low = Poles.Lower();
Standard_Integer upp = Poles.Upper();
Standard_Boolean istgt;
math_Matrix gradsol(1,3,1,3);
Standard_Real prm = P.Parameter(),rayprim;
-#ifdef DEB
- Standard_Integer NbSpan=(Poles.Length()-1)/2;
-#endif
Standard_Integer low = Poles.Lower();
Standard_Integer upp = Poles.Upper();
Standard_Boolean istgt;
Handle(Adaptor3d_HVertex)& Vtx)
{
Standard_Boolean recadre = Standard_False;
-#ifdef DEB
- Standard_Boolean byinter = (line->NbPoints() != 0);
-#endif
+
gp_Pnt2d pt2d, lastpt2d;
Standard_Integer IndexSol, nbarc;
Standard_Real pmin;
Standard_Boolean isInserted = Standard_False;
Standard_Integer j, ori = (arrForward(i)? 1 : 0);
for (j = 1; (j <= seqCandidates.Length()) && !isInserted; j++) {
- Standard_Integer aInd = seqCandidates.Value(j);//debug
Standard_Real aDelta = arrDistance(i) - arrDistance(seqCandidates.Value(j));
//if (arrDistance(i) <= arrDistance(seqCandidates.Value(j))) {
if( aDelta < Precision::Confusion()) {
fabs( Other.LastParameter()-Last) > aPC);
if (!proj) {
Standard_Integer i;
- Standard_Real Tol2, prm, aD2, dD;
+ Standard_Real Tol2, prm, dD;
gp_Pnt pref, pother;
//modified by NIZNHY-PKV Thu May 05 09:06:41 2011f
//OCC22428
TopoDS_Shape aLocalShape = myShape.EmptyCopied();
TopoDS_Face newFace = TopoDS::Face(aLocalShape);
// TopoDS_Face newFace = TopoDS::Face(myShape.EmptyCopied());
-#ifdef DEB
- TopAbs_Orientation orWire =
-#endif
- wir1.Orientation();
+
newFace.Orientation(TopAbs_FORWARD);
B.Add(newFace,wir1);
if (BRepCheck_Trace(0) > 1) {
TopTools_DataMapIteratorOfDataMapOfShapeInteger itt(MapOfShapeOrientation);
Standard_Integer upper = MapOfShapeOrientation.NbBuckets();
- Standard_Integer code = 0;
cout << "La map shape Orientation :" << endl;
for (; itt.More(); itt.Next()) {
PrintShape(itt.Key(), upper);
//
if(Inter.IsDone()) {
Standard_Integer nbp = Inter.NbPoints();
- Standard_Integer nbs = Inter.NbSegments();
+ //Standard_Integer nbs = Inter.NbSegments();
//
for(Standard_Integer p=1;p<=nbp;p++) {
const IntRes2d_IntersectionPoint& IP=Inter.Point(p);
{
TopoDS_Edge Edge = TopoDS::Edge (faceexplorer.Current());
c.Initialize (Edge, face);
-#ifdef DEB
- Standard_Integer nbinterval =
-#endif
- c.NbIntervals(GeomAbs_C1);
c.D1((c.LastParameter() - c.FirstParameter()) * param_ + c.FirstParameter(),P,T);
Standard_Real x = T.X();
gp_Pnt Pt,P1=BRep_Tool::Pnt(S1);
BRepClass_FaceClassifier classifier;
const Standard_Real tol = BRep_Tool::Tolerance(S2);
- const Standard_Real epsP = Precision::PConfusion();
for (i = 1; i <= NbExtrema; i++)
{
gp_Pnt Pt,P1=BRep_Tool::Pnt(S2);
BRepClass_FaceClassifier classifier;
const Standard_Real tol = BRep_Tool::Tolerance(S1);
- const Standard_Real epsP = Precision::PConfusion();
for (i = 1; i <= NbExtrema; i++)
{
BRepExtrema_SeqOfSolution seqSol1;
BRepExtrema_SeqOfSolution seqSol2;
- Standard_Boolean bIsMini = Standard_False;
if (SeqSolution1.Length() > 0 && SeqSolution2.Length() > 0)
MIN_SOLUTION(SeqSolution1, SeqSolution2, myDstRef, myEps, seqSol1, seqSol2);
BRepExtrema_SeqOfSolution seqSol1;
BRepExtrema_SeqOfSolution seqSol2;
- Standard_Boolean bIsMini = Standard_False;
if (SeqSolution1.Length() > 0 && SeqSolution2.Length() > 0)
MIN_SOLUTION(SeqSolution1, SeqSolution2, myDstRef, myEps, seqSol1, seqSol2);
gp_Pnt2d PUV;
Standard_Real U1,V1,U2,V2;
BRepClass_FaceClassifier classifier;
- const Standard_Real epsP=Precision::PConfusion();
for (i = 1; i <= NbExtrema; i++)
{
counter1++;
NewListOfEdges.Append(edg);
theEdge = eeee;
-#ifdef DEB
- Standard_Real dist1 =
-#endif
- theLastPnt.Distance(myLastPnt);
if(dist <= myTol)
theFEdge = edg;
// end by chaining the section
return Standard_False;
}
-// #ifdef DEB
-// Standard_Boolean isnb=
-// #endif
TopTools_ListOfShape thelist1;
-#ifdef DEB
- Standard_Boolean isnb=
-#endif
mySlface.Bind(CurrentFace, thelist1);
mySlface(CurrentFace).Append(edg1);
myListOfEdges.Append(edg1);
if(Sliding && !PtOnFirstEdge) {
BRepExtrema_ExtCF ext1(TopoDS::Edge(ee1.Shape()), FirstFace);
-#ifdef DEB
- Standard_Integer nb =
-#endif
- ext1.NbExt();
-#ifdef DEB
- Standard_Real dist =
-#endif
- ext1.SquareDistance(1);
if(ext1.NbExt() < 1 || ext1.SquareDistance(1) > Precision::Confusion() * Precision::Confusion())
Sliding = Standard_False;
}
counter1++;
NewListOfEdges.Append(edg);
theEdge = eeee;
-#ifdef DEB
- Standard_Real dist1 =
-#endif
- theLastPnt.Distance(myLastPnt);
+
if(dist <= myTol)
theFEdge = edg;
theLastPnt = BRep_Tool::Pnt(TopExp::LastVertex(theEdge,Standard_True));
TopoDS_Shape aLocalShape = DSS.SupportOnShape2(isol);
TopoDS_Edge E = TopoDS::Edge(aLocalShape);
// TopoDS_Edge E = TopoDS::Edge(DSS.SupportOnShape2(isol));
-#ifdef DEB
- Standard_Real tol =
-#endif
- Precision::PConfusion();
Standard_Real first,last,param;
DSS.ParOnEdgeS2(isol,param);
BRep_Tool::Range(E,first,last);
// bounding box of the stop shape
Bnd_Box BSurf;//, TheBox;
Standard_Real Umin, Umax, Vmin, Vmax;
-#ifdef DEB
- Standard_Real Tol = Precision::Confusion()/10;
-#endif
// BRepTools B;
// BRep_Tool BT;
Handle(Geom_Surface) Surf;
static Standard_Integer Side(const TopoDS_Wire& Profil,
const Standard_Real Tol)
{
-#ifdef DEB
- Standard_Boolean OnLeft = Standard_False;
- Standard_Boolean OnRight = Standard_False;
-#endif
TopoDS_Vertex V1,V2;
// Rem : it is enough to test the first edge of the Wire.
// ( Correctly cut in PrepareProfil)
// if one remains on the same edge.
// if one passes from left to the right they are inverted.
//------------------------------------------------- -------------
-#ifndef DEB
Standard_Boolean Commun = Standard_False;
-#else
- Standard_Boolean Commun;
-#endif
-#ifdef DEB
- TopAbs_Orientation OriSide =
-#endif
- Relative(myProfile,Prof,
+ Relative(myProfile,Prof,
TopoDS::Vertex(VV),
Commun);
const TopoDS_Face& F )
{
-#ifdef DEB
- TopAbs_Orientation O =
-#endif
- F.Orientation();
-
TopExp_Explorer Exp(F.Oriented(TopAbs_FORWARD),TopAbs_EDGE);
for (; Exp.More() ;Exp.Next()) {
// if the offset is greater otr equal to the radius and the side of the
// concavity of the circle => edge null.
gp_Circ2d C1(AC.Circle());
-#ifdef DEB
- Standard_Real radius =
-#endif
- C1.Radius();
gp_Ax22d axes( C1.Axis());
gp_Dir2d Xd = axes.XDirection();
gp_Dir2d Yd = axes.YDirection();
}
for(j = myLocation->NbLaw(); j >= 1; j--) {
- Standard_Boolean ismodified = Standard_False;
TopTools_ListOfShape aListOfFace;
if(bPrevModified) {
Standard_Integer BRepGProp_Face::LIntOrder(const Standard_Real Eps) const
{
Bnd_Box2d aBox;
- BndLib_Add2dCurve aB;
- aB.Add(myCurve, 1.e-7, aBox);
+
+ BndLib_Add2dCurve::Add(myCurve, 1.e-7, aBox);
Standard_Real aXmin, aXmax, aYmin, aYmax;
aBox.Get(aXmin, aYmin, aXmax, aYmax);
Standard_Real aVmin = mySurface.FirstVParameter();
gp_Pnt2d uvFirst, uvLast;
- TopAbs_Orientation orFace = face.Orientation();
Handle(Poly_Triangulation) T;
TopLoc_Location loc;
//IMPORTANT: Constants used in calculations
const Standard_Real MinimalArea2d = 1.e-9;
const Standard_Real MinimalSqLength3d = 1.e-12;
- const Standard_Real aDef2 = theDefFace*theDefFace;
// Define the number of iterations
Standard_Integer myNbIterations = 11;
Standard_Boolean caninsert;
Standard_Real sqdefface = theDefFace * theDefFace;
- Standard_Real ddu = theCaro->UResolution(theDefFace);
- Standard_Real ddv = theCaro->VResolution(theDefFace);
GeomAbs_SurfaceType thetype = theCaro->GetType();
Handle(Geom_Surface) BSpl;
const BRepMesh_Edge& ve1=myStructure->GetLink(e1);
const BRepMesh_Edge& ve2=myStructure->GetLink(e2);
- const BRepMesh_Edge& ve3=myStructure->GetLink(e3);
if (o1) {
v1=ve1.FirstNode();
MinLoc = E.Location() * MinLoc;
if (!C3d.IsNull())
{
- Standard_Real FirstPar = C3d->FirstParameter();
- Standard_Real LastPar = C3d->LastParameter();
if (MinPC->IsClosed())
{
f = FirstParOnPC;
TopoDS_Shape NE;
TopoDS_Edge TNE;
TopoDS_Face NF;
-#ifdef DEB
- TopAbs_Orientation Or;
-#endif
for (Exp.Init(myShape,TopAbs_FACE) ; Exp.More(); Exp.Next()) {
const TopoDS_Face& FI = TopoDS::Face(Exp.Current());
BRepOffset_Type RT = BRepOffset_Concave;
if (myOffset < 0.) RT = BRepOffset_Convex;
BRepOffset_DataMapIteratorOfDataMapOfShapeOffset It(MapSF);
-#ifdef DEB
- Standard_Integer MapSFNb = MapSF.Extent();
-#endif
for ( ; It.More(); It.Next()) {
const TopoDS_Shape& SI = It.Key();
const BRepOffset_Offset& SF = It.Value();
const TopoDS_Face& F )
{
-#ifdef DEB
- TopAbs_Orientation O =
-#endif
- F.Orientation();
TopExp_Explorer Exp;
Exp.Init(F.Oriented(TopAbs_FORWARD),TopAbs_EDGE);
return 0;
#ifdef DEB
- badargs:
di << "profile : bad number of arguments";
return 1;
#endif
DBRep::Set(name, E);
MW.Add(E);
if (MW.IsDone()==Standard_False) {
-#if DEB
- BRepBuilderAPI_WireError err =
-#endif
- MW.Error();
Standard_Failure::Raise("mkWire is over ");
}
BRepLib::BuildCurve3d(E);
MW.Add(E);
if (MW.IsDone()==Standard_False) {
-#ifdef DEB
- BRepBuilderAPI_WireError err =
-#endif
- MW.Error();
Standard_Failure::Raise("mkWire is over ");
}
}
TopoDS_Wire NW;
B.MakeWire(NW);
TopoDS_Iterator ite(W,Standard_False);
-#ifdef DEB
- Standard_Real Tol = BRep_Tool::Tolerance(F);
-#else
- BRep_Tool::Tolerance(F);
-#endif
Standard_Real UFirst,ULast;
// Reconstruction des wires.
TopoDS_Shape arefShape = SH.Oriented(TopAbs_FORWARD) ;
B.Add ( arefShape ,Fo.Oriented(NewO));
}
- Standard_Integer kk =1;
- Standard_Integer p =0;
// Rebind the free edges of the old shell to the new shell
//gka BUG 6491
TopExp_Explorer aexp(SH,TopAbs_EDGE);
{
//Standard_Real anglep=0,anglem=0;
TColgp_Array1OfPnt2d PClass(1,nbpnts);
- Standard_Real angle = 0.0, square = 0.0;
+ Standard_Real square = 0.0;
//-------------------------------------------------------------------
//-- ** The mode of calculation was somewhat changed
const TColStd_Array1OfExtendedString& aSourceArray = anAtt->Array()->Array1();
const Standard_Integer aFirstInd = aSourceArray.Lower();
const Standard_Integer aLastInd = aSourceArray.Upper();
- const Standard_Integer aLength = aLastInd - aFirstInd + 1;
theTarget << aFirstInd << aLastInd;
for (Standard_Integer i = aFirstInd; i <= aLastInd; i ++)
theTarget << anAtt->Value( i );
Handle(TDataStd_ExtStringList) anAtt = Handle(TDataStd_ExtStringList)::DownCast(theSource);
const Standard_Integer aFirstInd = 1;
const Standard_Integer aLastInd = anAtt->Extent();
- const Standard_Integer aLength = aLastInd - aFirstInd + 1;
theTarget << aFirstInd << aLastInd;
TDataStd_ListIteratorOfListOfExtendedString itr(anAtt->List());
for (; itr.More(); itr.Next())
TopAbs_State situ;
Standard_Real w,U,V;
Standard_Integer nbarc;
-#ifndef DEB
Standard_Integer Index = 0;
Standard_Boolean Isvtx = Standard_False;
-#else
- Standard_Integer Index;
- Standard_Boolean Isvtx;
-#endif
Standard_Integer Nbvar = Func.NbVariables();
Standard_Boolean Arrive,recad,echecrecad;
gp_Pnt2d p2d;
math_Matrix gradsol(1,3,1,3);
Standard_Real prm = P.Parameter();
-#ifdef DEB
- Standard_Integer NbSpan=(Poles.Length()-1)/2;
-#endif
Standard_Integer low = Poles.Lower();
Standard_Integer upp = Poles.Upper();
Standard_Boolean istgt;
const Standard_Real normtgcur = d1cur.Magnitude();
const gp_Vec nplan = d1cur.Normalized();
- const Standard_Real theD = -(nplan.XYZ().Dot(ptcur.XYZ()));
gp_Vec dnplan;
dnplan.SetLinearForm(-nplan.Dot(d2cur),nplan,d2cur);
TopoDS_Edge anEdge = makeEdge;
anEdge.Orientation(E1.Orientation());
// anEdge.Location(E1.Location());
-#ifdef DEB
- BRepLib_EdgeError error =
-#endif
- makeEdge.Error();
return anEdge;
}
const Standard_Boolean Complain)
{
Label.Nullify();
-#ifdef DEB
- Standard_Boolean Found;
-#endif
TDF_Tool::Label(D->GetData(),Entry,Label,Standard_False);
if (Label.IsNull() && Complain) cout<<"No label for entry "<<Entry<<endl;
return !Label.IsNull();
Handle(TDF_Attribute)& A,
const Standard_Boolean Complain)
{
-#ifdef DEB
- Standard_Boolean found;
-#endif
TDF_Label L;
if (Find(D,Entry,L,Complain)) {
if (L.FindAttribute(ID,A)) return Standard_True;
TDF_Reference::Set(anObject->Label(), aFun->Label().FindChild(FUNCTION_RESULT_LABEL)); //result is here
- Standard_Integer aSurfaceType = 0;
-
Standard_Real aRadius = atof(theArg[3]);
DNaming::GetReal(aFun,FILLET_RADIUS)->Set(aRadius);
return 0;
}
}
- ERR:
+
cout << "DNaming_SphRadius : Error" << endl;
return 1;
}
TDF_Label aResultLabel = aFun->Label().FindChild(FUNCTION_RESULT_LABEL, Standard_True);
TDF_Reference::Set(Obj->Label(), aResultLabel ); //result of the object
aResultLabel.ForgetAllAttributes(Standard_True);
- Standard_Boolean aKeepOrientation(Standard_False);
Handle(TNaming_NamedShape) aNS = DNaming::GetObjectValue( ContextObj);
try{
const TopoDS_Shape& aContext = aNS->Get();
TDF_Reference::Set(Obj->Label(), aResultLabel ); //result of the object
aResultLabel.ForgetAllAttributes(Standard_True);
- Standard_Boolean aKeepOrientation(Standard_False);
Handle(TNaming_NamedShape) aNS = DNaming::GetObjectValue( ContextObj);
try{
const TopoDS_Shape& aContext = aNS->Get();
if(!aNS.IsNull() && !aNS->IsEmpty()) {
const TopoDS_Shape& aRootShape = aNS->Get();
- TopAbs_ShapeEnum aType = aRootShape.ShapeType();
//TopTools_MapOfOrientedShape aMap0;
//MapOfOrientedShapes(aRootShape, aMap0);
TopTools_ListOfShape aList, aFailedList;
return 0;
}
}
- ERR:
+
cout << "DNaming_TestSingle : Error" << endl;
return 1;
}
if(!aNS.IsNull() && !aNS->IsEmpty()) {
const TopoDS_Shape& aRootShape = aNS->Get();
- TopAbs_ShapeEnum aType = aRootShape.ShapeType();
TopTools_MapOfOrientedShape aMap0;
MapOfOrientedShapes(aRootShape, aMap0);
TopTools_ListOfShape aList, aFailedList;
return 0;
}
}
- ERR:
+
cout << "DNaming_TestMultiple : Error" << endl;
return 1;
}
if (done) return;
done = Standard_True;
const char* g = "Naming data commands " ;
- const char* g2 = "Naming modeling commands" ;
theCommands.Add ("CopyShape",
"CopyShape (Shape1 [Shape2] ...)",
Draw_IsConsoleSubsystem = Standard_True;
//return _WinMain_(::GetModuleHandle(NULL), NULL, GetCommandLine(), SW_SHOW, fDraw_InitAppli);
theDraw_InitAppli = fDraw_InitAppli;
- Standard_Boolean CONSOLE = Standard_True;
//ParseCommandLine(GetCommandLine());
// MKV 01.02.05
if (Draw_Batch) return;
if (myViews[id]) {
gp_Trsf T = myViews[id]->Matrix;
-#ifdef DEB
- Standard_Real z = myViews[id]->Zoom;
-#endif
T.Invert();
gp_Pnt PP(0,0,0);
gp_Vec curvec (AxePosition, curpt);
gp_XYZ curXYZ = curvec.XYZ();
gp_XYZ Norm (curXYZ.Crossed(AxeXYZ));
-#ifdef DEB
- Standard_Real NormMod =
-#endif
- Norm.Modulus();
+
if (Norm.Modulus() > gp::Resolution()) {
Standard_Real curdist = curpos.Distance (curpt);
if (curdist < dist) {
void DrawFairCurve_Batten::Compute()
{
FairCurve_AnalysisCode Iana;
-#ifdef DEB
- Standard_Boolean Ok =
-#endif
- ((FairCurve_Batten*)MyBatten)->Compute(Iana, 50, 1.0e-2);
+ ((FairCurve_Batten*)MyBatten)->Compute(Iana, 50, 1.0e-2);
curv = ((FairCurve_Batten*)MyBatten)->Curve();
}
void DrawFairCurve_Batten::SetPoint(const Standard_Integer Side, const gp_Pnt2d& Point)
// verify that (upar vpar) is a point on the face
BRepClass_FaceClassifier fClass(face, pt2d, gp::Resolution());
-#ifdef DEB
- TopAbs_State state =
-#endif
- fClass.State();
+
if ((fClass.State() == TopAbs_OUT) || (fClass.State() == TopAbs_UNKNOWN)) {
// try to find a point on face
pt2d=points(1);
A(1).SetCoord(xo,yo,zo);
A(2).SetCoord(x,y,z);
-#ifdef DEB
- Quantity_Length arrowAngle = anArrowAspect->Angle();
- Quantity_Length textHeight = aTextAspect->Height();
-#endif
-
G->SetPrimitivesAspect(aLineAspect->Aspect());
G->Polyline(A);
G->SetPrimitivesAspect( anArrowAspect->Aspect() );
{
ExprIntrp_Recept.PushValue(1);
char name[100];
-#ifdef DEB
- Standard_Integer nbcar =
-#endif
- ExprIntrp_GetResult(name);
+ ExprIntrp_GetResult(name);
TCollection_AsciiString thename(name);
Handle(Expr_NamedExpression) namexp = ExprIntrp_Recept.GetNamed(thename);
if (namexp.IsNull()) {
extern "C" void ExprIntrp_DiffDegreeVar()
{
char name[100];
-#ifdef DEB
- Standard_Integer nbcar =
-#endif
- ExprIntrp_GetResult(name);
+ ExprIntrp_GetResult(name);
#ifndef WNT
if (strncasecmp(name,"X",1)) {
#else
extern "C" void ExprIntrp_DiffDegree()
{
char name[100];
-#ifdef DEB
- Standard_Integer nbcar =
-#endif
- ExprIntrp_GetResult(name);
+ ExprIntrp_GetResult(name);
Standard_Integer deg = atoi(name);
ExprIntrp_Recept.PushValue(deg);
}
extern "C" void ExprIntrp_VerDiffDegree()
{
char name[100];
-#ifdef DEB
- Standard_Integer nbcar =
-#endif
- ExprIntrp_GetResult(name);
+ ExprIntrp_GetResult(name);
Standard_Integer deg = atoi(name);
Standard_Integer thedeg = ExprIntrp_Recept.PopValue();
if (deg != thedeg) {
extern "C" void ExprIntrp_ConstantIdentifier()
{
char name[100];
-#ifdef DEB
- Standard_Integer nbcar =
-#endif
- ExprIntrp_GetResult(name);
+ ExprIntrp_GetResult(name);
TCollection_AsciiString thename(name);
ExprIntrp_Recept.PushName(thename);
}
if(Precision::IsInfinite(Abs(cfirst)) || Precision::IsInfinite(Abs(clast))) {
Bnd_Box aSurfBox;
- BndLib_AddSurface anAddSurf;
- anAddSurf.Add(*myS, ufirst, ulast, vfirst, vlast, Precision::Confusion(), aSurfBox);
+ BndLib_AddSurface::Add(*myS, ufirst, ulast, vfirst, vlast, Precision::Confusion(), aSurfBox);
Standard_Real xmin, ymin, zmin, xmax, ymax, zmax;
aSurfBox.Get(xmin, ymin, zmin, xmax, ymax, zmax);
Standard_Real tmin = Precision::Infinite(), tmax = -tmin;
}
//
Standard_Boolean IsARoot(Standard_Real u) {
- Standard_Integer i;
Standard_Real PIpPI, aEps;
//
aEps=RealEpsilon();
Standard_Real R = C.MajorRadius();
Standard_Real r = C.MinorRadius();
gp_Vec OPp (O,Pp);
-#ifdef DEB
- Standard_Real OPpMagn = OPp.Magnitude();
-#else
- OPp.Magnitude();
-#endif
Standard_Real X = OPp.Dot(gp_Vec(C.XAxis().Direction()));
Standard_Real Y = OPp.Dot(gp_Vec(C.YAxis().Direction()));
Standard_Real F = C.Focal();
gp_Vec OPp (O,Pp);
-#ifdef DEB
- Standard_Real OPpMagn = OPp.Magnitude();
-#else
- OPp.Magnitude();
-#endif
Standard_Real X = OPp.Dot(gp_Vec(C.XAxis().Direction()));
// Standard_Real Y = Sqrt(OPpMagn*OPpMagn-X*X);
Standard_Real Y = OPp.Dot(gp_Vec(C.YAxis().Direction()));
myDone = Standard_False;
}
else {
-#ifdef DEB
- Standard_Real VMagn = V.Magnitude();
-#else
- V.Magnitude();
-#endif
Standard_Real X = V.Dot(gp_Vec2d(E.XAxis().Direction()));
Standard_Real Y = V.Dot(gp_Vec2d(E.YAxis().Direction()));
Standard_Real R = H.MajorRadius();
Standard_Real r = H.MinorRadius();
gp_Vec2d OPp(O,P);
-#ifdef DEB
- Standard_Real OPpMagn = OPp.Magnitude();
-#else
- OPp.Magnitude();
-#endif
Standard_Real Tol2 = Tol * Tol;
Standard_Real X = OPp.Dot(gp_Vec2d(H.XAxis().Direction()));
Standard_Real Y = OPp.Dot(gp_Vec2d(H.YAxis().Direction()));
Standard_Real Tol2 = Tol * Tol;
Standard_Real F = C.Focal();
gp_Vec2d OPp (O,P);
-#ifdef DEB
- Standard_Real OPpMagn = OPp.Magnitude();
-#else
- OPp.Magnitude();
-#endif
Standard_Real X = OPp.Dot(gp_Vec2d(C.MirrorAxis().Direction()));
Standard_Real Y = OPp.Dot(gp_Vec2d(C.Axis().YAxis().Direction()));
Standard_Real L2 = MP.SquareMagnitude();
Standard_Real Vm = -(S.RefRadius() / Sin(A));
-#ifdef DEB
- Standard_Real Zm = gp_Vec(O, M).Dot(OZ);
-#else
- gp_Vec(O, M).Dot(OZ);
-#endif
// Case when P is mixed with S ...
if (L2 < Tol * Tol) {
TColStd_Array1OfInteger FirstIndexes(1, B.Length()); FirstIndexes.Init(B.Length());
-#ifdef DEB
- Standard_Integer dim, el, nvar, Imax, Imin, I0 = 1 - B.Lower(), i;
-#else
Standard_Integer dim, el, nvar, Imin, I0 = 1 - B.Lower(), i;
-#endif
+
Standard_Integer diml = Table->LowerRow(), dimu = Table->UpperRow(),
ell = Table->LowerCol(), elu = Table->UpperCol(), nvarl, nvaru;
Standard_Integer nvarl = T1.Lower(), nvaru = Min(T1.Upper(), nvarl + Mat.RowNumber() - 1);
-#ifdef DEB
- Standard_Integer I, J, I0 = 1 - B.Lower(), i, ii, j, jj,
-#else
+
Standard_Integer I, J, I0 = 1 - B.Lower(), i, ii, j,
-#endif
+
i0 = Mat.LowerRow() - nvarl, j0 = Mat.LowerCol() - nvarl;
for(i = nvarl; i <= nvaru; i++) {
// Standard_Real UCurrent;
Standard_Real Delta, Ui;
Standard_Real UU2 = Max(U1, U2);
-#ifdef DEB
- Standard_Real L =
-#endif
- CPnts_AbscissaPoint::Length(C, UU1, UU2);
Standard_Integer Index ;
// Ratio is defined as dl = Ratio * du
// Compute the integral from myUMin to aUMax of myUFunction.
Standard_Integer i;
Standard_Real aCoeff = aV2d.Y();
- Standard_Integer aNbUIntervals = anUKnots->Length() - 1;
+ //Standard_Integer aNbUIntervals = anUKnots->Length() - 1;
//Standard_Real aTol = myTolerance/aNbUIntervals;
Standard_Real aTol = myTolerance;
gp_Pnt2d center1(C1.Location());
gp_Pnt2d center2(C2.Location());
TColStd_Array1OfReal Radius(1,2);
-#ifdef DEB
- Standard_Real distance = center1.Distance(center2);
-#else
- center1.Distance(center2);
-#endif
+
Standard_Real dist1 = OnLine.Distance(center1);
Standard_Real dist2 = OnLine.Distance(center2);
Standard_Real d1 = dist1+R1;
gp_Dir2d dir(OnCirc.Location().XY()-Point2.XY());
gp_Pnt2d pinterm(Point2.XY()+(distpc+Ron)*dir.XY());
Standard_Real dist1 = L1.Distance(pinterm);
- if (Abs(dist1-distpc-Ron) > Tol) {
-#ifdef DEB
- gp_Pnt2d pinterm(Point2.XY()+(distpc-Ron)*dir.XY()); // Unused ! BUG ???
- Standard_Real dist1 = L1.Distance(pinterm); // Unused ! BUG ???
-#endif
- }
+
if (Abs(dist1-distpc+Ron) <= Tol) {
dir = gp_Dir2d(-dirL1.Y(),dirL1.X());
gp_Dir2d direc(originL1.XY()-pinterm.XY());
TColStd_Array1OfReal Rradius(1,2);
gp_Pnt2d center1(C1.Location());
gp_Pnt2d center2(C2.Location());
-#ifdef DEB
- Standard_Real distance = center1.Distance(center2);
-#else
- center1.Distance(center2);
-#endif
+
Standard_Real R1 = C1.Radius();
Standard_Real R2 = C2.Radius();
NbrSol = 0;
gp_Dir2d dirx(1.,0.);
-#ifdef DEB
- Standard_Real Tol = Abs(Tolerance);
-#endif
if (!(Qualified1.IsEnclosed() ||
Qualified1.IsOutside() || Qualified1.IsUnqualified()) ||
!(Qualified2.IsEnclosed() ||
{
gp_Dir2d dirx(1.0,0.0);
-#ifdef DEB
- Standard_Real Tol = Abs(Tolerance);
-#endif
TColStd_Array1OfReal cote1(1,2);
TColStd_Array1OfReal cote2(1,2);
Standard_Integer nbrcote1=0;
TheSame2.Init(0);
TheSame3.Init(0);
gp_Dir2d dirx(1.0,0.0);
-#ifdef DEB
- Standard_Real Tol = Abs(Tolerance);
-#endif
WellDone = Standard_False;
NbrSol = 0;
if (!(Qualified1.IsEnclosed() ||
gp_Pnt2d Center(Intp.Point(j).Value());
Standard_Real dist1 = L1.Distance(Center);
Standard_Real dist2 = Center.Distance(Point2);
-#ifdef DEB
- Standard_Real dist3 = Center.Distance(Point3);
-#else
- Center.Distance(Point3);
-#endif
+
Standard_Real Radius=0;
Standard_Integer nbsol1 = 0;
// Standard_Integer nbsol2 = 0;
cirsol(NbrSol)=gp_Circ2d(gp_Ax2d(Center,dirx),Radius);
// =====================================================
gp_Dir2d dc1(origin1.XY()-Center.XY());
-#ifdef DEB
- Standard_Real sign = dc1.Dot(normL1);
-#else
- dc1.Dot(normL1);
-#endif
if (!Qualified1.IsUnqualified()) {
qualifier1(NbrSol) = Qualified1.Qualifier();
}
cote1(1) = Radius;
cote1(2) = -Radius;
}
-#ifdef DEB
- Standard_Real x1dir = dir1.X();
- Standard_Real y1dir = dir1.Y();
-#else
- dir1.X();
- dir1.Y();
-#endif
TheIntConicCurve Intp;
for (Standard_Integer jcote1 = 1 ; jcote1 <= nbrcote1 ; jcote1++) {
gp_Pnt2d Point(dir1.XY()+cote1(jcote1)*norm1.XY());
cirsol(NbrSol) = gp_Circ2d(gp_Ax2d(Center,dirx),Radius);
// =======================================================
gp_Dir2d dc1(origin1.XY()-Center.XY());
-#ifdef DEB
- Standard_Real sign = dc1.Dot(norm1);
-#else
- dc1.Dot(norm1);
-#endif
if (!Qualified1.IsUnqualified()) {
qualifier1(NbrSol) = Qualified1.Qualifier();
}
Ufirst(4) = (point3.Distance(point2)+point3.Distance(point1))/2.;
GccIter_FuncTCuCuOnCu Func(L1,Cu2,OnLine,Ufirst(4));
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
if (Root.IsDone()) {
Root.Root(Ufirst);
// gp_Vec2d Tan1,Tan2,Nor1,Nor2;
Ufirst(4) = (point3.Distance(point2)+point3.Distance(point1))/2.;
GccIter_FuncTCuCuOnCu Func(Cu1,Cu2,OnLine,Ufirst(4));
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
if (Root.IsDone()) {
Root.Root(Ufirst);
gp_Vec2d Tan1,Tan2;
Ufirst(3) = (point3.Distance(Point2)+point3.Distance(point1))/2.;
GccIter_FuncTCuCuOnCu Func(Cu1,Point2,OnLine,Ufirst(3));
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
if (Root.IsDone()) {
Root.Root(Ufirst);
gp_Pnt2d point1,point3;
Ufirst(4) = (point3.Distance(point2)+point3.Distance(point1))/2.;
GccIter_FuncTCuCuOnCu Func(C1,Cu2,OnLine,Ufirst(4));
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
if (Root.IsDone()) {
Root.Root(Ufirst);
// gp_Vec2d Tan1,Tan2,Nor1,Nor2;
Ufirst(4) = (point3.Distance(point2)+point3.Distance(point1))/2.;
GccIter_FuncTCuCuOnCu Func(C1,Cu2,OnCirc,Ufirst(4));
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
if (Root.IsDone()) {
Root.Root(Ufirst);
// gp_Vec2d Tan1,Tan2,Nor1;
Ufirst(4) = (point3.Distance(point2)+point3.Distance(point1))/2.;
GccIter_FuncTCuCuOnCu Func(L1,Cu2,OnCirc,Ufirst(4));
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
if (Root.IsDone()) {
Root.Root(Ufirst);
gp_Pnt2d point1,point2;
Ufirst(4) = (point3.Distance(point2)+point3.Distance(point1))/2.;
GccIter_FuncTCuCuOnCu Func(Cu1,Cu2,OnCirc,Ufirst(4));
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
if (Root.IsDone()) {
Root.Root(Ufirst);
// gp_Vec2d Tan1,Tan2,Nor1;
Ufirst(3) = (point3.Distance(Point2)+point3.Distance(point1))/2.;
GccIter_FuncTCuCuOnCu Func(Cu1,Point2,OnCirc,Ufirst(3));
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
if (Root.IsDone()) {
Root.Root(Ufirst);
gp_Pnt2d point1,point3;
Ufirst(4) = (point3.Distance(point2)+point3.Distance(point1))/2.;
GccIter_FuncTCuCuOnCu Func(Cu1,Cu2,OnCurv,Ufirst(4));
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
if (Root.IsDone()) {
Root.Root(Ufirst);
gp_Vec2d Tan1,Tan2,Tan3;
Ufirst(4) = (point3.Distance(point2)+point3.Distance(point1))/2.;
GccIter_FuncTCuCuOnCu Func(C1,Cu2,OnCurv,Ufirst(4));
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
if (Root.IsDone()) {
Root.Root(Ufirst);
gp_Vec2d Tan1,Tan2,Tan3;
Ufirst(4) = (point3.Distance(point2)+point3.Distance(point1))/2.;
GccIter_FuncTCuCuOnCu Func(L1,Cu2,OnCurv,Ufirst(4));
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
if (Root.IsDone()) {
Root.Root(Ufirst);
gp_Vec2d Tan1,Tan2,Tan3;
Ufirst(3) = (point3.Distance(Point2)+point3.Distance(point1))/2.;
GccIter_FuncTCuCuOnCu Func(Cu1,Point2,OnCurv,Ufirst(3));
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
if (Root.IsDone()) {
Root.Root(Ufirst);
// gp_Vec2d Tan1,Tan2,Tan3;
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
if (Root.IsDone()) {
Root.Root(Ufirst);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
gp_Pnt2d point1,point2,point3;
gp_Vec2d Tan1,Tan2,Tan3;
TheCurveTool::D1(Cu1,Ufirst(1),point1,Tan1);
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
if (Root.IsDone()) {
Root.Root(Ufirst);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
gp_Pnt2d centre1(C1.Location());
Standard_Real R1 = C1.Radius();
gp_Pnt2d point1(centre1.XY()+R1*gp_XY(Cos(Ufirst(1)),Sin(Ufirst(1))));
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
if (Root.IsDone()) {
Root.Root(Ufirst);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
gp_Pnt2d centre1(C1.Location());
Standard_Real R1 = C1.Radius();
gp_Pnt2d point1(centre1.XY()+R1*gp_XY(Cos(Ufirst(1)),Sin(Ufirst(1))));
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
if (Root.IsDone()) {
Root.Root(Ufirst);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
gp_Pnt2d centre1(L1.Location());
gp_Pnt2d point1(centre1.XY()+Ufirst(1)*L1.Direction().XY());
gp_Pnt2d point2,point3;
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
if (Root.IsDone()) {
Root.Root(Ufirst);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
gp_Pnt2d centre1(L1.Location());
gp_Pnt2d point1(centre1.XY()+Ufirst(1)*L1.Direction().XY());
gp_Pnt2d centre2(L2.Location());
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
if (Root.IsDone()) {
Root.Root(Ufirst);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
gp_Pnt2d point1,point2;
// gp_Vec2d Tan1,Tan2,Nor1,Nor2;
gp_Vec2d Tan1,Tan2;
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
if (Root.IsDone()) {
Root.Root(Ufirst);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
gp_Pnt2d point3;
// gp_Vec2d Tan3,Nor3;
gp_Vec2d Tan3;
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
if (Root.IsDone()) {
Root.Root(Ufirst);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
gp_Pnt2d centre1(L1.Location());
gp_Pnt2d point1(centre1.XY()+Ufirst(2)*L1.Direction().XY());
gp_Pnt2d point2;
tol(3) = TheCurveTool::EpsX(Cu3,Abs(Tolerance));
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
if (Root.IsDone()) {
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
Root.Root(Ufirst);
gp_Pnt2d centre1(C1.Location());
Standard_Real R1 = C1.Radius();
math_FunctionSetRoot Root(Func,Ufirst,tol,Umin,Umax);
if (Root.IsDone()) {
Root.Root(Ufirst);
-#ifdef DEB
- Standard_Boolean Ok = Func.Value(Ufirst,Umin);
-#else
Func.Value(Ufirst,Umin);
-#endif
gp_Pnt2d centre1(C1.Location());
Standard_Real R1 = C1.Radius();
gp_Pnt2d point1(centre1.XY()+R1*gp_XY(Cos(Ufirst(1)),Sin(Ufirst(1))));
TheCurveTool::D2(Curve,X,Point,Vect1,Vect2);
Standard_Real NormeD1 = Vect1.SquareMagnitude();
gp_Vec2d TheDirection(TheCirc.Location(),Point);
-#ifdef DEB
- Standard_Real squaredir = TheDirection.SquareMagnitude();
-#else
- TheDirection.SquareMagnitude();
-#endif
Standard_Real cp1dott = TheDirection.Dot(Vect1);
Deriv = -2.*(cp1dott/NormeD1)*
((TheDirection.Dot(Vect2))-cp1dott*Vect1.Dot(Vect2)/NormeD1);
//norme des Tani.
Standard_Real nnor1 = Tan1.Magnitude();
Standard_Real nnor2 = Tan2.Magnitude();
-#ifdef DEB
- Standard_Real nnor3 = Tan3.Magnitude();
-#else
- Tan3.Magnitude();
-#endif
// Fonctions Fui.
// ==============
Fval(1) = (P3P1.Dot(P3P1)-X(4)*X(4))/(FirstRad*FirstRad);
//normales au courbes normees Nori et non nromees nori et norme des nori.
Standard_Real nnor1 = Tan1.Magnitude();
Standard_Real nnor2 = Tan2.Magnitude();
-#ifdef DEB
- Standard_Real nnor3 = Tan3.Magnitude();
-#else
- Tan3.Magnitude();
-#endif
// Derivees dFui/uj 1 <= ui <= 3 , 1 <= uj <= 3
// =============================================
Deriv(1,1) = 2.*Tan1.Dot(P3P1)/(FirstRad*FirstRad);
//normales au courbes normees Nori et non nromees nori et norme des nori.
Standard_Real nnor1 = Tan1.Magnitude();
Standard_Real nnor2 = Tan2.Magnitude();
-#ifdef DEB
- Standard_Real nnor3 = Tan3.Magnitude();
-#else
- Tan3.Magnitude();
-#endif
// Fonctions Fui.
// ==============
Fval(1) = (P3P1.Dot(P3P1)-X(4)*X(4))/(FirstRad*FirstRad);
par1sol = 0.;
pararg1 = 0.;
-#ifdef DEB
- Standard_Real Tol = Abs(Tolang);
-#endif
+
+ //Standard_Real Tol = Abs(Tolang);
+
WellDone = Standard_False;
if (Qualified1.IsEnclosed()) { GccEnt_BadQualifier::Raise(); }
gp_Circ2d C1 = Qualified1.Qualified();
Standard_Real T22 = T.Value (2, 2);
Standard_Real T23 = T.Value (2, 3);
Standard_Real T24 = T.Value (2, 4);
-#ifdef DEB
- Standard_Real T31 = T.Value (3, 1);
- Standard_Real T32 = T.Value (3, 2);
- Standard_Real T33 = T.Value (3, 3);
- Standard_Real T34 = T.Value (3, 4);
-#else
- T.Value (3, 1);
- T.Value (3, 2);
- T.Value (3, 3);
- T.Value (3, 4);
-#endif
A1 = T11 * T11 + T21 * T21;
A2 = T12 * T12 + T22 * T22;
A3 = T13 * T13 + T23 * T23;
// P'(u) = p'(u) + (Offset / R**2) * (DNdir/DU * R - Ndir * (DR/R))
-
-#ifdef DEB
- GeomAbs_Shape Continuity = basisCurve->Continuity();
-#else
- basisCurve->Continuity();
-#endif
basisCurve->D2 (U, PBasis, V1basis, V2basis);
V1 = V1basis;
Vec V2 = V2basis;
// P"(u) = p"(u) + (Offset / R) * (D2Ndir/DU - DNdir * (2.0 * Dr/ R**2) +
// Ndir * ( (3.0 * Dr**2 / R**4) - (D2r / R**2)))
-#ifdef DEB
- GeomAbs_Shape Continuity = basisCurve->Continuity();
-#else
- basisCurve->Continuity();
-#endif
-
basisCurve->D3 (U, PBasis, V1basis, V2basis, V3basis);
Standard_Integer Index = 2;
V1 = V1basis;
// P'(u) = p'(u) + (Offset / R**2) * (DNdir/DU * R - Ndir * (DR/R))
-
-#ifdef DEB
- GeomAbs_Shape Continuity = basisCurve->Continuity();
-#else
- basisCurve->Continuity();
-#endif
Vec2d V2;
basisCurve->D2 (U, P, V1, V2);
Standard_Integer Index = 2;
// P"(u) = p"(u) + (Offset / R) * (D2Ndir/DU - DNdir * (2.0 * Dr/ R**2) +
// Ndir * ( (3.0 * Dr**2 / R**4) - (D2r / R**2)))
-#ifdef DEB
- GeomAbs_Shape Continuity = basisCurve->Continuity();
-#else
- basisCurve->Continuity();
-#endif
Vec2d V3;
basisCurve->D3 (U, P, V1, V2, V3);
Standard_Integer Index = 2;
// P'(u) = p'(u) + (Offset / R**2) * (DNdir/DU * R - Ndir * (DR/R))
-#ifdef DEB
- GeomAbs_Shape Continuity = basisCurve->Continuity();
-#else
- basisCurve->Continuity();
-#endif
-
basisCurve->D2 (U, Pbasis, V1basis, V2basis);
V1 = V1basis;
Vec2d V2 = V2basis;
// P"(u) = p"(u) + (Offset / R) * (D2Ndir/DU - DNdir * (2.0 * Dr/ R**2) +
// Ndir * ( (3.0 * Dr**2 / R**4) - (D2r / R**2)))
-#ifdef DEB
- GeomAbs_Shape Continuity = basisCurve->Continuity();
-#else
- basisCurve->Continuity();
-#endif
-
basisCurve->D3 (U, Pbasis, V1basis, V2basis, V3basis);
Standard_Integer Index = 2;
V1 = V1basis;
};
if(HArrPoles->Value(iC) == Param || Param == HArrPoles->Value(iC+1)) return TLaw->Value(Param);
};
-#ifdef DEB
- Standard_Real Po =
-#endif
- HArrPoles->Value(iC);
// Calculate differenciation between apporoximated and local values of AngleAT
Standard_Real AngP = TLaw->Value(Param), AngPo = HArrAngle->Value(iC), dAng = AngP - AngPo;
gp_Vec Tangent, Normal, BN;
IsRational = Standard_False;
-#ifdef DEB
- Standard_Real NU = NPolU - 1;
- Standard_Real NV = NPolV - 1;
-#endif
myPoles = new TColgp_HArray2OfPnt( 1, NPolU, 1, NPolV);
Standard_Integer i,j;
static gp_Vec DDeriv(const gp_Vec& F, const gp_Vec& DF, const gp_Vec& D2F)
{
Standard_Real Norma = F.Magnitude();
-#ifdef DEB
- Standard_Real dot = F.Dot(DF);
-#else
- F.Dot(DF);
-#endif
+
gp_Vec Result = (D2F - 2*DF*(F*DF)/(Norma*Norma))/Norma -
F*((DF.SquareMagnitude() + F*D2F
- 3*(F*DF)*(F*DF)/(Norma*Norma))/(Norma*Norma*Norma));
gp_Vec n(P, PG); // vecteur definissant la normale
Standard_Real Norm = n.Magnitude(), ndn;
-#ifdef DEB
- Standard_Real Norm2 = n.SquareMagnitude();
-#else
- n.SquareMagnitude();
-#endif
//derivee de n par rapport a Param
gp_Vec dn, d2n;
dn.SetLinearForm(dtg_dt, TG, -1, To);
gp_Vec T, N, B;
gp_Pnt P;
Standard_Boolean Ok;
-#ifdef DEB
- Standard_Real U = myFirstS + ratio*(Param-myCurve->FirstParameter());
-#else
- myCurve->FirstParameter() ;
-#endif
-
myCurve->D0(Param, P);
V.SetXYZ(P.XYZ());
}
if (rotation) {
-#ifdef DEB
- Standard_Real U = myFirstS + ratio*(Param-myCurve->FirstParameter());
-#else
- myCurve->FirstParameter() ;
-#endif
-
//initialisation du germe
InitX(Param);
Standard_Integer Iter = 100;
}
else {
#if DEB
+ Standard_Real U = myFirstS + ratio*(Param-myCurve->FirstParameter());
cout << "LocationGuide::D0 : No Result !"<<endl;
TraceRevol(Param, U, myLaw, mySec, myCurve, Trans);
#endif
gp_Mat M(V1.X(), V2.X(), 0,
V1.Y(), V2.Y(), 0,
V1.Z(), V2.Z(), 0);
-#ifdef DEB
- Standard_Real r = FirstPnt.Distance(Center);
-#else
- FirstPnt.Distance(Center);
-#endif
// Calcul des contraintes -----------
Vx(1) = 1; Vy(1) = 0;
gp_Mat M(V1.X(), V2.X(), 0,
V1.Y(), V2.Y(), 0,
V1.Z(), V2.Z(), 0);
-#ifdef DEB
- Standard_Real r = FirstPnt.Distance(Center);
-#else
- FirstPnt.Distance(Center);
-#endif
// Calcul des coeffs -----------
beta = Angle/4;
myPolynomial = Polynomial;
// eval myNbSections.
-#ifdef DEB
- Standard_Integer Deg = myPath->Degree();
-#else
- myPath->Degree();
-#endif
Standard_Integer NSpans = myPath->NbKnots()-1;
myNbSections = 21 * NSpans;
new TColStd_HArray1OfReal(1,NbPts_i-1);
Handle(TColStd_HArray1OfReal) tcourb =
new TColStd_HArray1OfReal(1,NbPts_i-1);
-#ifdef DEB
- Standard_Integer Cont_i=myLinCont->Value(i)->Order();
-#else
- myLinCont->Value(i)->Order();
-#endif
EcartContraintesMil (i,tdist,tang,tcourb);
TColStd_Array1OfReal Curve(1, dimension);
TColStd_Array1OfReal Point(1, 3);
Standard_Real * Coeffs = (Standard_Real *) &Patch.ChangeValue(1);
-#ifdef DEB
- Standard_Real * Result =
-#endif
- (Standard_Real *) &Curve.ChangeValue(1);
Standard_Real * Digit = (Standard_Real *) &Point.ChangeValue(1);
Standard_Integer k1, k2, pos, ll=1;
TColStd_Array1OfReal Curve(1, 2*dimension);
TColStd_Array1OfReal Point(1, 3);
Standard_Real * Coeffs = (Standard_Real *) &Patch.ChangeValue(1);
-#ifdef DEB
- Standard_Real * Result = (Standard_Real *) &Curve.ChangeValue(1);
-#else
- Curve.ChangeValue(1);
-#endif
Standard_Real * Digit = (Standard_Real *) &Point.ChangeValue(1);
Standard_Integer k1, k2, pos, ll=1;
Standard_Real TolV = Pow(Tol, 2./3);
ProjLib_CompProjectedCurve Proj(HS,HC,TolU,TolV,-1.);
-#ifdef DEB
- Standard_Integer NbCurves = Proj.NbCurves();
-#else
- Proj.NbCurves();
-#endif
Standard_Real f,l;
Proj.Bounds(1,f,l);
Handle(Adaptor2d_HCurve2d) HC2d = Proj.Trim(f,l,TolU);
Standard_Real V1 = Vdeb;
Standard_Real V2 = Vfin;
- // debug mjm du 28/03/96
-#ifdef DEB
- Standard_Boolean IsDirect =
-#endif
- start->Torus().Direct();
-
// creation de la generatrice : Generatrix (cercle)
gp_Ax2 Axe = gp_Ax2(gp_Pnt((start->Torus().MajorRadius()), 0., 0.),
-gp::DY(), gp::DX());
if (DrawTrSurf::GetPoint(a[5], P3)) {
// if (DrawTrSurf::GetPoint(a[6], P4)) {
if (n>6) {
-#ifdef DEB
- Standard_Boolean ip4 =
-#endif
- DrawTrSurf::GetPoint(a[6], P4);
+ DrawTrSurf::GetPoint(a[6], P4);
gp_Vec V1 = gp_Vec(P2,P3);
Handle(Geom_Curve)thearc = GC_MakeArcOfCircle(P1,V1,P4).Value();
DrawTrSurf::Set(a[1], thearc);
theUfMax = 0.;
theUlMax = 0.;
theImax = 0;
- Standard_Real dmax = 0., ufmax = 0., ulmax = 0.;
- Standard_Integer imax = 0;
+ Standard_Real ufmax = 0., ulmax = 0.;
//take knots
Standard_Integer nbp = thePnts->NbKnots();
Draw::Set(a[1], aDrCrv);
- Standard_Real dmax = 0., ufmax = 0., ulmax = 0., uf, ul;
+ Standard_Real dmax = 0., ufmax = 0., ulmax = 0.;
Standard_Integer imax = 0;
ComputeDeviation(C,aPnts,dmax,ufmax,ulmax,imax);
Standard_Boolean mySquare = (methode == 2);
Standard_Integer degmin = 4;
Standard_Integer NbIteration = 5;
-#ifdef DEB
- Standard_Integer NbConst =
-#endif
- NbConstraint(TABofCC->Value(1).Constraint(),
- TABofCC->Value(NbPoints).Constraint());
if (Degree < 4) degmin = Max(1, Degree -1);
degmin = Max(degmin, NbConstraint(TABofCC->Value(1).Constraint(),
const Standard_Integer aRow,
const Standard_Integer aColumn) {
Standard_Integer i,length = myTextDescriptorList.Length() ;
-#ifdef DEB
-Standard_Integer row = (aRow > 0) ? Min(aRow,MAXROW-1) : MAXROW-1 ;
-Standard_Integer column = (aColumn > 0) ? Min(aColumn,MAXCOLUMN-1) : MAXCOLUMN-1 ;
-#endif
+
Standard_Integer descriptor = TEXT_DESCRIPTOR(aRow,aColumn,0,0,0,0) ;
Standard_Integer the_position = TEXT_POSITION(descriptor) ;
const Handle(Graphic2d_Drawer)& aDrawer)
{
Standard_Boolean theStatus = Standard_False;
-#ifdef DEB
-Standard_ShortReal scale =
-#endif
- (myIsZoomable) ? myScale*aDrawer->Scale() : myScale;
Standard_ShortReal TX = X, TY = Y;
if (IsInMinMax (X, Y, aPrecision)) {
Standard_Integer nvertexs = myPrimitiveArray->num_vertexs;
Standard_Integer nbounds = myPrimitiveArray->num_bounds;
Standard_Integer nedges = myPrimitiveArray->num_edges;
- Standard_Integer i,j,k,n;
+ Standard_Integer i,n;
#if TRACE > 0
Standard_CString name = StringType();
{
BRep_Builder B;
TopExp_Explorer exE, exW;
- Standard_Boolean splitted = Standard_False;
+ //Standard_Boolean splitted = Standard_False;
TopTools_IndexedDataMapOfShapeListOfShape aVEMap;
TopExp::MapShapesAndAncestors(F, TopAbs_VERTEX, TopAbs_EDGE, aVEMap);
printf("\n P:%+10.5g Tg2d:%+10.5g , %+10.5g N2d:%+10.5g , %+10.5g Crv:%+10.5g\n\n",
Point.Parameter(),Tangente.X(),Tangente.Y(),Normale.X(),Normale.Y(),Courbure);
#endif
-#ifdef DEB
- Standard_Real ParamAtIntersection =
-#endif
- Point.Parameter();
for (Standard_Integer IPntE = 1 ; IPntE <= Point.NbPoints() ; IPntE++) {
const HatchGen_PointOnElement& PntE = Point.Point (IPntE) ;
{
Handle(Standard_Transient) item = NamedItem(name);
if (item.IsNull()) return Standard_False;
-#ifdef DEB
- Standard_Integer bid =
-#endif
- theitems.Add(item,item); // reste mais sans nom
+ theitems.Add(item,item); // reste mais sans nom
return thenames->RemoveItem(name);
}
ProdVectTan=Tan1.Crossed(Tan2);
- Standard_Boolean IsInDomain=Standard_True;
-
//#####################################################################
//## Longueur Minimale d un segment Sur Courbe 1
//#####################################################################
,const Standard_Real TheTol)
{
- Standard_Boolean AnErrorOccurred = Standard_False;
-
this->ResetFields();
DomainOnCurve1=D1;
DomainOnCurve2=D1;
IntCurveSurface_TheQuadCurvExactInter QuadCurv(surface,curve);
if(QuadCurv.IsDone()) {
Standard_Integer NbRoots = QuadCurv.NbRoots();
-#ifdef DEB
- Standard_Integer NbInter = QuadCurv.NbIntervals();
-#else
- QuadCurv.NbIntervals();
-#endif
Standard_Real u,v,w;
for(Standard_Integer i = 1; i<= NbRoots; i++) {
w = QuadCurv.Root(i);
IntCurveSurface_TheQuadCurvExactInter QuadCurv(surface,curve);
if(QuadCurv.IsDone()) {
Standard_Integer NbRoots = QuadCurv.NbRoots();
-#ifdef DEB
- Standard_Integer NbInter = QuadCurv.NbIntervals();
-#else
- QuadCurv.NbIntervals();
-#endif
Standard_Real u,v,w;
for(Standard_Integer i = 1; i<= NbRoots; i++) {
w = QuadCurv.Root(i);
//ddout << "IntCurveSurface_Polygon::Init" << endl;
Standard_Real u=Binf;
- Standard_Real u1=Bsup;
Standard_Integer i=1, i0 = Upars.Lower()-1;
gp_Pnt P;
Standard_Integer& TriCon,
Standard_Integer& OtherP) const
{
-#ifdef DEB
- Standard_Integer nbdeltaUp1 = nbdeltaU + 1;
- Standard_Integer nbdeltaUm2 = nbdeltaU + nbdeltaU;
-#endif
Standard_Integer Pivotm1 = Pivot-1;
Standard_Integer nbdeltaVp1 = nbdeltaV+1;
Standard_Integer nbdeltaVm2 = nbdeltaV + nbdeltaV;
nbvtx = NbVertex();
if(nbvtx>1) {
IntPatch_Point& VTX0 = svtx.ChangeValue(1);
-#ifdef DEB
- //Standard_Real d;
- IntPatch_Point& VTX1 =
-#endif
- svtx.ChangeValue(2);
if( (VTX0.IsOnDomS1() == Standard_False)
&& (VTX0.IsOnDomS2() == Standard_False)) {
svtx.Remove(1);
}
if(nbvtx>1) {
IntPatch_Point& VTX0 = svtx.ChangeValue(nbvtx);
-#ifdef DEB
- IntPatch_Point& VTX1 =
-#endif
- svtx.ChangeValue(nbvtx-1);
if( (VTX0.IsOnDomS1() == Standard_False)
&& (VTX0.IsOnDomS2() == Standard_False)) {
svtx.Remove(nbvtx);
//-- 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
- Standard_Real anpara=para;
-#endif
+//#ifdef DEB
+// Standard_Real anpara=para;
+//#endif
gp_Pnt CopiePsurf=Psurf;
Standard_Boolean ok=IntersectionWithAnArc(CopiePsurf,alin,para,thearc,theparamonarc,thepointonarc,QuadSurf,lower,upper,dist);
Standard_Real BSEAM = 1.5*M_PI; // delta U crossing seam
Standard_Real BAPEX = M_PI/16.; // delta U crossing apex
- Standard_Integer i = 0, k = 0;
+ Standard_Integer k = 0;
Standard_Real U1 = 0., U2 = 0., V1 = 0., V2 = 0., AnU1 = 0., AnV1 = 0., DU1 = 0., DV1 = 0.;
Standard_Integer Findex = 1, Lindex = NbPnts, Bindex = 0;
}
else if (typl != IntPatch_Restriction) { // JAG 01.07.96
Standard_Real u1,v1,u2,v2;
-#ifdef DEB
- Standard_Real paramminonvtx=RealLast();
- Standard_Real parammaxonvtx=-paramminonvtx;
-#endif
Handle(IntPatch_GLine)& GLine
= *((Handle(IntPatch_GLine) *)&L);
slin.Clear();
gp_XYZ XYZ3=P1.XYZ()-P3.XYZ();
gp_Vec NormalVector((XYZ1^XYZ2)+(XYZ2^XYZ3)+(XYZ3^XYZ1));
NormalVector.Normalize();
-#ifdef DEB
- Standard_Real PolarDistance = NormalVector * P1.XYZ();
-#endif
//-- Calcul du point u,v au centre du triangle
Standard_Real u = (u1+u2+u3)/3.0;
Standard_Real v = (v1+v2+v3)/3.0;
Standard_Integer& TriCon,
Standard_Integer& OtherP) const {
-#ifdef DEB
- Standard_Integer nbdeltaUp1 = nbdeltaU + 1;
- Standard_Integer nbdeltaUm2 = nbdeltaU + nbdeltaU;
-#endif
Standard_Integer Pivotm1 = Pivot-1;
Standard_Integer nbdeltaVp1 = nbdeltaV+1;
Standard_Integer nbdeltaVm2 = nbdeltaV + nbdeltaV;
Standard_Integer& indice)
{
int k=indice>>5;
- Standard_Integer r=0;
while(k<Isize)
{
Standard_Integer r=((Standard_Integer *) p)[k] & ((Standard_Integer *) Oth.p)[k];
Standard_Integer nbCouplesStd = 0;
Standard_Integer nbCouplesAdv = 0;
- GeomAbs_SurfaceType ST1 = mySurf1->GetType();
- GeomAbs_SurfaceType ST2 = mySurf2->GetType();
+ //GeomAbs_SurfaceType ST1 = mySurf1->GetType();
+ //GeomAbs_SurfaceType ST2 = mySurf2->GetType();
// if(ST1 == GeomAbs_Torus || ST2 == GeomAbs_Torus)
// startFromAdvanced = Standard_True;
Standard_Boolean bDegI, bDeg;
Standard_Integer aNbU, aNbV, iCnt, i, j;
Standard_Integer aID1, aID2, aJD1, aJD2;
- Standard_Real aTol, aU, aV, aX, aY, aZ, aDegX, aTol2;
+ Standard_Real aTol, aU, aV, aX, aY, aZ;
gp_Pnt aP;
//
aNbU=(SurfID==1)? NbSamplesU1 : NbSamplesU2;
const IntRes2d_IntersectionPoint& AnP1=lseg(j).FirstPoint();
Standard_Real AnP1PParamOnFirst=AnP1.ParamOnFirst();
Standard_Real AnP1PParamOnSecond=AnP1.ParamOnSecond();
-#if DEB
- const IntRes2d_Transition& AnP1T1=AnP1.TransitionOfFirst();
-#else
- AnP1.TransitionOfFirst();
-#endif
-#if DEB
- const IntRes2d_Transition& AnP1T2=AnP1.TransitionOfSecond();
-#else
- AnP1.TransitionOfSecond();
-#endif
-#if DEB
- const gp_Pnt2d& AnPt1=AnP1.Value();
-#else
- AnP1.Value();
-#endif
const IntRes2d_IntersectionPoint& AnP2=lseg(j).LastPoint();
Standard_Real AnP2PParamOnFirst=AnP2.ParamOnFirst();
Standard_Real AnP2PParamOnSecond=AnP2.ParamOnSecond();
-#if DEB
- const IntRes2d_Transition& AnP2T1=AnP2.TransitionOfFirst();
-#else
- AnP2.TransitionOfFirst();
-#endif
-#if DEB
- const IntRes2d_Transition& AnP2T2=AnP2.TransitionOfSecond();
-#else
- AnP2.TransitionOfSecond();
-#endif
-#if DEB
- const gp_Pnt2d& AnPt2=AnP2.Value();
-#else
- AnP2.Value();
-#endif
-
if(Opposite == lseg(j).IsOpposite()) {
//---------------------------------------------------------------
//Standard_Integer aNbNodes = 23;
Standard_Real aDelta = (parap1 - para)/(aNbNodes + 1.);
Standard_Integer ii;
- Standard_Real aMinPar = Pdeb - 1.;
Standard_Real aCurPar;
Standard_Real aCurVal;
Standard_Boolean bFlag;
Standard_Real Umin, Usup, Vmin, Vsup;
- const Handle(Geom_Surface)& GS=BRep_Tool::Surface(myFace);
Umin=myS.FirstUParameter();
Usup=myS.LastUParameter();
Vmin=myS.FirstVParameter();
aD=aD-myCriteria;
return aD;
}
- //
- const Handle(Geom_Surface)& GS=BRep_Tool::Surface(myFace);
Umin=myS.FirstUParameter();
Usup=myS.LastUParameter();
//ZZ
{// Check the distances
- Standard_Boolean bIsDone;
Standard_Integer i, j, aNbP;
Standard_Real aT, aT1, aT2, dT, aD2, aD2Max;
//
etat1(I) = etat1(I) + 1;
Standard_Integer etat1I=etat1(I);
-#ifdef DEB
- Standard_Integer multi=0;
-#endif
//-- cout<<" \n Etat1("<<I<<") = "<<etat1I<<endl;
if(etat1I==2) { //-- lbr le 15 fev 99
etat1(I)=11;
//IFV for OCC20285
-
- Standard_Real tolustolv=tolu/tolv;
-
if ((Abs(Du) < tolu2 && Abs(Dv) < tolv2) ||
(Abs(Dup) < tolu2 && Abs(Dvp) < tolv2)) {
if (Arrive) {
static math_Vector bidF(1,1);
static math_Matrix bidD(1,1,1,2);
-#ifdef DEB
- Standard_Boolean bidB =
-#endif
- sp.Values(UV,bidF,bidD);
+ sp.Values(UV,bidF,bidD);
break;
}
}
UV(2) = V1;
static math_Vector bidF(1,1);
static math_Matrix bidD(1,1,1,2);
-#ifdef DEB
- Standard_Boolean bidB =
-#endif
- sp.Values(UV,bidF,bidD);
+ sp.Values(UV,bidF,bidD);
break;
}
}
if (Found) {
static math_Vector bidF(1,1);
static math_Matrix bidD(1,1,1,2);
-#ifdef DEB
- Standard_Boolean bidB =
-#endif
- sp.Values(UV,bidF,bidD);
+ sp.Values(UV,bidF,bidD);
Standard_Integer NBP = Line->NbPoints();
Standard_Integer Indextg;
Line->TangentVector(Indextg);
Irang = -Irang; // jag 941017
static math_Vector bidF(1,1);
static math_Matrix bidD(1,1,1,2);
-#ifdef DEB
- Standard_Boolean bidB =
-#endif
- sp.Values(UV,bidF,bidD);
+ sp.Values(UV,bidF,bidD);
return;
}
}
if (Arrive) {
static math_Vector bidF(1,1);
static math_Matrix bidD(1,1,1,2);
-#ifdef DEB
- Standard_Boolean bidB =
-#endif
- sp.Values(UV,bidF,bidD);
+ sp.Values(UV,bidF,bidD);
break;
}
}
if (Case == 1)
Psol.SetValue(sp.Point(),reversed, U, V);
else if (Case == 2) {
-#ifdef DEB
- Standard_Boolean foo = sp.IsTangent();
-#endif
Psol.SetValue(sp.Point(),reversed, U, V);
}
else if (Case == 11 || Case == 12 ) {
const Standard_Real v2max)
{
//xf
- Standard_Integer iCnt=0;
Standard_Integer i, NbPasOKConseq;
Standard_Real UFirst1, VFirst1, ULast1, VLast1, UFirst2, VFirst2, ULast2, VLast2;
Standard_Real pasMaxSV[4], aTmp;
{
// Evaluation d un Graphe de dependances : sur chaque Entite, on prend sa
// liste "Shared". On en deduit les "Sharing" directement
- Standard_Integer n = Size(), total = 0;
+ Standard_Integer n = Size();
thesharings = new TColStd_HArray1OfListOfInteger(1,n);//TColStd_HArray1OfTransient(1,n);//Clear();
if(themodel->GTool().IsNull())
return;
while (clt.More()) {
indTri=clt.Value();
// Modified by MKK - Thu Oct 25 12:40:11 2007 Begin
- Standard_Integer prevSize = mySPoins.Length();
Standard_Integer pTri[3];
ToolPolyh::Triangle(thePolyh, indTri, pTri[0], pTri[1], pTri[2]);
Standard_Integer pTri[3];
ToolPolyh::Triangle(thePolyh, TTri, pTri[0], pTri[1], pTri[2]);
gp_XYZ triNor = TriNormal; // Vecteur normal.
- Standard_Real triDp = TriDp; // Distance polaire.
+ //Standard_Real triDp = TriDp; // Distance polaire.
// Standard_Real dBegTri=(triNor*BegO.XYZ())-triDp; // Distance <BegO> plan
const Standard_Boolean Periodic)
{
Standard_Integer l = ParAndRad.Lower();
-#ifdef DEB
- Standard_Integer u =
-#endif
- ParAndRad.Upper();
Standard_Integer nbp = ParAndRad.Length();
Handle(TColStd_HArray1OfReal) par = new TColStd_HArray1OfReal(1,nbp);
const Standard_Boolean Periodic)
{
Standard_Integer l = ParAndRad.Lower();
-#ifdef DEB
- Standard_Integer u =
-#endif
- ParAndRad.Upper();
Standard_Integer nbp = ParAndRad.Length();
Handle(TColStd_HArray1OfReal) par = new TColStd_HArray1OfReal(1,nbp);
for (; exp.More(); exp.Next()) {
const TopoDS_Face& theface = TopoDS::Face(exp.Current());
IntCurvesFace_Intersector theInt(theface,0.);
-#ifdef DEB
- TopAbs_Orientation orface =
-#endif
- theface.Orientation();
for (Standard_Integer i = 1; i<=myNbelem; i++) {
HC->ChangeCurve().Load(new Geom_Circle(Scir(i)));
for (; exp.More(); exp.Next()) {
const TopoDS_Face& theface = TopoDS::Face(exp.Current());
IntCurvesFace_Intersector theInt(theface,0.);
-#ifdef DEB
- TopAbs_Orientation orface =
-#endif
- theface.Orientation();
for (Standard_Integer i = 1; i<=myNbelem; i++) {
if (Scur(i).IsNull()) {
continue;
Standard_Integer nbpoints = theSeq.Length();
Standard_Integer newpnt = theInt.NbPnt();
Standard_Real param,paramu,paramv;
-#ifdef DEB
- TopAbs_Orientation orface =
-#endif
- theface.Orientation();
for (Standard_Integer j = 1; j<=newpnt; j++) {
const gp_Pnt& thept = theInt.Pnt(j);
param = theInt.WParameter(j);
L.AddConstEdges(listofedg);
L.Perform();
L.WiresToFaces();
-#ifdef DEB
- const TopTools_ListOfShape& listofwires =
-#endif
- L.NewWires();
const TopTools_ListOfShape& listoffaces = L.NewFaces();
toRemove.Add(fac);
// if (!HasWire) {
TopoDS_Vertex Vf2,Vl2;
TopExp::Vertices(TopoDS::Edge(Gvf),Vf2,Vl2);
-#ifdef DEB
- TopAbs_Orientation ornw =
-#endif
- NewEdg.Orientation();
+
+ //TopAbs_Orientation ornw = NewEdg.Orientation();
// ici bug orientation : voir tspdrft6
TopoDS_Vertex Vf2,Vl2;
TopExp::Vertices(TopoDS::Edge(Gvl),Vf2,Vl2);
-#ifdef DEB
- TopAbs_Orientation ornw =
-#endif
- NewEdg.Orientation();
+
+ //TopAbs_Orientation ornw = NewEdg.Orientation();
// ici bug orientation : voir tspdrft6
TopoDS_Shape aLocalShape = F.EmptyCopied();
TopoDS_Face newFace = TopoDS::Face(aLocalShape);
// TopoDS_Face newFace = TopoDS::Face(F.EmptyCopied());
-#ifdef DEB
- TopAbs_Orientation orWire =
-#endif
- W2.Orientation();
+
+ //TopAbs_Orientation orWire = W2.Orientation();
+
newFace.Orientation(TopAbs_FORWARD);
B.Add(newFace,W2);
// GProp_GProps GP;
//gp_Vec2d Tan1,Tan2;
gp_Pnt2d Ori; //PEdge;
Standard_Integer IPrec,INext;
-#ifdef DEB
- Standard_Real Tolerance = MAT2d_TOLCONF;
-#endif
IPrec = (IndexEdge == 1) ? theCircuit->NumberOfItems() : (IndexEdge - 1);
INext = (IndexEdge == theCircuit->NumberOfItems()) ? 1 : (IndexEdge + 1);
Handle(PXCAFDoc_Area) S = Handle(PXCAFDoc_Area)::DownCast (Source);
Handle(XCAFDoc_Area) T = Handle(XCAFDoc_Area)::DownCast (Target);
-#ifdef DEB
- PTColStd_PersistentTransientMap& PTMap =
-#endif
- RelocTable->OtherTable();
T->Set(S->Get());
}
Handle(XCAFDoc_Area) S = Handle(XCAFDoc_Area)::DownCast (Source);
Handle(PXCAFDoc_Area) T = Handle(PXCAFDoc_Area)::DownCast (Target);
-#ifdef DEB
- PTColStd_TransientPersistentMap& TPMap =
-#endif
- RelocTable->OtherTable();
T->Set(S->Get());
}
Handle(PXCAFDoc_Centroid) S = Handle(PXCAFDoc_Centroid)::DownCast (Source);
Handle(XCAFDoc_Centroid) T = Handle(XCAFDoc_Centroid)::DownCast (Target);
-#ifdef DEB
- PTColStd_PersistentTransientMap& PTMap =
-#endif
- RelocTable->OtherTable();
T->Set(S->Get());
}
Handle(XCAFDoc_Centroid) S = Handle(XCAFDoc_Centroid)::DownCast (Source);
Handle(PXCAFDoc_Centroid) T = Handle(PXCAFDoc_Centroid)::DownCast (Target);
-#ifdef DEB
- PTColStd_TransientPersistentMap& TPMap =
-#endif
- RelocTable->OtherTable();
T->Set(S->Get());
}
Handle(PXCAFDoc_Datum) S = Handle(PXCAFDoc_Datum)::DownCast (Source);
Handle(XCAFDoc_Datum) T = Handle(XCAFDoc_Datum)::DownCast (Target);
-#ifdef DEB
- PTColStd_PersistentTransientMap& PTMap =
-#endif
- RelocTable->OtherTable();
Handle(TCollection_HAsciiString) aName, aDescr, anId;
if ( !S->GetName().IsNull() )
aName = new TCollection_HAsciiString( (S->GetName())->Convert() );
{
Handle(XCAFDoc_Datum) S = Handle(XCAFDoc_Datum)::DownCast (Source);
Handle(PXCAFDoc_Datum) T = Handle(PXCAFDoc_Datum)::DownCast (Target);
-#ifdef DEB
- PTColStd_TransientPersistentMap& TPMap =
-#endif
- RelocTable->OtherTable();
Handle(TCollection_HAsciiString) aNameStr = S->GetName();
Handle(TCollection_HAsciiString) aDescrStr = S->GetDescription();
Handle(TCollection_HAsciiString) anIdStr = S->GetIdentification();
Handle(PXCAFDoc_DimTol) S = Handle(PXCAFDoc_DimTol)::DownCast (Source);
Handle(XCAFDoc_DimTol) T = Handle(XCAFDoc_DimTol)::DownCast (Target);
-#ifdef DEB
- PTColStd_PersistentTransientMap& PTMap =
-#endif
- RelocTable->OtherTable();
Handle(TColStd_HArray1OfReal) aVals;
Handle(PColStd_HArray1OfReal) aPArr = S->GetVal();
if ( !aPArr.IsNull() )
{
Handle(XCAFDoc_DimTol) S = Handle(XCAFDoc_DimTol)::DownCast (Source);
Handle(PXCAFDoc_DimTol) T = Handle(PXCAFDoc_DimTol)::DownCast (Target);
-#ifdef DEB
- PTColStd_TransientPersistentMap& TPMap =
-#endif
- RelocTable->OtherTable();
Handle(TColStd_HArray1OfReal) aHArr = S->GetVal();
Handle(PColStd_HArray1OfReal) aVals;
if ( !aHArr.IsNull() )
Handle(PXCAFDoc_Material) S = Handle(PXCAFDoc_Material)::DownCast (Source);
Handle(XCAFDoc_Material) T = Handle(XCAFDoc_Material)::DownCast (Target);
-#ifdef DEB
- PTColStd_PersistentTransientMap& PTMap =
-#endif
- RelocTable->OtherTable();
Handle(TCollection_HAsciiString) aName, aDescr, aDensName, aDensValType;
if ( !S->GetName().IsNull() )
aName = new TCollection_HAsciiString( (S->GetName())->Convert() );
{
Handle(XCAFDoc_Material) S = Handle(XCAFDoc_Material)::DownCast (Source);
Handle(PXCAFDoc_Material) T = Handle(PXCAFDoc_Material)::DownCast (Target);
-#ifdef DEB
- PTColStd_TransientPersistentMap& TPMap =
-#endif
- RelocTable->OtherTable();
Handle(TCollection_HAsciiString) aNameStr = S->GetName();
Handle(TCollection_HAsciiString) aDescrStr = S->GetDescription();
Handle(TCollection_HAsciiString) aDensNameStr = S->GetDensName();
Handle(PXCAFDoc_Volume) S = Handle(PXCAFDoc_Volume)::DownCast (Source);
Handle(XCAFDoc_Volume) T = Handle(XCAFDoc_Volume)::DownCast (Target);
-#ifdef DEB
- PTColStd_PersistentTransientMap& PTMap =
-#endif
- RelocTable->OtherTable();
T->Set(S->Get());
}
Handle(XCAFDoc_Volume) S = Handle(XCAFDoc_Volume)::DownCast (Source);
Handle(PXCAFDoc_Volume) T = Handle(PXCAFDoc_Volume)::DownCast (Target);
-#ifdef DEB
- PTColStd_TransientPersistentMap& TPMap =
-#endif
- RelocTable->OtherTable();
T->Set(S->Get());
}
Aspect_TypeOfDisplayText ADisplayType = Aspect_TODT_NORMAL;
TCollection_AsciiString AFontString;
Standard_Integer ADispInt;
- Standard_Boolean ATexFont;
// Bold font is used by default for better text readability
OSD_FontAspect AFontAspectType = OSD_FA_Bold;
Standard_Integer AAspect;
Tint nf, nv, nr, nc;
Tint lighting_model;
- tel_point pfn = myData.fnormals;
tel_colour pfc = myData.fcolours;
tel_point pv = myData.vertices;
tel_colour pvc = myData.vcolours;
const OpenGl_AspectLine *aspect_line_old = AWorkspace->SetAspectLine( aspect_face->AspectEdge() );
AWorkspace->AspectLine( Standard_True );
- tel_point pv = myData.vertices;
Tint nc = myData.num_columns;
Tint nf = myData.num_rows * myData.num_columns;
{
Tint i, newList = 0;
- tel_point pfn = myData.fnormals;
tel_colour pfc = myData.fcolours;
tel_point pv = myData.vertices;
tel_colour pvc = myData.vcolours;
// setup printing context and viewport
GLint aViewPortBack[4];
- GLint aReadBufferPrev = GL_BACK;
GLint anAlignBack = 1;
OpenGl_PrinterContext aPrinterContext (myGContext);
F.Value(X, FVal);
-#ifdef DEB
- Standard_Real FuncVal= FVal(1)*FVal(1) + FVal(2)*FVal(2);
-#endif
if ((FVal(1)*FVal(1) + FVal(2)*FVal(2)) > FuncTol) myDone = Standard_False;
}
else {
myShRef = aShto.Sharings(theEL2);
myShRef.SelectType (STANDARD_TYPE(StepShape_FaceBound),Standard_True);
-#ifdef DEB
- Standard_Integer nbRef =
-#endif
- myShRef.NbEntities();
myShRef.Start();
Handle(StepShape_FaceBound) theFB2 =
Handle(StepShape_FaceBound)::DownCast(myShRef.Value());
const Standard_Real YMax,
const Standard_Real aTol)
{//distance point-Line....
-#ifdef DEB
- Standard_Real TheTol = HasOwnTolerance()? myOwnTolerance : aTol;
-#endif
Standard_Real MinDist = gp_Lin2d(gp_Pnt2d(XMin,YMin),
gp_Vec2d(gp_Pnt2d(XMin,YMin),
gp_Pnt2d(XMax,YMax))
gp_XY V02(p2);V02-=p0;
gp_XY V12(p2);V12-=p1;
- Standard_Real TolTol = aTol*aTol;
-
// check these particular cases...
// if one of vectors is almost null (2 points are mixed),
// leave at once (it is already in the bounding box, which is good...)
if(myDetectedTr==-1)
return Standard_False; // currently not implemented...
const Poly_Array1OfTriangle& triangles = myTriangul->Triangles();
- const TColgp_Array1OfPnt& Nodes = myTriangul->Nodes();
Standard_Integer n1,n2,n3;
triangles( myDetectedTr ).Get(n1,n2,n3);
const Standard_Real aTol,
Standard_Real& DMin)
{
- Standard_Boolean Found= Standard_False;
const Standard_Real SqTol = aTol * aTol;
gp_Vec2d AB, AC, BC;
const gp_Pnt2d apoint(X,Y);
//const Handle(ShapeExtend_WireData)& sewd)
{
- Standard_Integer i =1, nbc = 0;
+ Standard_Integer nbc = 0;
gp_Pnt fuv,luv, uv0;
//Standard_Real totcross=0;
gp_XYZ aTotal(0.,0.,0.);
return res;
}
- TopAbs_ShapeEnum st = shape.ShapeType(), subt;
+ TopAbs_ShapeEnum st = shape.ShapeType();
if ( st >= until ) return newsh; // critere d arret
if(st == TopAbs_VERTEX || st == TopAbs_SHAPE)
return shape;
if(!myRemoveEdges.IsBound(aE) ) {
const TopTools_ListOfShape& aLface3 = myEdgeFaces.FindFromKey(aE);
TopTools_ListIteratorOfListOfShape aliter3(aLface3);
- Standard_Boolean isRemoved = Standard_True;
for( ; aliter3.More();aliter3.Next()) {
TopoDS_Shape aF2 = Context()->Apply(aliter3.Value());
if(aF2.IsNull())
theTriangles.Assign(theTriangulation->Triangles());
Mesh->AddDomain (Deflection);
-#ifdef DEB
- TopAbs_Orientation orientation =
-#endif
- face.Orientation();
-
TColgp_Array1OfPnt thePoints(1, theTriangulation->NbNodes());
thePoints.Assign(theTriangulation->Nodes());
//compute normal of face
{
if (aDataSet->IsEmpty()) return;
-#ifdef DEB
- TDF_LabelMap& refLabs =
-#endif
- aDataSet->Labels();
const TDF_AttributeMap& refAtts = aDataSet->Attributes();
// Removes the attributes.
TFunction_IFunction iFunction(L);
Handle(TFunction_GraphNode) graphNode = iFunction.GetGraphNode();
- const TColStd_MapOfInteger& prev = graphNode->GetPrevious();
const TColStd_MapOfInteger& next = graphNode->GetNext();
TFunction_ExecutionStatus status = graphNode->GetStatus();
isCommon = Standard_True; // statement: this shape (itm.Key()) is common (to be checked below)
TNaming_DataMapIteratorOfDataMapOfShapeMapOfShape itdm(aDMM);
for (;itdm.More();itdm.Next()) {
- const TopoDS_Shape& aKey1 = itdm.Key();
const TNaming_MapOfShape& aMap = itdm.Value();
if(!aMap.Contains(itm.Key())) {
isCommon = Standard_False;
TCollection_ExtendedString txt;
TPrsStd_ConstraintTools::ComputeTextAndValue (aConst,val1,txt,Standard_True);
-// Unused :
-#ifdef DEB
- Standard_Boolean isface(shape.ShapeType()==TopAbs_FACE);
-#endif
-
Handle(AIS_AngleDimension) ais;
TopoDS_Face face;
if (!anAIS.IsNull()) {
ais = new AIS_AngleDimension ( face, val1, txt);
}
-// Unused :
-#ifdef DEB
- Standard_Integer ExtShape(0);
-#endif
-
anAIS = ais;
}
ComputeTextAndValue(aConst,val1,txt,Standard_False);
// Update de l'AIS
-// Unused :
-#ifdef DEB
- Standard_Boolean tocreate = Standard_True;
-#endif
Standard_Boolean isplanar(aConst->IsPlanar());
if (isplanar) GetGoodShape(shape1);
ComputeTextAndValue(aConst,val1,txt,Standard_False);
// Update de l'AIS
-// Unused :
-#ifdef DEB
- Standard_Boolean tocreate = Standard_True;
-#endif
Standard_Boolean isplanar(aConst->IsPlanar());
if (isplanar) GetGoodShape(shape1);
ComputeTextAndValue(aConst,val1,txt,Standard_False);
// Update de l'AIS
-// Unused :
-#ifdef DEB
- Standard_Boolean tocreate = Standard_True;
-#endif
Standard_Boolean isplanar(aConst->IsPlanar());
if (isplanar) GetGoodShape(shape1);
DBRep::Set(namie.ToCString(),es);
if (eca) {
TCollection_AsciiString s;
-#ifdef DEB
- Standard_Integer i1 =
-#endif
- BDS.Shape(F1);
-#ifdef DEB
- Standard_Integer i2 =
-#endif
- BDS.Shape(F2);
+
if (outdraw) {
if (outclear) s = s + "clear; ";
::CATSHA(s,F1,BDS,"tsee f ","; ");
TopOpeBRepBuild_ShellToSolid SheToSo;
for (; itm.More(); itm.Next()) {
const TopTools_ListOfShape& lns = itm.Value();
-#ifdef DEB
- Standard_Integer nlns =
-#endif
- lns.Extent();
TopTools_ListIteratorOfListOfShape itsh(lns);
for (; itsh.More(); itsh.Next()) {
const TopoDS_Shell& she = TopoDS::Shell(itsh.Value());
TopoDS_Shape W1 = DBRep::Get(a[1]);
TopoDS_Shape W2 = DBRep::Get(a[2]);
TopoDS_Shape F = DBRep::Get(a[3]);
-#ifdef DEB
- Standard_Integer i = atoi(a[4]);
-#endif
TopoDS_Wire w1 = TopoDS::Wire(W1);
TopoDS_Wire w2 = TopoDS::Wire(W2);
for(i = 1;i<=nbsh;i++) {
TopTools_ListOfShape& los = DS.ChangeShapeSameDomain(i);
j = los.Extent();
-#ifdef DEB
- Standard_Integer iref =
-#endif
- DS.SameDomainRef(i);
-#ifdef DEB
- Standard_Integer iind =
-#endif
- DS.SameDomainInd(i);
+
TopTools_ListIteratorOfListOfShape li(los);
for(; li.More(); li.Next()) {
#ifdef DEB
if ( ISE < 1 || ISE > nse ) return 0;
const TopoDS_Shape& SE = PHDSD->CurrentBDS().SectionEdge(ISE);
if (SE.IsNull()) return 0;
-#ifdef DEB
- Standard_Integer ids =
-#endif
- PHDSD->CurrentBDS().Shape(SE,SFindKeep);
TCollection_AsciiString namedbrep; PHDSD->SectionEdgeName(ISE,SE,namedbrep);
TCollection_AsciiString namedisp; PHDSD->SectionEdgeDisplayName(ISE,SE,namedisp);
const TopOpeBRepDS_DataStructure& BDS = PHDSD->CurrentBDS();
-#ifdef DEB
- Standard_Integer ig,ng = 0;
-#endif
if (TK == TopOpeBRepDS_POINT) {
TopOpeBRepDS_PointExplorer pex(BDS,GFindKeep);
for (; pex.More(); pex.Next()) {
if (PHDSD == NULL) return 0;
const Handle(TopOpeBRepDS_HDataStructure)& HDS = PHDSD->CurrentHDS();
if (HDS.IsNull()) {COUTNOHDS(di);return 0;}
-#ifdef DEB
- const TopOpeBRepDS_DataStructure& BDS =
-#endif
- PHDSD->CurrentBDS();
+ PHDSD->CurrentBDS();
TopOpeBRepDS_Dumper Dumper(HDS);
if ( na == 1 ) { Dumper.Dump(cout,TDSkeep,TDScompact); return 0; }
void TestTopOpeDraw_SurfaceDisplayer::DisplaySurface(const Handle(Geom_Surface& S))
{
if (S.IsNull()) return;
-#ifdef DEB
- Draw_ColorKind isocol =
-#endif
- TestTopOpeDraw_TTOT::GeometryColor(TopOpeBRepDS_SURFACE);
Handle(TestTopOpeDraw_DrawableSUR) D;
D = new TestTopOpeDraw_DrawableSUR
(S,mySDIsoColor,mySDBoundColor,mySDNormalColor,
C = "";C = C + P.Coord(2);
TCollection_AsciiString S1 = C.Token(".",1);
-#ifdef DEB
- Standard_Integer l =
-#endif
- S1.Length();
S1.RightJustify(15, ' ');
TCollection_AsciiString S2 = C.Token(".",2);
S2.Trunc(2);
if ( GK != TopOpeBRepDS_VERTEX ) continue;
const TopoDS_Shape& v = BDS.Shape(GI);
-#ifdef DEB
- Standard_Boolean isb =
-#endif
- SSI->GBound();
Standard_Boolean vofe = imev.Contains(v);
SSI->SetGBound(vofe);
} // it.More()
const TopoDS_Edge& e2 = TopoDS::Edge(BDS.Shape(S1));
if (!map2.Contains(e2)) continue;
-#ifdef DEB
- Standard_Integer G1 =
-#endif
- I1->Geometry(); TopOpeBRepDS_Kind GT1 = I1->GeometryType();
+ TopOpeBRepDS_Kind GT1 = I1->GeometryType();
if (GT1 == TopOpeBRepDS_POINT) {
Handle(TopOpeBRepDS_CurvePointInterference) CPI1 = Handle(TopOpeBRepDS_CurvePointInterference)::DownCast(I1);
Standard_Real par1 = CPI1->Parameter();
const TopoDS_Shape& gs2 = myShapeIntersector.CurrentGeomShape(2);
TopAbs_ShapeEnum t1 = gs1.ShapeType();
TopAbs_ShapeEnum t2 = gs2.ShapeType();
-#ifdef DEB
- TopAbs_Orientation o1 =
-#endif
- gs1.Orientation();
-#ifdef DEB
- TopAbs_Orientation o2 =
-#endif
- gs2.Orientation();
// si le couple courant apres un couple facefacesamedomain n'est
// pas un couple edgeedge ==> facefacesamedomain est deconnecte
TopTools_ListIteratorOfListOfShape itsd(lSsd);
for (; itsd.More(); itsd.Next()){
TopoDS_Shape Ssd = itsd.Value(); //xpuxpu
-#ifdef DEB
- Standard_Integer iSsd =
-#endif
- BDS.Shape(Ssd);
Standard_Integer rkSsd = BDS.AncestorRank(Ssd);
if (rkSsd == 1) continue;
const TopoDS_Shape& gs2 = myShapeIntersector2d.CurrentGeomShape(2);
TopAbs_ShapeEnum t1 = gs1.ShapeType();
TopAbs_ShapeEnum t2 = gs2.ShapeType();
-#ifdef DEB
- TopAbs_Orientation o1 =
-#endif
- gs1.Orientation();
-#ifdef DEB
- TopAbs_Orientation o2 =
-#endif
- gs2.Orientation();
// si le couple courant apres un couple facefacesamedomain n'est
// pas un couple edgeedge ==> facefacesamedomain est deconnecte
else if ((t1 == TopAbs_EDGE) && (t2 == TopAbs_EDGE)) {
TopOpeBRep_EdgesIntersector& EE = myShapeIntersector2d.ChangeEdgesIntersector();
EE.Dimension(2);
-#ifdef DEB
- Standard_Boolean EEsamedomain =
-#endif
- EE.SameDomain();
myEdgesFiller.Face(1,lFF1);
myEdgesFiller.Face(2,lFF2);
myEdgesFiller.Insert(gs1,gs2,EE,HDS);
Standard_Boolean reducesegment = (hs && !esd);
#endif
-#ifdef DEB
- TopAbs_Orientation E1ori =
-#endif
- E1.Orientation();
-#ifdef DEB
- TopAbs_Orientation E2ori =
-#endif
- E2.Orientation();
-
// --- Add <E1,E2> in BDS
Standard_Integer E1index = myPDS->AddShape(E1,1);
Standard_Integer E2index = myPDS->AddShape(E2,2);
// --- get list of interferences connected to edges <E1>,<E2>
TopOpeBRepDS_ListOfInterference& EIL1 = myPDS->ChangeShapeInterferences(E1);
-#ifdef DEB
- TopOpeBRepDS_ListOfInterference& EIL2 =
-#endif
- myPDS->ChangeShapeInterferences(E2);
Handle(TopOpeBRepDS_Interference) EPI; //edge/point interference
Handle(TopOpeBRepDS_Interference) EVI; //edge/vertex interference
Standard_Boolean pointofsegment =
#endif
P2D.IsPointOfSegment();
-#ifdef DEB
- Standard_Boolean reducesegmentpoint = (reducesegment && pointofsegment);
-#endif
#ifdef DEB
if (trc) {
Standard_Boolean isvertex2 = P2D.IsVertex(2);
if (isvertex1 && isvertex2) {
Standard_Integer G1 = myPDS->AddShape(P2D.Vertex(1),1);
-#ifdef DEB
- Standard_Integer G2 =
-#endif
- myPDS->AddShape(P2D.Vertex(2),2);
+ myPDS->AddShape(P2D.Vertex(2),2);
G = G1;
K = TopOpeBRepDS_VERTEX;
}
Standard_Boolean TopOpeBRep_EdgesFiller::ToRecompute(const TopOpeBRep_Point2d& P2D,const Handle(TopOpeBRepDS_Interference)& I,const Standard_Integer IEmother)
{
Standard_Boolean b = Standard_True;
- const TopOpeBRepDS_Transition& T = I->Transition();
-#ifdef DEB
- TopAbs_State sb =
-#endif
- T.Before();
-#ifdef DEB
- TopAbs_State sa =
-#endif
- T.After();
Standard_Boolean pointofsegment = P2D.IsPointOfSegment();
Standard_Boolean esd = myPEI->SameDomain();
b = b && (pointofsegment && !esd);
//=======================================================================
void TopOpeBRep_EdgesIntersector::SetFaces(const TopoDS_Shape& F1,const TopoDS_Shape& F2,const Bnd_Box& B1,const Bnd_Box& B2)
{
-#ifdef DEB
- Standard_Boolean memesfaces = F1.IsSame(F2);
-#endif
Standard_Boolean computerestriction = Standard_False;
Standard_Boolean so11 = Standard_True;
{
mysp2d.Clear();
myip2d = 1; mynp2d = 0;
-#ifdef DEB
- TopAbs_Orientation E1ori =
-#endif
- E1.Orientation();
-#ifdef DEB
- TopAbs_Orientation E2ori =
-#endif
- E2.Orientation();
+
myEdge1 = TopoDS::Edge(E1);
myEdge2 = TopoDS::Edge(E2);
Standard_Real toll =
#endif
BRep_Tool::Tolerance(vl);
-#ifdef DEB
- Standard_Real tol = Max (tolf,toll);
-#endif
Standard_Boolean onf = (df < tolf);
-#ifdef DEB
- Standard_Boolean onl = (dl < toll);
-#endif
TopoDS_Vertex v1 = onf ? vf : vl;
TopTools_IndexedDataMapOfShapeListOfShape mapVE; TopExp::MapShapesAndAncestors(myFace1,TopAbs_VERTEX,TopAbs_EDGE,mapVE);
const TopTools_ListOfShape& Edsanc = mapVE.FindFromKey(v1);
Standard_Boolean T1INT = (T1.Orientation(TopAbs_IN) == TopAbs_INTERNAL);
#ifdef DEB
Standard_Boolean T1EXT = (T1.Orientation(TopAbs_IN) == TopAbs_EXTERNAL);
- Standard_Boolean INTEXT1 = T1INT || T1EXT;
#endif
if (T1INT && isvertex2 && !isvertex1) {
const TopoDS_Vertex& V2 = P2D.Vertex(2);
Standard_Boolean rr = (Abs(r1-r2) < Precision::Confusion()); //xpu281098 (cto019D2) tolerance a revoir
if (!rr) return SetSameDomain(Standard_False);
-#ifdef DEB
- const gp_Ax22d& pos1 =
-#endif
- c1.Position();
-#ifdef DEB
- const gp_Ax22d& pos2 =
-#endif
- c2.Position();
-
const gp_Pnt2d& p1 = c1.Location();
const gp_Pnt2d& p2 = c2.Location();
Standard_Boolean pospsa = psa.IsPointOfSegment();
TopOpeBRep_P2Dstatus stspsa = psa.Status();
-#ifdef DEB
- const gp_Pnt& Ppsa =
-#endif
- psa.Value();
Standard_Real tpsa1 = psa.Parameter(1);
Standard_Real tpsa2 = psa.Parameter(2);
const TopOpeBRepDS_Transition& Tpsa1 = psa.Transition(1);
Standard_Boolean pospsb = psb.IsPointOfSegment();
TopOpeBRep_P2Dstatus stspsb = psb.Status();
-#ifdef DEB
- const gp_Pnt& Ppsb =
-#endif
- psb.Value();
Standard_Real tpsb1 = psb.Parameter(1);
Standard_Real tpsb2 = psb.Parameter(2);
const TopOpeBRepDS_Transition& Tpsb1 = psb.Transition(1);
psb.SetKeep(Standard_False);
TopOpeBRepDS_Config cpsa = psa.EdgesConfig();
-#ifdef DEB
- TopOpeBRepDS_Config cpsb =
-#endif
- psb.EdgesConfig();
+
Pn.SetEdgesConfig(cpsa);
Standard_Boolean isvpsa1 = psa.IsVertex(1);if (isvpsa1) Pn.SetVertex(1,psa.Vertex(1));
for (; FEINT.MorePoint(); FEINT.NextPoint() ) {
gp_Pnt2d pUV; FEINT.UVPoint(pUV);
-#ifdef DEB
- TopAbs_State sta =
-#endif
- FEINT.State();
Standard_Real parE = FEINT.Parameter();
#ifdef DEB
Standard_Boolean isvertexF = FEINT.IsVertex(1,V1);
TopoDS_Vertex V2;
Standard_Boolean isvertexE = FEINT.IsVertex(2,V2);
- Standard_Boolean isvertex = isvertexF || isvertexE;
cout<<endl;
cout<<"P"<<ip<<" : ";
for (; VPI.More(); VPI.Next()) {
TopOpeBRep_VPointInter& VP = VPI.ChangeCurrentVP();
-#ifdef DEB
- Standard_Integer VPsi = VP.ShapeIndex();
-#endif
Standard_Boolean isvertex = VP.IsVertex(Esi);
if ( isvertex ) {
Standard_Integer iOO = myDS->AddShape(OOE,OOrank);
Standard_Real OOpar;
-#ifdef DEB
- Standard_Boolean okOO =
-#endif
- VP.ParonE(OOE,OOpar);
+ VP.ParonE(OOE,OOpar);
// xpu091198 : 1d interf done in EdgesFiller processing (cto cylcong *)
Standard_Boolean sdmeds = FUN_ds_sdm((*myDS),Erest,OOE);
TopOpeBRepDS_Curve DSC;
myDSCIndex = myDS->AddCurve(DSC);
-#ifdef DEB
- const TopOpeBRepDS_Curve& CCC = myDS->Curve(myDSCIndex);
-#endif
-
#ifdef DEB
if (TopOpeBRepDS_GettraceDSF() || TopOpeBRepDS_GettraceDSNC())
cout<<"new DSC "<<myDSCIndex<<endl;
for (InitLine(); MoreLine(); NextLine()) {
TopOpeBRep_LineInter& L = CurrentLine();
if (L.TypeLineCurve() == TopOpeBRep_RESTRICTION) {
-#ifdef DEB
- Standard_Boolean isedge1 = L.ArcIsEdge(1); //DEB
- Standard_Boolean isedge2 = L.ArcIsEdge(2); //DEB
-#endif
const TopoDS_Shape& E = L.Arc();
myEdgeRestrictionMap.Add(E);
}
Standard_ProgramError::Raise("FacesIntersector : bad SameDomain");
Standard_Boolean sd = myIntersector.TangentFaces();
-#ifdef DEB
- Standard_Boolean plpl = (mySurfaceType1 == GeomAbs_Plane) && (mySurfaceType2 == GeomAbs_Plane);
-#endif
+
+ //Standard_Boolean plpl = (mySurfaceType1 == GeomAbs_Plane) && (mySurfaceType2 == GeomAbs_Plane);
+
// if (!plpl) return Standard_False;
return sd;
}
return anRLine;
Standard_Boolean IsOnFirst = (theRank == 1);
-#ifdef DEB
- Standard_Integer ParamMinOnLine = (Standard_Integer)
-#endif
- Vtx1.ParameterOnLine();
-#ifdef DEB
- Standard_Integer ParamMaxOnLine = (Standard_Integer)
-#endif
- Vtx2.ParameterOnLine();
Handle(IntSurf_LineOn2S) aLineOn2S = new IntSurf_LineOn2S();
const Handle(IntSurf_LineOn2S)& Lori = theWLine->Curve();
Standard_Real toll =
#endif
BRep_Tool::Tolerance(vl);
-#ifdef DEB
- Standard_Real tol = Max (tolf,toll);
-#endif
Standard_Boolean onf = (df < tolf);
-#ifdef DEB
- Standard_Boolean onl = (dl < toll);
-#endif
TopoDS_Vertex v1 = onf ? vf : vl;
TopTools_IndexedDataMapOfShapeListOfShape mapVE; TopExp::MapShapesAndAncestors(F1,TopAbs_VERTEX,TopAbs_EDGE,mapVE);
const TopTools_ListOfShape& Edsanc = mapVE.FindFromKey(v1);
}
}
-#ifdef DEB
- GeomAbs_CurveType myCurveType1 = myCurve1.GetType();
- GeomAbs_CurveType myCurveType2 = myCurve2.GetType();
-#endif
-
} // SetEdges
//=======================================================================
Standard_Boolean isvertex1 = IsVertex(1); TopoDS_Vertex V1; if (isvertex1) V1 = Vertex(1);
Standard_Boolean isvertex2 = IsVertex(2); TopoDS_Vertex V2; if (isvertex2) V2 = Vertex(2);
- Standard_Boolean isvertex = isvertex1 || isvertex2;
Standard_Integer ia1,ia2; SegmentAncestors(ia1,ia2);
cout<<endl<<"p2d "<<index<<" k="<<keep<<" pos="<<pos;
// If vp(index) is an edge boundary returns the point's parameter.
const TopoDS_Edge& E = TopoDS::Edge(Lrest.Arc());
-#ifdef DEB
- Standard_Boolean isdg =
-#endif
- BRep_Tool::Degenerated(E);
Standard_Boolean isedge1 = Lrest.ArcIsEdge(1);
Standard_Boolean isedge2 = Lrest.ArcIsEdge(2);
if (isedge1 && vp.IsVertexOnS1()) {
if (isrest) {
const TopoDS_Edge& E = TopoDS::Edge(L.Arc());
-#ifdef DEB
- Standard_Boolean FIisrest =
-#endif
- myFacesIntersector->IsRestriction(E);
#ifdef DEB
if (trRL) {
(const TopOpeBRep_LineInter& L,const Standard_Boolean checkkeep) const
{
#ifdef DEB
- Standard_Boolean trc = (TopOpeBRepDS_GettraceDSF() || TopOpeBRepDS_GettraceDSNC());
+ //Standard_Boolean trc = (TopOpeBRepDS_GettraceDSF() || TopOpeBRepDS_GettraceDSNC());
#endif
TopOpeBRep_TypeLineCurve t = L.TypeLineCurve();
itLES.Next(),itLOI.Next()) {
const TopoDS_Shape& E1 = itLES.Value();
Standard_Integer rE1 = itLOI.Value();
-#ifdef DEB
- Standard_Integer iE1 =
-#endif
- myDS->AddShape(E1,rE1);
+ myDS->AddShape(E1,rE1);
}
// determination des aretes SameDomain en 3d pur
Standard_Boolean res = myIntersectionDone;
#ifdef DEB
- Standard_Integer i1 = Index(1);
- Standard_Integer i2 = Index(2);
if (TopOpeBRep_GettraceSI() && res) {
if ( myFFDone ) cout<<"FF : ";
else if ( myEEFFDone ) cout<<" EE : ";
#ifdef DEB
SAVFFi1 = myFaceScanner.Index(); SAVFFi2 = myFaceExplorer.Index();
if (TopOpeBRep_GettraceSI()) {
- Standard_Integer i1 = myFaceScanner.Index();
- Standard_Integer i2 = myFaceExplorer.Index();
cout<<"?? FF : ";
myFaceScanner.DumpCurrent(cout); myFaceExplorer.DumpCurrent(cout);
cout<<endl;
myEEIntersector.Perform(GS1,GS2);
#ifdef DEB
- Standard_Integer i1 = Index(1);
- Standard_Integer i2 = Index(2);
if (TopOpeBRep_GettraceSI() && myEEIntersector.IsEmpty()) {
cout<<" EE : ";
myEdgeScanner.DumpCurrent(cout);
Standard_Boolean res = myIntersectionDone;
#ifdef DEB
- Standard_Integer i1 = Index(1);
- Standard_Integer i2 = Index(2);
if (TopOpeBRep_GettraceSI() && res) {
if ( myFFDone ) cout<<"FF : ";
else if ( myEEFFDone ) cout<<" EE : ";
#ifdef DEB
if (TopOpeBRep_GettraceSI()) {
- Standard_Integer i1 = myFaceScanner.Index();
- Standard_Integer i2 = myFaceExplorer.Index();
cout<<"?? FF : ";
myFaceScanner.DumpCurrent(cout);
myFaceExplorer.DumpCurrent(cout);
#endif
const TopOpeBRepTool_BoxSort& BS = myFaceScanner.BoxSort();
-#ifdef DEB
- const Bnd_Box& B1 =
-#endif
- BS.Box(GS1);
-#ifdef DEB
- const Bnd_Box& B2 =
-#endif
- BS.Box(GS2);
+ BS.Box(GS1);
+ BS.Box(GS2);
myFFDone = Standard_True;
break;
NextFFCouple();
myEEIntersector.Perform(GS1,GS2);
#ifdef DEB
- Standard_Integer i1 = Index(1);
- Standard_Integer i2 = Index(2);
if (TopOpeBRep_GettraceSI() && myEEIntersector.IsEmpty()) {
cout<<" EE : ";
myEdgeScanner.DumpCurrent(cout);
return myState;
}
-#ifdef DEB
- const gp_Pnt& P3D = VP.Value();
-#endif
-
TopoDS_Face FF = TopoDS::Face(F);
TopOpeBRepTool_ShapeTool::AdjustOnPeriodic(FF,u,v);
gp_Pnt2d p2d(u,v);
Standard_ProgramError::Raise("FUNBREP_topogline_new : line is not a GLine");
return Standard_False;
}
-#ifdef DEB
- Standard_Boolean trc = TopOpeBRepDS_GettraceDSF();
-#endif
Standard_Integer iVP = VP.Index();
Standard_Integer iINON1,iINONn,nINON; L.VPBounds(iINON1,iINONn,nINON);
Standard_Real& parline,TopOpeBRepDS_Transition& transLine)
//----------------------------------------------------------------------
{
-#ifdef DEB
- Standard_Boolean trc = TopOpeBRepDS_GettraceDSF();
-#endif
-
if (L.TypeLineCurve() == TopOpeBRep_WALKING) {
Standard_ProgramError::Raise("FUNBREP_topogline : line is not a GLine");
return Standard_False;
const TopOpeBRepDS_DataStructure& BDS = HDS->DS();
if (BDS.HasShape(edge)) {
-#ifdef DEB
- Standard_Integer iedge =
-#endif
- BDS.Shape(edge);
const TopOpeBRepDS_ListOfInterference& EPIL = BDS.ShapeInterferences(edge);
TopOpeBRepDS_ListIteratorOfListOfInterference itEPIL(EPIL);
EPIfound = FF.GetGeometry(itEPIL,VP,PVIndex,PVKind);
Standard_Real tolOOe = FUN_tool_maxtol(OOedge);
Standard_Real OOtolp = Precision::Parametric(tolOOe);
if (BDS.HasShape(OOedge)) {
-#ifdef DEB
- Standard_Integer iooedge =
-#endif
- BDS.Shape(OOedge);
const TopOpeBRepDS_ListOfInterference& OOEPIL = BDS.ShapeInterferences(OOedge);
TopOpeBRepDS_ListIteratorOfListOfInterference OOitEPIL(OOEPIL);
OOEPIfound = FF.GetGeometry(OOitEPIL,VP,PVIndex,PVKind);
Standard_Boolean rest = inERL || isse;
Standard_Boolean interf2d = EtgOOF && Lonrest && rest;
Standard_Boolean interf3dtg = EtgOOF && rest && !interf2d; // xpu260898 :cto902D6,(e15,p3,f9)
-#ifdef DEB
- Standard_Boolean interf3d = !interf2d && !interf3dtg;
-#endif
Standard_Real factor = 1.e-2;
TopOpeBRepTool_makeTransition MKT;
Standard_Integer& keptVPnbr)
//-----------------------------------------------------------------------
{
-#ifdef DEB
- Standard_Boolean CPIfound = !Ifound.IsNull();
-#endif
Standard_Integer OOShapeIndex = (ShapeIndex == 1) ? 2 : 1;
TopOpeBRepDS_Transition ttransLine = transLine;
}
}//myLineINL
-#ifdef DEB
- Standard_Integer SEPI = (EPIfound) ? IEPI->Support() : 0;
-#endif
TopOpeBRepDS_Kind SKEPI; if(EPIfound) SKEPI=IEPI->SupportType();
-#ifdef DEB
- Standard_Integer SCPI = (CPIfound) ? ICPI->Support() : 0;
-#endif
TopOpeBRepDS_Kind SKCPI; if(CPIfound) SKCPI=ICPI->SupportType();
// Gfound = VP corresponds with an existing geometry of ShapeIndex
// Standard_Boolean isvertex = VP.IsVertex(ShapeIndex);
Standard_Boolean isvertex = (PVKind == TopOpeBRepDS_VERTEX);
Standard_Integer absindex = VP.ShapeIndex(); // 0,1,2,3
-#ifdef DEB
- Standard_Integer iVP =
-#endif
- VP.Index();
Standard_Boolean OOShapeIndex = (ShapeIndex == 1) ? 2 : 1;
Standard_Boolean on2edges = (absindex == 3);
Standard_Boolean hasONedge = (VP.State(OOShapeIndex) == TopAbs_ON);
Standard_Boolean hasOOedge = (on2edges) ? Standard_True : hasONedge;
TopoDS_Face Face = (*this).Face(ShapeIndex);
-#ifdef DEB
- Standard_Integer iSIFace =
-#endif
- myDS->Shape(Face);
TopoDS_Face OOFace = (*this).Face(OOShapeIndex);
Standard_Integer iOOFace = myDS->Shape(OOFace);
if (iOOFace == 0) iOOFace = myDS->AddShape(OOFace,OOShapeIndex);
const TopoDS_Edge& edge = TopoDS::Edge(VP.Edge(ShapeIndex));
if (myDS->HasShape(edge)) SIedgeIndex = myDS->Shape(edge);
else myDS->AddShape(edge,ShapeIndex);
-#ifdef DEB
- Standard_Boolean isrest =
-#endif
- myDS->IsSectionEdge(edge);
-#ifdef DEB
- Standard_Boolean closing =
-#endif
- TopOpeBRepTool_ShapeTool::Closed(edge,Face);
+
Standard_Real paredge = VP.EdgeParameter(ShapeIndex);
// dummy if !<hasOOedge>
TopoDS_Edge& OOEi, Standard_Real& paronOOEi, Standard_Boolean hasOOEi,
Standard_Boolean& isT2d)
{
-#ifdef DEB
- Standard_Boolean traceDSF = TopOpeBRepDS_GettraceDSF();
- Standard_Boolean traceDEGEN = TopOpeBRepDS_GettraceDEGEN();
- Standard_Boolean trace = traceDSF || traceDEGEN;
-#endif
OOEi.Nullify();
Standard_Boolean on3 = (VP.ShapeIndex() == 3);// <VP> is shared by edge of 1 and edge of 2.
if (isperio && uviso && !EFnull) {
// C2D prend comme origine dans F l'origine de la pcurve de EF dans F
-#ifdef DEB
- Standard_Real period = S1->IsUPeriodic() ? S1->UPeriod() : S1->IsVPeriodic() ? S1->VPeriod() : 0.;
-#endif
TopoDS_Face FFOR = F;
FFOR.Orientation(TopAbs_FORWARD);
gp_Pnt2d p1,p2; BRep_Tool::UVPoints(EF,FFOR,p1,p2);
}
if ( myHBT->HasBox(S) ) {
-#ifdef DEB
- Standard_Integer i =
-#endif
- myHBT->Index(S);
const Bnd_Box& B = myHBT->Box(S);
return B;
}
TopOpeBRepTool_CORRISO::TopOpeBRepTool_CORRISO(const TopoDS_Face& Fref)
{
myFref = Fref;
-#ifdef DEB
- Standard_Boolean closed =
-#endif
- FUN_tool_closedS(myFref,myUclosed,myUper,myVclosed,myVper);
+
+ FUN_tool_closedS(myFref,myUclosed,myUper,myVclosed,myVper);
const Handle(Geom_Surface)& SU = BRep_Tool::Surface(myFref);
myGAS = GeomAdaptor_Surface(SU);
// Standard_Real f,l,tol; Handle(Geom2d_Curve) PC = FC2D_CurveOnSurface(E,myFref,f,l,tol);
Handle(Geom2d_Curve) PC; Standard_Real f,l,tol;
Standard_Boolean hasold = FC2D_HasOldCurveOnSurface(E,myFref,PC);
-#ifdef DEB
- Standard_Boolean hasnew =
-#endif
- FC2D_HasNewCurveOnSurface(E,myFref,PC);
PC = FC2D_EditableCurveOnSurface(E,myFref,f,l,tol);
if (!hasold) FC2D_AddNewCurveOnSurface(PC,E,myFref,f,l,tol);
if (PC.IsNull()) return Standard_False;
if (fyceds.Extent() == 1) {// ivf == 3 : cto016G*
TopTools_DataMapOfOrientedShapeInteger fyeds;
-#ifdef DEB
- Standard_Boolean found =
-#endif
- EdgesWithFaultyUV(myEds,3,fyeds);
+
+ EdgesWithFaultyUV(myEds,3,fyeds);
Standard_Integer nfy = fyeds.Extent();
TopTools_DataMapIteratorOfDataMapOfOrientedShapeInteger itm(fyceds);
// <vce> (boundary of <cE>):
const TopoDS_Vertex& vce = TopoDS::Vertex(vcE(ivce));
TopTools_ListOfShape loe; isb = Connexity(vce,loe);
-#ifdef DEB
- Standard_Integer nloe =
-#endif
- loe.Extent(); // DEB
+
if (!isb) return Standard_False; // NYIRAISE
Standard_Real parvce = TopOpeBRepTool_TOOL::ParE(ivce,cE); gp_Pnt2d UVvce = TopOpeBRepTool_TOOL::UVF(parvce,cE2d);
Standard_Real xlast = onU ? myGAS.LastUParameter() : myGAS.LastVParameter(); // xlast=xfirst+xperiod
Standard_Real xperiod = onU ? myUper : myVper;
-#ifdef DEB
- Standard_Boolean inbounds=Standard_False;
-#endif
Standard_Boolean isou,isov; gp_Pnt2d o2d; gp_Dir2d d2d;
Standard_Boolean iso = TopOpeBRepTool_TOOL::UVISO(PC,isou,isov,d2d,o2d);
// <vEok> :
Standard_Boolean vEok = Standard_False;
const TopTools_ListOfShape& loe = myVEds.Find(vE);
-#ifdef DEB
- Standard_Integer nloe =
-#endif
- loe.Extent(); //DEB
+
for (TopTools_ListIteratorOfListOfShape ite(loe); ite.More(); ite.Next()) {
const TopoDS_Edge& e = TopoDS::Edge(ite.Value());
TopAbs_Orientation oe = e.Orientation();
Standard_Real tttole =
#endif
BRep_Tool::Tolerance(e);
-#ifdef DEB
- Standard_Real tttuve = Max(Tol(1,tttole),Tol(2,tttole));
-#endif
Standard_Boolean isb = myERep2d.IsBound(e);
if (!isb) {FUN_RaiseError(); return Standard_False;}
{
gp_Vec2d tt2d;
if (onU) {Standard_Real uper;
-#ifdef DEB
- Standard_Boolean ok =
-#endif
Refclosed(1,uper);
if (!uper) return Standard_False;
tt2d = gp_Vec2d(uper,0.);}
else {Standard_Real vper;
-#ifdef DEB
- Standard_Boolean ok =
-#endif
Refclosed(2,vper);
if (!vper) return Standard_False;
tt2d = gp_Vec2d(0.,vper);}
if (!isb) {
Handle(Geom2d_Curve) PC; Standard_Real f,l,tol;
Standard_Boolean hasold = FC2D_HasOldCurveOnSurface(E,myFref,PC);
-#ifdef DEB
- Standard_Boolean hasnew =
-#endif
- FC2D_HasNewCurveOnSurface(E,myFref,PC);
PC = FC2D_EditableCurveOnSurface(E,myFref,f,l,tol);
if (!hasold) FC2D_AddNewCurveOnSurface(PC,E,myFref,f,l,tol);
if (PC.IsNull()) return Standard_False;
}
if (ST == GeomAbs_Sphere) {
Standard_Real pisur2 = M_PI*.5;
-#ifdef DEB
- Standard_Real u =
-#endif
- p2d.X();
Standard_Real v = p2d.Y();
Standard_Boolean vpisur2 = (Abs(v-pisur2) < toluv);
Standard_Boolean vmoinspisur2 = (Abs(v+pisur2) < toluv);
}
else if (du < tol) {
Standard_Real vf = GS.FirstVParameter();
-#ifdef DEB
- Standard_Real vl =
-#endif
- GS.LastVParameter();
Standard_Boolean onvf = Abs(p2d.Y()-vf)<toluv;
Standard_Real x = p2d.X(); Standard_Real y = p2d.Y();
if (pcb.IsNull()) return Standard_False;
Geom2dAdaptor_Curve GC2d(pcb);
GeomAbs_CurveType typ = GC2d.GetType();
-#ifdef DEB
- Standard_Boolean isquad = Standard_False;
-#endif
+
if (typ == GeomAbs_Line) return Standard_True;
return Standard_False ;
Standard_ProgramError::Raise("HBT::Box1");
}
-#ifdef DEB
- Standard_Integer im =
-#endif
- Index(S);
const Bnd_Box& B = myIMS.FindFromKey(S);
return B;
}
TopTools_DataMapIteratorOfDataMapOfShapeListOfShape itvFine(mapvFine);
for (; itvFine.More(); itvFine.Next()){
const TopoDS_Shape& vFine = itvFine.Key();
-#ifdef DEB
- const TopTools_ListOfShape& edsvFine =
-#endif
- itvFine.Value();
Standard_Boolean vIine = mapvIine.IsBound(vFine);
if (vIine) {mapvok.Add(vFine); continue;}
Standard_Boolean vRine = mapvRine.IsBound(vFine);
TopTools_DataMapIteratorOfDataMapOfShapeListOfShape itvRine(mapvRine);
for (; itvRine.More(); itvRine.Next()){
const TopoDS_Shape& vRine = itvRine.Key();
-#ifdef DEB
- const TopTools_ListOfShape& edsvRine =
-#endif
- itvRine.Value();
Standard_Boolean vok = mapvok.Contains(vRine);
if (vok) continue;
Standard_Boolean vIine = mapvIine.IsBound(vRine);
// splitting face :
const TopoDS_Face& f = TopoDS::Face(exf.Current());
TopTools_ListOfShape lfsp; Standard_Boolean issp = TopOpeBRepTool_REGUS::SplitF(f,lfsp);
-#ifdef DEB
- Standard_Integer nf =
-#endif
- lfsp.Extent();
+
if (!issp) continue;
myFsplits.Bind(f,lfsp);
// lofc : the list of faces connexed to e in <myS>
// lof : the list of untouched faces connexed to e in <myS>
const TopTools_ListOfShape& lofc = mymapeFsstatic.Find(e);
-#ifdef DEB
- Standard_Integer nfc =
-#endif
- lofc.Extent();
+
itff.Initialize(lofc);
TopoDS_Face fref;
for (; itff.More(); itff.Next()) {
#endif
ffound.Nullify();
TopoDS_Face fref = TopoDS::Face(myf);
-#ifdef DEB
- Standard_Integer nf =
-#endif
- lof.Extent();//deb
// Give us egde <e>, and a reference face <fref> (= <myf>)
// - parameter on <e> = <pare>.
TopExp_Explorer exe(CS, TopAbs_EDGE);
for (; exe.More(); exe.Next()){
const TopoDS_Edge& ed = TopoDS::Edge(exe.Current());
-#ifdef DEB
- TopAbs_Orientation oed =
-#endif
- ed.Orientation();
Standard_Boolean isdgE = BRep_Tool::Degenerated(ed);
Standard_Boolean iscE = TopOpeBRepTool_TOOL::IsClosingE(ed,myCORRISO.S(),Fref());
for (; exv.More(); exv.Next()){
const TopoDS_Shape& vcur = exv.Current();
TopOpeBRepTool_connexity& cco = mymapvEds.ChangeFromKey(vcur);
-#ifdef DEB
- Standard_Boolean ok =
-#endif
+//#ifdef DEB
+// Standard_Boolean ok =
+//#endif
cco.RemoveItem(myed);
// if (!ok) return Standard_False; see for closing vertices
}
Standard_Real fac = 0.45678;
Standard_Real tola = Precision::Angular();
Standard_Integer iv0e1 = (iStep == 1) ? REVERSED : FORWARD;
-#ifdef DEB
- Standard_Integer iv1e1 = (iStep == 1) ? FORWARD : REVERSED;
-#endif
// initializing
TopTools_ListIteratorOfListOfShape ite(loe);
if (trc) cout<<"ang(e"<<FUN_adds(myed)<<",e"<<FUN_adds(ei)<<")="<<angi<<endl;
#endif
if (eq) {
-#ifdef DEB
- Standard_Boolean dummy=Standard_True;//DEB
-#endif
FUN_Raise();
return Standard_False;
}
myed = efound;
}
-#ifdef DEB
- TopOpeBRepTool_connexity& newco =
-#endif
- mymapvEds.ChangeFromKey(myv);
TopExp_Explorer exv(myed, TopAbs_VERTEX);
for (; exv.More(); exv.Next()){
TopOpeBRepTool_connexity& cco = mymapvEds.ChangeFromKey(exv.Current());
-#ifdef DEB
- Standard_Boolean ok =
-#endif
+//#ifdef DEB
+// Standard_Boolean ok =
+//#endif
cco.RemoveItem(myed);
// if (!ok) {FUN_Raise(); return Standard_False;} closed edges
}
// noldW = 1
// ---------
if (noldW == 1) {
-#ifdef DEB
- const TopoDS_Shape& owi =
-#endif
- itm.Key(); // DEB
const TopTools_ListOfShape& low = itm.Value();
Standard_Boolean ok = CLASSI.Classilist(low,mapWlow);
if (!ok) return Standard_False;
if (!isb1) continue;
const TopTools_ListOfShape& lw1 = mapOwNw.Find(Ow1);
-#ifdef DEB
- Standard_Integer nw1 =
-#endif
- lw1.Extent();
+
if (nOw == 1) {
// all wires of <mapWs> have been treated, except the last one
// if (nw1 == 0) mapWlow binds already (Ow1,null);
cout<<endl;}
#endif
const TopTools_ListOfShape& lw2 = mapOwNw.Find(Ow2);
-#ifdef DEB
- Standard_Integer nw2 =
-#endif
- lw2.Extent();
TopTools_ListOfShape lw1r; FUN_addOwlw(Ow1,lw1,lw1r);
TopTools_ListOfShape lw2r; FUN_addOwlw(Ow2,lw2,lw2r);
myP2Ddef = Standard_True;
TopoDS_Face F = TopoDS::Face(myRef);
F.Orientation(TopAbs_FORWARD);
-#ifdef DEB
- Standard_Real tol2d =
-#endif
- Precision::PConfusion();
Standard_Real TolClass = 1e-8;
BRepTopAdaptor_FClass2d FClass2d(F,TolClass);
myState = FClass2d.Perform(P2D);
if (isUperio) {
Standard_Real Uperiod = Surf->UPeriod();
-#ifdef DEB
- Standard_Real ubid = UFfirst;
-#endif
+
+// Standard_Real ubid = UFfirst;
+
// ElCLib::AdjustPeriodic(UFfirst,UFfirst + Uperiod,tol,ubid,u);
if (Abs(u - UFfirst-Uperiod) > tol)
u = ElCLib::InPeriod(u,UFfirst,UFfirst + Uperiod);
}
if (isVperio) {
Standard_Real Vperiod = Surf->VPeriod();
-#ifdef DEB
- Standard_Real vbid = VFfirst;
-#endif
+
+// Standard_Real vbid = VFfirst;
+
// ElCLib::AdjustPeriodic(VFfirst,VFfirst + Vperiod,tol,vbid,v);
if (Abs(v - VFfirst-Vperiod) > tol)
v = ElCLib::InPeriod(v,VFfirst,VFfirst + Vperiod);
Standard_Boolean TopOpeBRepTool_TOOL::TggeomE(const Standard_Real par, const BRepAdaptor_Curve& BC,
gp_Vec& Tg)
{
-#ifdef DEB
- GeomAbs_CurveType ct =
-#endif
- BC.GetType();
-#ifdef DEB
- Standard_Boolean apoles = (ct == GeomAbs_BezierCurve)||(ct == GeomAbs_BSplineCurve);
-#endif
+//#ifdef DEB
+// GeomAbs_CurveType ct =
+//#endif
+// BC.GetType();
+//#ifdef DEB
+// Standard_Boolean apoles = (ct == GeomAbs_BezierCurve)||(ct == GeomAbs_BSplineCurve);
+//#endif
Standard_Real f = BC.FirstParameter(), l = BC.LastParameter();
Standard_Real tolE = BC.Tolerance(); Standard_Real tolp = BC.Resolution(tolE);
// Standard_Real f,l,tol; Handle(Geom2d_Curve) PC = FC2D_CurveOnSurface(E,F,f,l,tol);
Handle(Geom2d_Curve) PC; Standard_Real f,l,tol;
Standard_Boolean hasold = FC2D_HasOldCurveOnSurface(E,F,PC);
-#ifdef DEB
- Standard_Boolean hasnew =
-#endif
- FC2D_HasNewCurveOnSurface(E,F,PC);
PC = FC2D_EditableCurveOnSurface(E,F,f,l,tol);
if (!hasold) FC2D_AddNewCurveOnSurface(PC,E,F,f,l,tol);
Bnd_Box bndf; BRepBndLib::AddClose(f,bndf);
Standard_Real f1,f2,f3,l1,l2,l3; bndf.Get(f1,f2,f3,l1,l2,l3);
gp_Vec d123(f1-l1, f2-l2, f3-l3);
-#ifdef DEB
- Standard_Real dmax =
-#endif
- d123.Dot(dir);
gp_Pnt p; FUN_tool_value(uv,f,p); p.Translate(dir.Multiplied(factor));
Standard_Real d; gp_Pnt2d uvtr;
-#ifdef DEB
- Standard_Boolean ok =
-#endif
- FUN_tool_projPonF(p,f, uvtr,d);
+ FUN_tool_projPonF(p,f, uvtr,d);
Standard_Real tolf = BRep_Tool::Tolerance(f); tolf *= 1.e2; //NYIXPUTOL
if (d > tolf) return Standard_False;
Standard_Real x = 0.45678; Standard_Real pare = (1-x)*f+x*l;
Standard_Real eps = 0.123; //NYIXPU190199
-#ifdef DEB
- Standard_Real tola = Precision::Angular()*1.e3;
-#endif
+
+ //Standard_Real tola = Precision::Angular()*1.e3;
gp_Pnt2d uv1; FUN_tool_paronEF(e,pare,f1,uv1);
gp_Dir nt1; Standard_Boolean ok1 = TopOpeBRepTool_TOOL::Nt(uv1,f1,nt1);
if (S.IsNull()) return Standard_False;
Standard_Boolean uclosed,vclosed; Standard_Real uperiod,vperiod;
-#ifdef DEB
- Standard_Boolean uvclosed =
-#endif
- FUN_tool_closedS(F,uclosed,uperiod,vclosed,vperiod);
+
+// Standard_Boolean uvclosed =
+
+ FUN_tool_closedS(F,uclosed,uperiod,vclosed,vperiod);
// Standard_Real uf,ul,vf,vl; S->Bounds(uf,ul,vf,vl);
const TopoDS_Face& F = TopoDS::Face(Sh);
Standard_Boolean uclosed,vclosed; Standard_Real uperiod,vperiod;
-#ifdef DEB
- Standard_Boolean uvclosed =
-#endif
- FUN_tool_closedS(F,uclosed,uperiod,vclosed,vperiod);
+ FUN_tool_closedS(F,uclosed,uperiod,vclosed,vperiod);
Standard_Real tolp = 1.e-6;
if (uclosed) {
TopExp_Explorer e(F,TopAbs_EDGE);
for (;e.More();e.Next()) {
const TopoDS_Shape& EF = e.Current();
-#ifdef DEB
- Standard_Boolean b = EF.IsSame(E);
-#endif
if (EF.IsSame(E)) {
oriEinF=EF.Orientation();
break;
Standard_Boolean hasedge = FUN_tool_maxtol(ff,TopAbs_EDGE,maxtol);
if (hasedge) {
TopExp_Explorer exe(S,TopAbs_FACE);
- for (; exe.More(); exe.Next()){
+ for (; exe.More(); exe.Next())
+ {
const TopoDS_Shape& ee = exe.Current();
-#ifdef DEB
- Standard_Boolean hasvertex =
-#endif
- FUN_tool_maxtol(ee,TopAbs_VERTEX,maxtol);
+ FUN_tool_maxtol(ee,TopAbs_VERTEX,maxtol);
}
}
}
Standard_Boolean hasedge = FUN_tool_maxtol(S,TopAbs_EDGE,maxtol);
if (hasedge) {
TopExp_Explorer exe(S,TopAbs_FACE);
- for (; exe.More(); exe.Next()){
- const TopoDS_Shape& ee = exe.Current();
-#ifdef DEB
- Standard_Boolean hasvertex =
-#endif
- FUN_tool_maxtol(ee,TopAbs_VERTEX,maxtol);
+ for (; exe.More(); exe.Next())
+ {
+ const TopoDS_Shape& ee = exe.Current();
+ FUN_tool_maxtol(ee,TopAbs_VERTEX,maxtol);
}
}
if (!hasedge) {
-#ifdef DEB
- Standard_Boolean hasvertex =
-#endif
- FUN_tool_maxtol(S,TopAbs_VERTEX,maxtol);
+ FUN_tool_maxtol(S,TopAbs_VERTEX,maxtol);
}
}
return maxtol;
if (clo) {
Standard_Boolean isou,isov; gp_Pnt2d o2d; gp_Dir2d d2d;
Standard_Real f,l,tol; Handle(Geom2d_Curve) PC = FC2D_CurveOnSurface(E,F,f,l,tol);
-#ifdef DEB
- Standard_Boolean isouv =
-#endif
- TopOpeBRepTool_TOOL::UVISO(PC,isou,isov,d2d,o2d);
+ TopOpeBRepTool_TOOL::UVISO(PC,isou,isov,d2d,o2d);
if (UISO && isou) {
Eclo=E;
return Standard_True;
// Standard_Real f,l,tolpc; Standard_Boolean trim3d = Standard_True;
// Handle(Geom2d_Curve) PC = FC2D_CurveOnSurface(E,F,f,l,tolpc,trim3d);
Standard_Real f,l,tol; Handle(Geom2d_Curve) PC;
-#ifdef DEB
- Standard_Boolean hasold =
-#endif
- FC2D_HasOldCurveOnSurface(E,FFOR,PC);
-#ifdef DEB
- Standard_Boolean hasnew =
-#endif
- FC2D_HasNewCurveOnSurface(E,FFOR,PC);
PC = FC2D_EditableCurveOnSurface(E,FFOR,f,l,tol);
Standard_Boolean isoU,isoV; gp_Pnt2d o2d; gp_Dir2d d2d;
-#ifdef DEB
- Standard_Boolean ISO =
-#endif
- TopOpeBRepTool_TOOL::UVISO(PC,isoU,isoV,d2d,o2d);
+ TopOpeBRepTool_TOOL::UVISO(PC,isoU,isoV,d2d,o2d);
Standard_Boolean xiso = (inU && isoU)||((!inU) && isoV);
if (!xiso) return Standard_False;
Standard_Real par = dx*f + (1-dx)*l; gp_Vec2d dxx;
-#ifdef DEB
- Standard_Boolean ok =
-#endif
- FUN_tool_getdxx(FFOR,E,par,dxx);
+
+ FUN_tool_getdxx(FFOR,E,par,dxx);
TopExp_Explorer ex(FFOR, TopAbs_EDGE);
for (; ex.More(); ex.Next()){
// Standard_Real f1,l1; Handle(Geom2d_Curve) PC1 = BRep_Tool::CurveOnSurface(e1,F,f1,l1);
Standard_Real f1,l1,tol1; Handle(Geom2d_Curve) PC1;
-#ifdef DEB
- Standard_Boolean hasold1 =
-#endif
- FC2D_HasOldCurveOnSurface(e1,FFOR,PC1);
-#ifdef DEB
- Standard_Boolean hasnew1 =
-#endif
- FC2D_HasNewCurveOnSurface(e1,FFOR,PC1);
PC1 = FC2D_EditableCurveOnSurface(e1,FFOR,f1,l1,tol1);
Standard_Boolean isoU1,isoV1; gp_Pnt2d o2d1; gp_Dir2d d2d1;
-#ifdef DEB
- Standard_Boolean ISO1 =
-#endif
- TopOpeBRepTool_TOOL::UVISO(PC1,isoU1,isoV1,d2d1,o2d1);
+ TopOpeBRepTool_TOOL::UVISO(PC1,isoU1,isoV1,d2d1,o2d1);
// 2d(e1,FFOR) and 2d(E,FFOR) describe the same side of matter
Standard_Real par1 = dx*f1 + (1-dx)*l1; gp_Vec2d dxx1;
-#ifdef DEB
- Standard_Boolean ok1 =
-#endif
- FUN_tool_getdxx(FFOR,e1,par1,dxx1);
+ FUN_tool_getdxx(FFOR,e1,par1,dxx1);
Standard_Real dot = dxx.Dot(dxx1);
if (dot < 0.) continue;
// all subshapes of INTERNAL(EXTERNAL) are oriented INTERNAL(EXTERNAL)
TopTools_ListOfShape lINT; lINT.Assign(theItems.Value(INTERNAL));
-#ifdef DEB
- Standard_Integer n1 =
-#endif
- lINT.Extent();
TopTools_ListIteratorOfListOfShape it1(lINT);
while (it1.More()) {
const TopoDS_Shape& item1 = it1.Value();
}
TopTools_ListOfShape lEXT; lEXT.Assign(theItems.Value(EXTERNAL));
-#ifdef DEB
- Standard_Integer n2 =
-#endif
- lEXT.Extent();
TopTools_ListIteratorOfListOfShape it2(lEXT);
while (it2.More()) {
const TopoDS_Shape& item2 = it2.Value();
if (!ok) continue;
Standard_Real parei;
-#ifdef DEB
- Standard_Boolean oki =
-#endif
- TopOpeBRepTool_TOOL::ParISO(myuvi,ei,myFi, parei);
+ TopOpeBRepTool_TOOL::ParISO(myuvi,ei,myFi, parei);
myEpari.Bind(ei,parei);
lEi.Append(ei);
}
Standard_Real x1 = 24, y1 = 24;
Standard_Integer numberOfColumn = 1, numberOfRows = 1;
- Quantity_PlaneAngle anAngle = 0.0;
- Quantity_Factor aScale = 1.0;
if( argc >= 3 )
x1 = atof( argv[2] );
double text_scale = 15;
double length = 0;
- int distance_type = 0;
- double arrow_angle = 24;
- double arrow_length = 24;
- int arrow_type = 2;
- int arrow_side = 3;
+ //int distance_type = 0;
+ //double arrow_angle = 24;
+ //double arrow_length = 24;
+ //int arrow_type = 2;
+ //int arrow_side = 3;
double distance = FirstPt.Distance(LastPt);
gp_Pnt2d anAp2(240, 240);
gp_Circ2d aCirc(gp_Ax2d(anAp2,gp_Dir2d(0,1)),100.);
- Quantity_Length aRadius = 100;
TCollection_ExtendedString aText("Rad = 10%");
Handle(Prs2d_Radius) theRadius;
gp_Pnt2d anAp2(240, 240);
gp_Circ2d aCirc(gp_Ax2d(anAp2,gp_Dir2d(0,1)),100.);
- Quantity_Length aRadius = 100;
TCollection_ExtendedString aText("Rad = 10%");
Handle(AIS2D_InteractiveObject) aIO = new AIS2D_InteractiveObject();
Handle(AIS_InteractiveObject) aisPickedShape =
Handle(AIS_InteractiveObject)::DownCast(aContext->DetectedInteractive());
ret = aisPickedShape;
-#ifdef DEB
- const char *name =
-#endif
- ( GetMapOfAIS().IsBound1(aisPickedShape) )?
- GetMapOfAIS().Find1(aisPickedShape).ToCString() :
- (char *) "????";
}
}
return ret;
}
Standard_Boolean IsBound = GetMapOfAIS().IsBound2(shapeName);
- Standard_Boolean IsDatum = Standard_False;
Handle(Standard_Transient) anObj;
if ( IsBound ) {
anObj = GetMapOfAIS().Find2(shapeName);
/////////////////////
TopoDS_Shape aShape = DBRep::Get(a[1]);
aContext2D->EraseAll(Standard_True);
- Standard_Integer aPolyAlgo = 0;
+ //Standard_Integer aPolyAlgo = 0;
Standard_Boolean IsPoly = Standard_False;
gp_Ax2 anAx2 = gp::XOY();
/////////////////////
TopoDS_Shape aShape = DBRep::Get(a[1]);
aContext2D->EraseAll(Standard_True);
- Standard_Integer aPolyAlgo = 0;
+ //Standard_Integer aPolyAlgo = 0;
Standard_Boolean IsPoly = Standard_True;
gp_Ax2 anAx2 = gp::XOY();
if (narg<5) return 1;
Standard_Integer NbToPick = (narg -4)/2;
-#ifdef DEB
- Standard_Boolean autonaming = !strcasecmp(a[3],".");
-#endif
Handle(TopTools_HArray1OfShape) arr = new TopTools_HArray1OfShape(1,NbToPick);
if(ViewerTest::PickShapes(TopAbs_EDGE,arr)){
for(Standard_Integer i=1;i<=NbToPick;i++){
//
// Destroy all defined views
//
-#ifdef DEB
- Standard_Integer Length = MyDefinedView.Extent ();
-#else
- MyDefinedView.Extent ();
-#endif
#ifdef DESTROY
cout << "The Manager " << MyId << " have " << Length << " defined views\n";
//
// Change structure priority in all defined views
//
-#ifdef DEB
- Standard_Integer Length = MyDefinedView.Extent ();
-#else
- MyDefinedView.Extent ();
-#endif
Visual3d_SetIteratorOfSetOfView MyIterator(MyDefinedView);
while (MyIterator.More ()) {
#endif
Standard_Integer ViewId = theView->Identification ();
- Standard_Integer indexD = 0;
-
// Even if physically the structure cannot
// be displayed (pb of visualisation type)
// it has status Displayed.
void Visual3d_ViewManager::Clear (const Handle(Graphic3d_Structure)& AStructure, const Standard_Boolean WithDestruction) {
-#ifdef DEB
- Standard_Integer Length = MyDefinedView.Extent ();
-#else
- MyDefinedView.Extent ();
-#endif
Visual3d_SetIteratorOfSetOfView MyIterator(MyDefinedView);
while (MyIterator.More ()) {
void Visual3d_ViewManager::Connect (const Handle(Graphic3d_Structure)& AMother, const Handle(Graphic3d_Structure)& ADaughter) {
-#ifdef DEB
- Standard_Integer Length = MyDefinedView.Extent ();
-#else
- MyDefinedView.Extent ();
-#endif
Visual3d_SetIteratorOfSetOfView MyIterator(MyDefinedView);
while (MyIterator.More ()) {
void Visual3d_ViewManager::Disconnect (const Handle(Graphic3d_Structure)& AMother, const Handle(Graphic3d_Structure)& ADaughter) {
-#ifdef DEB
- Standard_Integer Length = MyDefinedView.Extent ();
-#else
- MyDefinedView.Extent ();
-#endif
Visual3d_SetIteratorOfSetOfView MyIterator(MyDefinedView);
while (MyIterator.More ()) {
//
// Erase structure in all defined views
//
-#ifdef DEB
- Standard_Integer Length = MyDefinedView.Extent ();
-#else
- MyDefinedView.Extent ();
-#endif
Visual3d_SetIteratorOfSetOfView MyIterator(MyDefinedView);
while (MyIterator.More ()) {
//
// Highlight in all activated views
//
-#ifdef DEB
- Standard_Integer Length = MyDefinedView.Extent ();
-#else
- MyDefinedView.Extent ();
-#endif
Visual3d_SetIteratorOfSetOfView MyIterator(MyDefinedView);
while (MyIterator.More ()) {
void Visual3d_ViewManager::SetTransform (const Handle(Graphic3d_Structure)& AStructure, const TColStd_Array2OfReal& ATrsf) {
-#ifdef DEB
- Standard_Integer Length = MyDefinedView.Extent ();
-#else
- MyDefinedView.Extent ();
-#endif
Visual3d_SetIteratorOfSetOfView MyIterator(MyDefinedView);
while (MyIterator.More ()) {
//
// UnHighlight in all activated views
//
-#ifdef DEB
- Standard_Integer Length = MyDefinedView.Extent ();
-#else
- MyDefinedView.Extent ();
-#endif
Visual3d_SetIteratorOfSetOfView MyIterator(MyDefinedView);
while (MyIterator.More ()) {
Handle (Visual3d_HSetOfView) SG = new Visual3d_HSetOfView ();
-#ifdef DEB
- Standard_Integer Length = MyDefinedView.Extent ();
-#else
- MyDefinedView.Extent ();
-#endif
Visual3d_SetIteratorOfSetOfView MyIterator(MyDefinedView);
while (MyIterator.More ()) {
Standard_Real APT;
Visual3d_SetIteratorOfSetOfView MyIterator(MyDefinedView);
-#ifdef DEB
- Standard_Integer Length = MyDefinedView.Extent ();
-#else
- MyDefinedView.Extent ();
-#endif
Standard_Integer stop = 0;
//
Visual3d_SetIteratorOfSetOfView MyIterator(MyDefinedView);
-#ifdef DEB
- Standard_Integer Length = MyDefinedView.Extent ();
-#else
- MyDefinedView.Extent ();
-#endif
-
while (MyIterator.More ()) {
if (! (MyIterator.Value ())->IsActive ())
(MyIterator.Value ())->Activate ();
//
// Deactivates all activated views
//
-#ifdef DEB
- Standard_Integer Length = MyDefinedView.Extent ();
-#else
- MyDefinedView.Extent ();
-#endif
Visual3d_SetIteratorOfSetOfView MyIterator(MyDefinedView);
while (MyIterator.More ()) {
VrmlData_ErrorStatus aStatus;
Handle(VrmlData_Node) aNode;
TCollection_AsciiString aName;
- Standard_Boolean isReused (Standard_False);
// Read the DEF token to assign the node name
if (VrmlData_Node::OK(aStatus, ReadLine(theBuffer)))
void WNT_ArcNote :: Play ( BOOL fDummy )
{
Xform ();
- HDC hdc = ALLOCATOR -> myHDC;
SetArcDirection ( ALLOCATOR -> myHDC, myDirect );
Arc ( ALLOCATOR -> myHDC, myTX - myTXr, myTY - myTYr,
myTX + myTXr, myTY + myTYr,
void WNT_TextNote :: Xform ( void )
{
- HDC hdc = ALLOCATOR -> myHDC;
WNT_PointNote :: Xform ();
RMatrix.eDx = float ( myTX );
RMatrix.eDy = float ( myTY );
{
int i;
char* p;
- BOOL fUseDefault = FALSE;
char* fName = new char[ strlen ( aFontName ) + 1 ];
) {
PW32_Allocator aNew = NULL;
- Aspect_TypeOfDrawMode DrawMode = Aspect_TODM_REPLACE;
MyDrawMode = aDrawMode;
aNew = _FindAllocator ( myAllocators, aRetainBuffer );
TColStd_Array1OfReal anArrMass(1,comp.Length());
anArrMass.Init(0.0);
Standard_Real aTotalMass =0.0;
- Standard_Boolean isFind = Standard_True;
Standard_Integer k=1;
for ( ; k <= comp.Length(); k++ ) {
TDF_Label lab = comp(k);
di << "use: storevrml shape file defl type_of_conversion (0, 1, 2)" << "\n";
}
else {
- TopAbs_ShapeEnum Types[3] = {TopAbs_FACE, TopAbs_WIRE, TopAbs_EDGE};
TopoDS_Shape shape = DBRep::Get(argv[1]);
Standard_Real defl = atof(argv[3]);
Standard_Integer type = 1;
try {
OCC_CATCH_SIGNALS
TCollection_AsciiString anInf(anInfo,'?');
- Standard_Integer aRefCounter = anInf.Token(" ",2).IntegerValue();
+ //Standard_Integer aRefCounter = anInf.Token(" ",2).IntegerValue();
//theNewDocument->SetReferenceCounter(aRefCounter);
}
catch (Standard_Failure) {
const Handle(TDF_Attribute)& theTarget,
XmlObjMgt_RRelocationTable& ) const
{
- Standard_Integer aFirstInd, aLastInd, aValue, ind;
+ Standard_Integer aFirstInd, aLastInd, aValue;
const XmlObjMgt_Element& anElement = theSource;
// Read the FirstIndex; if the attribute is absent initialize to 1
const Handle(TDF_Attribute)& theTarget,
XmlObjMgt_RRelocationTable& ) const
{
- Standard_Integer aFirstInd, aLastInd, aValue, ind;
+ Standard_Integer aFirstInd, aLastInd, ind;
const XmlObjMgt_Element& anElement = theSource;
//DataMapOfStringInteger: Read the FirstIndex; if the attribute is absent initialize to 1
LDOM_Node aCurNode = anElement.getFirstChild()/*.getNextSibling().getNextSibling()*/;
LDOM_Element* aCurElement = (LDOM_Element*)&aCurNode;
XmlObjMgt_DOMString aValueStr;
- Standard_Integer i = aFirstInd;
while (*aCurElement != anElement.getLastChild())
{
aValueStr = XmlObjMgt::GetStringValue( *aCurElement );
const gp_XYZ& Col2,
const gp_XYZ& Col3)
{
- const Standard_Address M = (Standard_Address)&(matrix[0][0]);
Mat00 = Col1.X(); Mat10 = Col1.Y(); Mat20 = Col1.Z();
Mat01 = Col2.X(); Mat11 = Col2.Y(); Mat21 = Col2.Z();
Mat02 = Col3.X(); Mat12 = Col3.Y(); Mat22 = Col3.Z();
F.Initialize(P, Dir);
Standard_Real dy1, Hnr1, lambda, alfa=0;
-#ifdef DEB
- Standard_Integer n =
-#endif
- Dir.Length();
dy1 = Gr*Dir;
if (dy1 != 0) {
Hnr1 = Dir.Norm2();
// Standard_Boolean math_BrentMinimum::IsSolutionReached(math_Function& F) {
Standard_Boolean math_BrentMinimum::IsSolutionReached(math_Function& ) {
- Standard_Real xm = 0.5 * (a + b);
+// Standard_Real xm = 0.5 * (a + b);
// modified by NIZHNY-MKK Mon Oct 3 17:45:57 2005.BEGIN
// Standard_Real tol = XTol * fabs(x) + EPSZ;
// return fabs(x - xm) <= 2.0 * tol - 0.5 * (b - a);
void math_DoubleTab::Free()
{
- Standard_Integer RowNumber = UppR - LowR + 1;
- Standard_Integer ColNumber = UppC - LowC + 1;
-
// free the data
if(isAllocated) {
Standard_Address it = (Standard_Address)&Value(LowR,LowC);
math_FunctionSetRoot Sol(Ff,V,Tol,NbIterations);
Done = Sol.IsDone();
if (Done) {
-#ifdef DEB
- Standard_Integer Ier=F.GetStateNumber();
-#else
F.GetStateNumber();
-#endif
TheRoot = Sol.Root()(1);
TheDerivative = Sol.Derivative()(1,1);
Ok = F.Value(TheRoot,TheError);
math_FunctionSetRoot Sol(Ff,V,Tol,Aa,Bb,NbIterations);
Done = Sol.IsDone();
if (Done) {
-#ifdef DEB
- Standard_Integer Ier =F.GetStateNumber();
-#else
F.GetStateNumber();
-#endif
TheRoot = Sol.Root()(1);
TheDerivative = Sol.Derivative()(1,1);
Ok = F.Value(TheRoot,TheError);
if(n1>n2) n=n2;
for(Standard_Integer i=1;i<=n;i++) {
Standard_Real t = Sol(i)-StaticSol(i);
-#ifdef NEWSEQ
-# ifdef DEB
- Standard_Real t1=
-# endif
- Sol(i);
-# ifdef DEB
- Standard_Real t2=
-# endif
- StaticSol(i);
-#endif
if(Abs(t)>NEpsX) {
printf("\n mathFunctionRoots : i:%d/%d delta: %g",i,n,t);
}
Standard_DimensionError_Raise_if(Length() != Other.Length(), " ");
-#ifdef DEB
- Standard_Integer I = Other.FirstIndex;
-#endif
(Other.Array).Copy(Array);
return *this;
}
const Standard_Real theUpper,
const Standard_Integer theNbPnts)
{
- const Standard_Real aMinVol = Epsilon(1.);
+ //const Standard_Real aMinVol = Epsilon(1.);
const Standard_Real aPtol = 1.e-9;
myNbIterReached = 0;
if(!myIsDone) return;
- Standard_Real anAbsVal = Abs(myValue);
+ //Standard_Real anAbsVal = Abs(myValue);
myAbsolutError = myErrorReached;
Standard_Boolean IsDone;
- Standard_Integer aNGauss = theGaussP.Length();
Standard_Integer aNKronrod = theKronrodP.Length();
Standard_Real aGaussVal;
//-- F= AA*CN*CN+2*BB*CN*SN+CC*CN+DD*SN+EE;
//-- D = -2*AA*CN*SN+2*BB*(CN*CN-SN*SN)-CC*SN+DD*CN;
Standard_Real AACN = AA*CN;
-#ifdef DEB
- Standard_Real BBCN = BB*CN;
-#endif
Standard_Real BBSN = BB*SN;
F = AACN*CN + BBSN*(CN+CN) + CC*CN + DD*SN + EE;
Standard_DimensionError_Raise_if(Length() != Right.RowNumber(), "");
math_Vector Result(Right.LowerColIndex, Right.UpperColIndex);
-#ifdef DEB
- Standard_Integer Index = LowerIndex;
-#endif
for(Standard_Integer J2 = Right.LowerColIndex;
J2 <= Right.UpperColIndex; J2++) {
Array(J2) = 0.0;