mirror of
https://github.com/NGSolve/netgen.git
synced 2024-12-26 22:00:33 +05:00
little stl cleanup
This commit is contained in:
parent
0c4b90c4c4
commit
54fa0d81ec
@ -691,11 +691,6 @@ void STLChart :: AddOuterTrig(STLTrigId i)
|
|||||||
|
|
||||||
bool STLChart :: IsInWholeChart(int nr) const
|
bool STLChart :: IsInWholeChart(int nr) const
|
||||||
{
|
{
|
||||||
// for (int i = 1; i <= charttrigs.Size(); i++)
|
|
||||||
// if (charttrigs.Get(i) == nr) return true;
|
|
||||||
// for (int i = 1; i <= outertrigs.Size(); i++)
|
|
||||||
// if (outertrigs.Get(i) == nr) return true;
|
|
||||||
// return false;
|
|
||||||
return charttrigs.Contains(nr) || outertrigs.Contains(nr);
|
return charttrigs.Contains(nr) || outertrigs.Contains(nr);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1014,30 +1009,10 @@ void STLBoundary ::AddTriangle(const STLTriangle & t)
|
|||||||
|
|
||||||
INDEX_2 op(seg[1], seg[0]);
|
INDEX_2 op(seg[1], seg[0]);
|
||||||
if (boundary_ht.Used(op))
|
if (boundary_ht.Used(op))
|
||||||
{
|
|
||||||
// cout << "delete " << op << endl;
|
|
||||||
boundary_ht.Delete(op);
|
boundary_ht.Delete(op);
|
||||||
}
|
|
||||||
else
|
else
|
||||||
{
|
|
||||||
// cout << "insert " << seg << endl;
|
|
||||||
boundary_ht[seg] = bseg;
|
boundary_ht[seg] = bseg;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
/*
|
|
||||||
// cout << "bounds = " << boundary << endl;
|
|
||||||
cout << "bounds:";
|
|
||||||
for (auto & val : boundary)
|
|
||||||
cout << val.I1() << "-" << val.I2() << endl;
|
|
||||||
cout << "ht = " << boundary_ht << endl;
|
|
||||||
if (boundary_ht.UsedElements() != boundary.Size())
|
|
||||||
{
|
|
||||||
cout << "wrong count" << endl;
|
|
||||||
char key;
|
|
||||||
cin >> key;
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
// NgProfiler::StopTimer (timer_new);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bool STLBoundary :: TestSeg(const Point<3>& p1, const Point<3> & p2, const Vec<3> & sn,
|
bool STLBoundary :: TestSeg(const Point<3>& p1, const Point<3> & p2, const Vec<3> & sn,
|
||||||
|
@ -140,11 +140,10 @@ class STLBoundarySeg
|
|||||||
Point<3> p1, p2, center;
|
Point<3> p1, p2, center;
|
||||||
Point<2> p2d1, p2d2;
|
Point<2> p2d1, p2d2;
|
||||||
Box<2> boundingbox;
|
Box<2> boundingbox;
|
||||||
// Point<2> p2dmin, p2dmax;
|
|
||||||
|
|
||||||
double rad;
|
double rad;
|
||||||
STLPointId i1, i2;
|
STLPointId i1, i2;
|
||||||
int smoothedge;
|
bool smoothedge;
|
||||||
public:
|
public:
|
||||||
STLBoundarySeg () { ; }
|
STLBoundarySeg () { ; }
|
||||||
STLBoundarySeg (STLPointId ai1, STLPointId ai2, const Array<Point<3>,STLPointId> & points,
|
STLBoundarySeg (STLPointId ai1, STLPointId ai2, const Array<Point<3>,STLPointId> & points,
|
||||||
@ -177,8 +176,8 @@ public:
|
|||||||
const Box<2> & BoundingBox() const { return boundingbox; }
|
const Box<2> & BoundingBox() const { return boundingbox; }
|
||||||
double Radius () const { return rad; }
|
double Radius () const { return rad; }
|
||||||
|
|
||||||
void SetSmoothEdge (int se) { smoothedge = se; }
|
void SetSmoothEdge (bool se) { smoothedge = se; }
|
||||||
int IsSmoothEdge () const { return smoothedge; }
|
bool IsSmoothEdge () const { return smoothedge; }
|
||||||
friend class STLBoundary;
|
friend class STLBoundary;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user