Fix part/section handling of Face OuterWire

This commit is contained in:
WandererFan 2016-09-01 11:37:54 -04:00
parent b75f82b500
commit 7e04c17bdd
2 changed files with 2 additions and 9 deletions

View File

@ -363,13 +363,9 @@ void DrawViewPart::extractFaces()
EdgeWalker ew;
ew.loadEdges(faceEdges);
ew.perform();
std::vector<TopoDS_Wire> fw = ew.getResultWires();
//TODO: we should remove duplicates here in case of islands?
// but for non-mosaic's we should keep 1 copy of the outerWire
// if we remove duplicates after sortstrip, then the outerWire won't be a duplicate
// still ok as long as we draw biggest first?
std::vector<TopoDS_Wire> fw = ew.getResultNoDups();
std::vector<TopoDS_Wire> sortedWires = ew.sortStrip(fw,false); //false==>do not include OuterWire
std::vector<TopoDS_Wire> sortedWires = ew.sortStrip(fw,true);
std::vector<TopoDS_Wire>::iterator itWire = sortedWires.begin();
for (; itWire != sortedWires.end(); itWire++) {

View File

@ -389,9 +389,6 @@ TopoDS_Face DrawViewSection::projectFace(const TopoDS_Shape &face,
if (sortedWires.empty()) {
return projectedFace;
}
//TODO: should have the same size checking logic as DVP?
//remove the largest wire (OuterWire of graph) ??? but duplicates have been removed? only do this if a mosaic?
//sortedWires.erase(sortedWires.begin());
BRepBuilderAPI_MakeFace mkFace(sortedWires.front(),true); //true => only want planes?
std::vector<TopoDS_Wire>::iterator itWire = ++sortedWires.begin(); //starting with second face