if (ProjectPointToCurve(aEndPs[aPI], theCurve1, aParameter) <=
Precision::SquareConfusion())
{
if (ProjectPointToCurve(aEndPs[aPI], theCurve1, aParameter) <=
Precision::SquareConfusion())
{
aIntCount += AddParameter(theCurve1, aParameter, theParameters);
}
}
// Process the internal extremums.
aIntCount += AddParameter(theCurve1, aParameter, theParameters);
}
}
// Process the internal extremums.
{
Extrema_POnCurv aP1, aP2;
aAlgo.Points(aEN, aP1, aP2);
{
Extrema_POnCurv aP1, aP2;
aAlgo.Points(aEN, aP1, aP2);
TopExp::MapShapesAndAncestors(theWire,
TopAbs_VERTEX, TopAbs_EDGE, aVertexToEdges);
const int aVCount = aVertexToEdges.Extent();
TopExp::MapShapesAndAncestors(theWire,
TopAbs_VERTEX, TopAbs_EDGE, aVertexToEdges);
const int aVCount = aVertexToEdges.Extent();
const TopoDS_Wire& theWire,
std::deque<std::list<double> >& theParameters) const
{
const TopoDS_Wire& theWire,
std::deque<std::list<double> >& theParameters) const
{
- //std::string brepName = "theWireToIntersect";
- //brepName += ".brep";
- //BRepTools::Write( theWire, brepName.c_str() );
+ std::string brepName = "theWireToIntersect";
+ brepName += ".brep";
+ BRepTools::Write( theWire, brepName.c_str() );
std::list<TopoDS_Edge>::const_iterator aEIt = myEdges.begin();
std::list<TopoDS_Edge>::const_iterator aLastEIt = myEdges.end();
std::deque<std::list<double> >::iterator aPIt = theParameters.begin();
for (; aEIt != aLastEIt; ++aPIt, ++aEIt)
{
std::list<TopoDS_Edge>::const_iterator aEIt = myEdges.begin();
std::list<TopoDS_Edge>::const_iterator aLastEIt = myEdges.end();
std::deque<std::list<double> >::iterator aPIt = theParameters.begin();
for (; aEIt != aLastEIt; ++aPIt, ++aEIt)
{
const TopoDS_Edge& aEdge = *aEIt;
std::list<double>& aParams = *aPIt;
TopExp_Explorer aEIt2(theWire, TopAbs_EDGE);
for (; aEIt2.More(); aEIt2.Next())
{
aIntCount += IntersectEdge(aEdge,TopoDS::Edge(aEIt2.Current()), aParams);
const TopoDS_Edge& aEdge = *aEIt;
std::list<double>& aParams = *aPIt;
TopExp_Explorer aEIt2(theWire, TopAbs_EDGE);
for (; aEIt2.More(); aEIt2.Next())
{
aIntCount += IntersectEdge(aEdge,TopoDS::Edge(aEIt2.Current()), aParams);