From ee2f5e5ad34f3c2af34f351579f081bf9ed755f5 Mon Sep 17 00:00:00 2001 From: mpv Date: Wed, 26 Feb 2020 14:29:14 +0300 Subject: [PATCH] Skipping compsolids in the history request due to improved behavior of BOPs in the OCCT 7.4.0. --- src/Model/Model_BodyBuilder.cpp | 3 ++- src/Model/Model_ResultBody.cpp | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Model/Model_BodyBuilder.cpp b/src/Model/Model_BodyBuilder.cpp index 2c5c5c381..fd85d452a 100644 --- a/src/Model/Model_BodyBuilder.cpp +++ b/src/Model/Model_BodyBuilder.cpp @@ -365,7 +365,8 @@ void Model_BodyBuilder::storeModified(const std::list& theOldShape std::list::const_iterator anOldIter = theOldShapes.cbegin(); for(; anOldIter != theOldShapes.cend(); anOldIter++) { // compounds may cause crash if call "modified" - bool aStore = (*anOldIter)->isCompound() || (*anOldIter)->isShell() || (*anOldIter)->isWire(); + bool aStore = (*anOldIter)->isCompound() || (*anOldIter)->isShell() || (*anOldIter)->isWire() || + (*anOldIter)->isCompSolid(); if (!aStore) { ListOfShape aNews; // check this old really modifies theNewShape theMakeShape->modified(*anOldIter, aNews); diff --git a/src/Model/Model_ResultBody.cpp b/src/Model/Model_ResultBody.cpp index 4d1991738..62b47c7cb 100644 --- a/src/Model/Model_ResultBody.cpp +++ b/src/Model/Model_ResultBody.cpp @@ -408,7 +408,7 @@ void Model_ResultBody::computeOldForSub(const GeomShapePtr& theSub, for (TopTools_MapOfShape::Iterator anOldIter(anOldSubs); anOldIter.More(); anOldIter.Next()) { TopoDS_Shape anOldShape = anOldIter.Value(); if (anOldShape.ShapeType() == TopAbs_COMPOUND || anOldShape.ShapeType() == TopAbs_SHELL || - anOldShape.ShapeType() == TopAbs_WIRE) + anOldShape.ShapeType() == TopAbs_WIRE || anOldShape.ShapeType() == TopAbs_COMPSOLID) continue; // container old-shapes are not supported by the history, may cause crash GeomShapePtr anOldSub(new GeomAPI_Shape); anOldSub->setImpl(new TopoDS_Shape(anOldShape)); -- 2.39.2