X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FGeomAlgoAPI%2FGeomAlgoAPI_Placement.cpp;h=3cc4f85aedc6bea31cedcd8ecf2e713996ef2a54;hb=53f6beb5ed80b108cbfc5a8aca6b2bea370458d3;hp=6a378adde2ce10d71514694ad793a12805661566;hpb=71cf58ac99d209975c4dc6d25d2fc9705eab3908;p=modules%2Fshaper.git diff --git a/src/GeomAlgoAPI/GeomAlgoAPI_Placement.cpp b/src/GeomAlgoAPI/GeomAlgoAPI_Placement.cpp index 6a378adde..3cc4f85ae 100644 --- a/src/GeomAlgoAPI/GeomAlgoAPI_Placement.cpp +++ b/src/GeomAlgoAPI/GeomAlgoAPI_Placement.cpp @@ -1,3 +1,5 @@ +// Copyright (C) 2014-20xx CEA/DEN, EDF R&D + // File: GeomAlgoAPI_Placement.cpp // Created: 2 Dec 2014 // Author: Artem ZHIDKOV @@ -15,8 +17,7 @@ #include #include #include - - +#define DEB_PLACEMENT 1 GeomAlgoAPI_Placement::GeomAlgoAPI_Placement( std::shared_ptr theAttractiveFace, std::shared_ptr theSourcePlane, @@ -57,17 +58,19 @@ void GeomAlgoAPI_Placement::build( setImpl(aBuilder); myDone = aBuilder->IsDone() == Standard_True; if (myDone) { - TopoDS_Shape aResult; - if(aBuilder->Shape().ShapeType() == TopAbs_COMPOUND) - aResult = GeomAlgoAPI_DFLoader::refineResult(aBuilder->Shape()); - else - aResult = aBuilder->Shape(); + TopoDS_Shape aResult = aBuilder->Shape(); // fill data map to keep correct orientation of sub-shapes for (TopExp_Explorer Exp(aResult,TopAbs_FACE); Exp.More(); Exp.Next()) { std::shared_ptr aCurrentShape(new GeomAPI_Shape()); aCurrentShape->setImpl(new TopoDS_Shape(Exp.Current())); myMap.bind(aCurrentShape, aCurrentShape); - } + } +#ifdef DEB_PLACEMENT + int aNum = myMap.size(); + cout << "MAP of Oriented shapes =" << aNum <setImpl(new TopoDS_Shape(aResult)); myMkShape = new GeomAlgoAPI_MakeShape (aBuilder); }