From b83ae00530d9def410adb46075f2b034a839e7c4 Mon Sep 17 00:00:00 2001 From: azv Date: Thu, 27 Sep 2018 13:36:08 +0300 Subject: [PATCH] Issue #2611: Partition of a solid belonging to a Compsolid Fix failure in Partition if full compsolid is selected (do not place all its sub-solids to the list of unused shapes) --- src/FeaturesPlugin/FeaturesPlugin_Partition.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/FeaturesPlugin/FeaturesPlugin_Partition.cpp b/src/FeaturesPlugin/FeaturesPlugin_Partition.cpp index 92658389c..3ef472216 100755 --- a/src/FeaturesPlugin/FeaturesPlugin_Partition.cpp +++ b/src/FeaturesPlugin/FeaturesPlugin_Partition.cpp @@ -343,6 +343,11 @@ void unusedSubsOfComposolid(const CompsolidSubs& theObjects, CompsolidSubs& theN if (aCSIt->first->shapeType() != GeomAPI_Shape::COMPSOLID) continue; + // check the compsolid is selected + if (aCSIt->second.size() == 1 && aCSIt->first->isEqual(aCSIt->second.front())) + continue; + + // process all sub-solids of compsolid ListOfShape aNotUsedSolids; for (GeomAPI_ShapeExplorer anExp(aCSIt->first, GeomAPI_Shape::SOLID); anExp.more(); anExp.next()) { -- 2.39.2