From 782e329d921c63ca8bf54375c69139444d6147f9 Mon Sep 17 00:00:00 2001 From: mbs Date: Mon, 27 Feb 2023 16:41:06 +0000 Subject: [PATCH] fixed problem where only the first solid was imported from STEP --- src/GeomAlgoAPI/GeomAlgoAPI_STEPImportXCAF.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/GeomAlgoAPI/GeomAlgoAPI_STEPImportXCAF.cpp b/src/GeomAlgoAPI/GeomAlgoAPI_STEPImportXCAF.cpp index 3daecc1b6..b6b233236 100644 --- a/src/GeomAlgoAPI/GeomAlgoAPI_STEPImportXCAF.cpp +++ b/src/GeomAlgoAPI/GeomAlgoAPI_STEPImportXCAF.cpp @@ -166,7 +166,7 @@ std::shared_ptr setGeom(const Handle(XCAFDoc_ShapeTool) &theShape aGeomShape->setImpl(new TopoDS_Shape(shape)); return aGeomShape; } else { - for (Standard_Integer i=1; iGetShape(aFrshapes.Value(i)); TDF_Label aLabel = theShapeTool->FindShape(aS, Standard_False); if ( (!aLabel.IsNull()) && (theShapeTool->IsShape(aLabel)) ) { @@ -174,7 +174,7 @@ std::shared_ptr setGeom(const Handle(XCAFDoc_ShapeTool) &theShape if (aS.IsNull()) { continue; } else { - if (!theShapeTool->IsReference(aLabel) ){ + if (aS.ShapeType() != TopAbs_SOLID && !theShapeTool->IsReference(aLabel)){ for(TDF_ChildIterator anIt(aLabel); anIt.More(); anIt.Next()) { aB.Add(aCompound, theShapeTool->GetShape(anIt.Value()) ); } -- 2.30.2