#include <GeomAlgoAPI_PaveFiller.h>
#include <GeomAlgoAPI_ShapeTools.h>
-#include <GeomAPI_ShapeExplorer.h>
+#include <GeomAPI_ShapeIterator.h>
#include <map>
for(; aBoolObjIt != aBooleanObjects.cend() && aBoolMSIt != aBooleanMakeShapes.cend();
++aBoolObjIt, ++aBoolMSIt) {
- int aTag = 1;
-
ResultBodyPtr aResultBody = myFeature->document()->createBody(myFeature->data(), aResultIndex);
if((*aBoolObjIt)->isEqual((*aBoolMSIt)->shape())) {
{
aResultBody->storeModified(*aBoolObjIt, (*aBoolMSIt)->shape());
- aTag += 5000;
-
// Store generation history.
ListOfShape::const_iterator aGenBaseIt = aGenBaseShapes.cbegin();
ListOfMakeShape::const_iterator aGenMSIt = aGenMakeShapes.cbegin();
for(; aGenBaseIt != aGenBaseShapes.cend() && aGenMSIt != aGenMakeShapes.cend();
++aGenBaseIt, ++aGenMSIt) {
- storeGenerationHistory(aResultBody, *aGenBaseIt, *aGenMSIt);
+ std::shared_ptr<GeomAlgoAPI_MakeShapeList> aMSList(new GeomAlgoAPI_MakeShapeList());
+ aMSList->appendAlgo(*aGenMSIt);
+ aMSList->appendAlgo(*aBoolMSIt);
+ storeGenerationHistory(aResultBody, *aGenBaseIt, aMSList);
}
storeModificationHistory(aResultBody, *aBoolObjIt, aTools, *aBoolMSIt);
// Collecting solids from compsolids which will not be modified in boolean operation.
ListOfShape aShapesToAdd;
- for(GeomAPI_ShapeExplorer
- anExp(aCompSolid, GeomAPI_Shape::SOLID); anExp.more(); anExp.next()) {
- GeomShapePtr aSolidInCompSolid = anExp.current();
+ for (GeomAPI_ShapeIterator aCompSolidIt(aCompSolid);
+ aCompSolidIt.more();
+ aCompSolidIt.next())
+ {
+ GeomShapePtr aSolidInCompSolid = aCompSolidIt.current();
ListOfShape::const_iterator aUsedShapesIt = aUsedShapes.cbegin();
for(; aUsedShapesIt != aUsedShapes.cend(); ++aUsedShapesIt) {
if(aSolidInCompSolid->isEqual(*aUsedShapesIt)) {
aSolidsToFuse.insert(aSolidsToFuse.end(), aUsedShapes.begin(), aUsedShapes.end());
// Collect solids from compsolid which will not be modified in boolean operation.
- for(GeomAPI_ShapeExplorer
- anExp(aCompSolid, GeomAPI_Shape::SOLID); anExp.more(); anExp.next()) {
- GeomShapePtr aSolidInCompSolid = anExp.current();
+ for (GeomAPI_ShapeIterator aCompSolidIt(aCompSolid);
+ aCompSolidIt.more();
+ aCompSolidIt.next())
+ {
+ GeomShapePtr aSolidInCompSolid = aCompSolidIt.current();
ListOfShape::iterator anIt = aUsedShapes.begin();
for(; anIt != aUsedShapes.end(); anIt++) {
if(aSolidInCompSolid->isEqual(*anIt)) {
ListOfShape aTools = theTools;
aTools.push_back(theObject);
- std::string aName;
for(ListOfShape::const_iterator anIt = aTools.begin(); anIt != aTools.end(); anIt++) {
theResultBody->loadModifiedShapes(theMakeShape, *anIt,
(*anIt)->shapeType() == GeomAPI_Shape::EDGE ?