From: caremoli Date: Thu, 1 Jul 2010 08:45:51 +0000 (+0000) Subject: CCAR: various optimisations : display and GEOM_Client X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=3b461374c9973721893e9b88f7b1068b2e9afdc5;p=modules%2Fgeom.git CCAR: various optimisations : display and GEOM_Client and timings --- diff --git a/src/EntityGUI/EntityGUI_SketcherDlg.cxx b/src/EntityGUI/EntityGUI_SketcherDlg.cxx index 8538d514f..0cd60e315 100644 --- a/src/EntityGUI/EntityGUI_SketcherDlg.cxx +++ b/src/EntityGUI/EntityGUI_SketcherDlg.cxx @@ -1745,7 +1745,8 @@ void EntityGUI_SketcherDlg::FindLocalCS() continue; if (geomObj->GetType() == GEOM_MARKER) { ComboBox1->addItem(geomObj->GetName()); - TopoDS_Shape aShape = GEOM_Client().GetShape(GeometryGUI::GetGeomGen(), geomObj); + //TopoDS_Shape aShape = GEOM_Client().GetShape(GeometryGUI::GetGeomGen(), geomObj); + TopoDS_Shape aShape = GEOM_Client::ShapeReader.GetShape(GeometryGUI::GetGeomGen(), geomObj); gp_Ax3 aLCS; aLCS.Transform(aShape.Location().Transformation()); diff --git a/src/GEOM/GEOM_Object.cxx b/src/GEOM/GEOM_Object.cxx index cbbce1eeb..ca8ac421d 100644 --- a/src/GEOM/GEOM_Object.cxx +++ b/src/GEOM/GEOM_Object.cxx @@ -191,7 +191,7 @@ GEOM_Object::GEOM_Object(TDF_Label& theEntry, int theType) //============================================================================= GEOM_Object::~GEOM_Object() { - MESSAGE("GEOM_Object::~GEOM_Object()"); + //MESSAGE("GEOM_Object::~GEOM_Object()"); } //============================================================================= diff --git a/src/GEOMBase/GEOMBase.cxx b/src/GEOMBase/GEOMBase.cxx index 6cbf4f374..654167ccb 100644 --- a/src/GEOMBase/GEOMBase.cxx +++ b/src/GEOMBase/GEOMBase.cxx @@ -85,7 +85,8 @@ TopoDS_Shape GEOMBase::GetShapeFromIOR(QString IOR) if (GeomObject->_is_nil()) return result; - result = GEOM_Client().GetShape(GeometryGUI::GetGeomGen(), GeomObject); + //result = GEOM_Client().GetShape(GeometryGUI::GetGeomGen(), GeomObject); + result = GEOM_Client::ShapeReader.GetShape(GeometryGUI::GetGeomGen(), GeomObject); return result; } @@ -909,7 +910,8 @@ bool GEOMBase::GetShape( const GEOM::GEOM_Object_ptr& theObject, TopoDS_Shape& t { if ( !CORBA::is_nil( theObject ) ) { - TopoDS_Shape aTopoDSShape = GEOM_Client().GetShape( GeometryGUI::GetGeomGen(), theObject ); + //TopoDS_Shape aTopoDSShape = GEOM_Client().GetShape( GeometryGUI::GetGeomGen(), theObject ); + TopoDS_Shape aTopoDSShape = GEOM_Client::ShapeReader.GetShape( GeometryGUI::GetGeomGen(), theObject ); if ( !aTopoDSShape.IsNull() && ( theType == TopAbs_SHAPE || theType == aTopoDSShape.ShapeType() ) ) { theShape = aTopoDSShape; diff --git a/src/GEOMBase/GEOMBase_Helper.cxx b/src/GEOMBase/GEOMBase_Helper.cxx index 3a2878658..26b943510 100755 --- a/src/GEOMBase/GEOMBase_Helper.cxx +++ b/src/GEOMBase/GEOMBase_Helper.cxx @@ -53,6 +53,14 @@ #include #include +#include +static long tcount=0; +static long cumul; +#define START_TIMING long tt0; timeval tv; gettimeofday(&tv,0);tt0=tv.tv_usec+tv.tv_sec*1000000; +#define END_TIMING(NUMBER) \ + tcount=tcount+1;gettimeofday(&tv,0);cumul=cumul+tv.tv_usec+tv.tv_sec*1000000 -tt0; \ + if(tcount==NUMBER){ std::cerr << __FILE__ << __LINE__ << " temps CPU(mus): " << cumul << std::endl; tcount=0;cumul=0; } + //To disable automatic genericobj management, the following line should be commented. //Otherwise, it should be uncommented. Refer to KERNEL_SRC/src/SALOMEDSImpl/SALOMEDSImpl_AttributeIOR.cxx #define WITHGENERICOBJ @@ -657,7 +665,8 @@ void GEOMBase_Helper::clearShapeBuffer( GEOM::GEOM_Object_ptr theObj ) CORBA::String_var IOR = SalomeApp_Application::orb()->object_to_string( theObj ); TCollection_AsciiString asciiIOR( (char *)IOR.in() ); - GEOM_Client().RemoveShapeFromBuffer( asciiIOR ); + //GEOM_Client().RemoveShapeFromBuffer( asciiIOR ); + GEOM_Client::ShapeReader.RemoveShapeFromBuffer( asciiIOR ); if ( !getStudy() || !getStudy()->studyDS() ) return; @@ -673,7 +682,8 @@ void GEOMBase_Helper::clearShapeBuffer( GEOM::GEOM_Object_ptr theObj ) if ( anIt->Value()->FindAttribute(anAttr, "AttributeIOR") ) { _PTR(AttributeIOR) anIOR ( anAttr ); TCollection_AsciiString asciiIOR( (char*)anIOR->Value().c_str() ); - GEOM_Client().RemoveShapeFromBuffer( asciiIOR ); + //GEOM_Client().RemoveShapeFromBuffer( asciiIOR ); + GEOM_Client::ShapeReader.RemoveShapeFromBuffer( asciiIOR ); } } } @@ -800,6 +810,7 @@ bool GEOMBase_Helper::onAccept( const bool publish, const bool useTransaction ) return false; } + START_TIMING; erasePreview( false ); bool result = false; @@ -873,6 +884,7 @@ bool GEOMBase_Helper::onAccept( const bool publish, const bool useTransaction ) } updateViewer(); + END_TIMING(1); return result; } diff --git a/src/GEOMClient/GEOM_Client.cxx b/src/GEOMClient/GEOM_Client.cxx index 0e07e69d3..f3dedef25 100644 --- a/src/GEOMClient/GEOM_Client.cxx +++ b/src/GEOMClient/GEOM_Client.cxx @@ -58,6 +58,17 @@ #define HST_CLIENT_LEN 256 +#include + +#include +static long tcount=0; +static long cumul; +#define START_TIMING long tt0; timeval tv; gettimeofday(&tv,0);tt0=tv.tv_usec+tv.tv_sec*1000000; +#define END_TIMING(NUMBER) \ + tcount=tcount+1;gettimeofday(&tv,0);cumul=cumul+tv.tv_usec+tv.tv_sec*1000000 -tt0; \ + if(tcount==NUMBER){ std::cerr << __FILE__ << __LINE__ << " temps CPU(mus): " << cumul << std::endl; tcount=0;cumul=0; } + +GEOM_Client GEOM_Client::ShapeReader; //======================================================================= // function : Load() @@ -117,6 +128,19 @@ GEOM_Client::GEOM_Client(Engines::Container_ptr client) //======================================================================= Standard_Integer GEOM_Client::Find( const TCollection_AsciiString& IOR, TopoDS_Shape& S ) { + //CCAR +#if 1 + if(_myIndexes.count(IOR)==0) + { + return 0; + } + else + { + Standard_Integer i =_myIndexes[IOR]; + S = myShapes.Value(i); + return i; + } +#else for ( Standard_Integer i = 1; i<= myIORs.Length(); i++ ) { if (myIORs.Value(i).IsEqual(IOR)) { S = myShapes.Value(i); @@ -124,6 +148,7 @@ Standard_Integer GEOM_Client::Find( const TCollection_AsciiString& IOR, TopoDS_S } } return 0; +#endif } //======================================================================= @@ -149,6 +174,7 @@ void GEOM_Client::Bind( const TCollection_AsciiString& IOR, const TopoDS_Shape& { myIORs.Append(IOR); myShapes.Append(S); + _myIndexes[IOR]=myIORs.Length(); } //======================================================================= @@ -165,6 +191,8 @@ void GEOM_Client::RemoveShapeFromBuffer( const TCollection_AsciiString& IOR) if( anIndex != 0 ) { myIORs.Remove(anIndex); myShapes.Remove(anIndex); + _myIndexes.erase(IOR); + _mySubShapes.erase(IOR); } return; } @@ -179,6 +207,8 @@ void GEOM_Client::ClearClientBuffer() return; myIORs.Clear(); myShapes.Clear(); + _myIndexes.clear(); + _mySubShapes.clear(); return; } @@ -202,7 +232,10 @@ TopoDS_Shape GEOM_Client::GetShape( GEOM::GEOM_Gen_ptr geom, GEOM::GEOM_Object_p TCollection_AsciiString IOR = (char*)anIOR.in(); Standard_Integer anIndex = Find(IOR, S); - if (anIndex != 0) return S; + if (anIndex != 0) + { + return S; + } /******* in case of a MAIN GEOM::SHAPE ********/ if (aShape->IsMainShape()) { @@ -216,12 +249,28 @@ TopoDS_Shape GEOM_Client::GetShape( GEOM::GEOM_Gen_ptr geom, GEOM::GEOM_Object_p TopoDS_Shape aMainShape = GetShape (geom, aShape->GetMainShape()); GEOM::ListOfLong_var list = aShape->GetSubShapeIndices(); + START_TIMING; + TopTools_IndexedMapOfShape anIndices; - TopExp::MapShapes(aMainShape, anIndices); + anIOR = geom->GetStringFromIOR(aShape->GetMainShape()); + IOR = (char*)anIOR.in(); + + //find subshapes only one time + if(_mySubShapes.count(IOR)==0) + { + std::cerr << "find sub shapes " << std::endl; + TopExp::MapShapes(aMainShape, anIndices); + Standard_Integer ii = 1, nbSubSh = anIndices.Extent(); + for (; ii <= nbSubSh; ii++) + { + _mySubShapes[IOR].push_back(anIndices.FindKey(ii)); + } + } /* Case of only one subshape */ if (list->length() == 1 && list[0] > 0) { - S = anIndices.FindKey(list[0]); + //S = anIndices.FindKey(list[0]); + S = _mySubShapes[IOR][list[0]-1]; } else { BRep_Builder B; @@ -229,7 +278,8 @@ TopoDS_Shape GEOM_Client::GetShape( GEOM::GEOM_Gen_ptr geom, GEOM::GEOM_Object_p B.MakeCompound(aCompound); for (int i = 0; i < list->length(); i++) { if (0 < list[i] && list[i] <= anIndices.Extent()) { - TopoDS_Shape aSubShape = anIndices.FindKey(list[i]); + TopoDS_Shape aSubShape = _mySubShapes[IOR][list[i]-1]; + //TopoDS_Shape aSubShape = anIndices.FindKey(list[i]); B.Add(aCompound, aSubShape); } } @@ -237,5 +287,6 @@ TopoDS_Shape GEOM_Client::GetShape( GEOM::GEOM_Gen_ptr geom, GEOM::GEOM_Object_p S = aCompound; } Bind(IOR, S); + END_TIMING(100); return S; } diff --git a/src/GEOMClient/GEOM_Client.hxx b/src/GEOMClient/GEOM_Client.hxx index f5f9cafc2..2586126ae 100644 --- a/src/GEOMClient/GEOM_Client.hxx +++ b/src/GEOMClient/GEOM_Client.hxx @@ -73,6 +73,10 @@ class TopoDS_Shape; #define GEOMCLIENT_EXPORT #endif +#include +#include +#include + //===================================================================== // GEOM_Client : class definition //===================================================================== @@ -113,12 +117,15 @@ public: //Standard_EXPORT unsigned int BufferLength() ; TopoDS_Shape Load( GEOM::GEOM_Gen_ptr geom, GEOM::GEOM_Object_ptr aShape); + static GEOM_Client ShapeReader; private: // Fields PRIVATE // TColStd_SequenceOfAsciiString myIORs ; TopTools_SequenceOfShape myShapes ; + std::map< TCollection_AsciiString , int > _myIndexes; + std::map< TCollection_AsciiString , std::vector > _mySubShapes; long pid_client; }; diff --git a/src/GEOMFiltersSelection/GEOM_SelectionFilter.cxx b/src/GEOMFiltersSelection/GEOM_SelectionFilter.cxx index f90cc20e5..01884fb0b 100644 --- a/src/GEOMFiltersSelection/GEOM_SelectionFilter.cxx +++ b/src/GEOMFiltersSelection/GEOM_SelectionFilter.cxx @@ -139,7 +139,8 @@ bool GEOM_SelectionFilter::getShape (const GEOM::GEOM_Object_ptr& theObject, } if ( !CORBA::is_nil( geomGen ) ) { - TopoDS_Shape aTopoDSShape = GEOM_Client().GetShape( geomGen, theObject ); + //TopoDS_Shape aTopoDSShape = GEOM_Client().GetShape( geomGen, theObject ); + TopoDS_Shape aTopoDSShape = GEOM_Client::ShapeReader.GetShape( geomGen, theObject ); if ( !aTopoDSShape.IsNull() ) { diff --git a/src/GEOMGUI/GEOM_Displayer.cxx b/src/GEOMGUI/GEOM_Displayer.cxx index 82853c712..b118490c3 100644 --- a/src/GEOMGUI/GEOM_Displayer.cxx +++ b/src/GEOMGUI/GEOM_Displayer.cxx @@ -92,6 +92,14 @@ #include #include +#include +static long tcount=0; +static long cumul; +#define START_TIMING long tt0; timeval tv; gettimeofday(&tv,0);tt0=tv.tv_usec+tv.tv_sec*1000000; +#define END_TIMING(NUMBER) \ + tcount=tcount+1;gettimeofday(&tv,0);cumul=cumul+tv.tv_usec+tv.tv_sec*1000000 -tt0; \ + if(tcount==NUMBER){ std::cerr << __FILE__ << __LINE__ << " temps CPU(mus): " << cumul << std::endl; tcount=0;cumul=0; } + //================================================================ // Function : getActiveStudy @@ -303,9 +311,11 @@ void GEOM_Displayer::Display( const Handle(SALOME_InteractiveObject)& theIO, if ( prs ) { + START_TIMING; vf->BeforeDisplay( this ); vf->Display( prs ); vf->AfterDisplay( this ); + END_TIMING(100); if ( updateViewer ) vf->Repaint(); @@ -935,7 +945,8 @@ SALOME_Prs* GEOM_Displayer::BuildPrs( GEOM::GEOM_Object_ptr theObj ) return 0; internalReset(); - setShape( GEOM_Client().GetShape( GeometryGUI::GetGeomGen(), theObj ) ); + setShape( GEOM_Client::ShapeReader.GetShape( GeometryGUI::GetGeomGen(), theObj ) ); + //setShape( GEOM_Client().GetShape( GeometryGUI::GetGeomGen(), theObj ) ); myType = theObj->GetType(); // Update presentation @@ -1016,7 +1027,8 @@ SALOME_Prs* GEOM_Displayer::buildPresentation( const QString& entry, if ( !GeomObject->_is_nil() ) { // finally set shape - setShape( GEOM_Client().GetShape( GeometryGUI::GetGeomGen(), GeomObject ) ); + setShape( GEOM_Client::ShapeReader.GetShape( GeometryGUI::GetGeomGen(), GeomObject ) ); + //setShape( GEOM_Client().GetShape( GeometryGUI::GetGeomGen(), GeomObject ) ); myType = GeomObject->GetType(); } } @@ -1025,6 +1037,7 @@ SALOME_Prs* GEOM_Displayer::buildPresentation( const QString& entry, } } UpdatePrs( prs ); // Update presentation by using of the double dispatch + myViewFrame->updateViewer( prs ); } } return prs; diff --git a/src/GEOMGUI/GeometryGUI.h b/src/GEOMGUI/GeometryGUI.h index 69cd94753..613282d40 100644 --- a/src/GEOMGUI/GeometryGUI.h +++ b/src/GEOMGUI/GeometryGUI.h @@ -87,7 +87,8 @@ public: static CORBA::Object_var ClientSObjectToObject (_PTR(SObject) theSObject); static SALOMEDS::Study_var ClientStudyToStudy (_PTR(Study) theStudy); - GEOM_Client& GetShapeReader() { return myShapeReader; } + GEOM_Client& GetShapeReader() { return GEOM_Client::ShapeReader; } + //GEOM_Client& GetShapeReader() { return myShapeReader; } // Get active dialog box QDialog* GetActiveDialogBox(){ return myActiveDialogBox; } diff --git a/src/GEOMGUI/GeometryGUI_Swig.cxx b/src/GEOMGUI/GeometryGUI_Swig.cxx index 9c9c9533d..73b49083a 100644 --- a/src/GEOMGUI/GeometryGUI_Swig.cxx +++ b/src/GEOMGUI/GeometryGUI_Swig.cxx @@ -68,6 +68,14 @@ #include +#include +static long tcount=0; +static long cumul; +#define START_TIMING long tt0; timeval tv; gettimeofday(&tv,0);tt0=tv.tv_usec+tv.tv_sec*1000000; +#define END_TIMING(NUMBER) \ + tcount=tcount+1;gettimeofday(&tv,0);cumul=cumul+tv.tv_usec+tv.tv_sec*1000000 -tt0; \ + if(tcount==NUMBER){ std::cerr << __FILE__ << __LINE__ << " temps CPU(mus): " << cumul << std::endl; tcount=0;cumul=0; } + static GEOM_Client ShapeReader; inline OCCViewer_Viewer* GetOCCViewer(SUIT_Application* theApp){ @@ -154,7 +162,7 @@ void GEOM_Swig::createAndDisplayGO (const char* Entry, bool isUpdated) std::string anIORValue = anIOR->Value(); GEOM::GEOM_Object_var aShape = Geom->GetIORFromString(anIORValue.c_str()); - TopoDS_Shape Shape = ShapeReader.GetShape(Geom,aShape); + TopoDS_Shape Shape = GEOM_Client::ShapeReader.GetShape(Geom,aShape); if (!Shape.IsNull()) { if (obj->FindAttribute(anAttr, "AttributeName")) { _PTR(AttributeName) aName (anAttr); @@ -167,6 +175,7 @@ void GEOM_Swig::createAndDisplayGO (const char* Entry, bool isUpdated) aStudyBuilder->Addreference(newObj1, obj); // commit transaction op->commit();*/ + START_TIMING; Handle(GEOM_InteractiveObject) anIO = new GEOM_InteractiveObject (const_cast(anIORValue.c_str()), const_cast(aFatherIOR.c_str()), @@ -174,6 +183,7 @@ void GEOM_Swig::createAndDisplayGO (const char* Entry, bool isUpdated) const_cast( obj->GetID().c_str())); GEOM_Displayer(ActiveStudy).Display(anIO, myUpdateViewer); + END_TIMING(100); /*if (SVTK_ViewWindow* aViewWindow = GetSVTKViewWindow(app)) { SVTK_View* aView = aViewWindow->getView(); int aMode = aView->GetDisplayMode(); diff --git a/src/GEOM_I/GEOM_Gen_i.cc b/src/GEOM_I/GEOM_Gen_i.cc index 0b6a72d35..9c7ce2cea 100644 --- a/src/GEOM_I/GEOM_Gen_i.cc +++ b/src/GEOM_I/GEOM_Gen_i.cc @@ -61,6 +61,17 @@ #include "SALOMEDS_Tool.hxx" +#include +static long tt0; +static long tcount=0; +static long cumul; +static timeval tv; +#define START_TIMING gettimeofday(&tv,0);tt0=tv.tv_usec+tv.tv_sec*1000000; +#define END_TIMING(NUMBER) \ + tcount=tcount+1;gettimeofday(&tv,0);cumul=cumul+tv.tv_usec+tv.tv_sec*1000000 -tt0; \ + if(tcount==NUMBER){ std::cerr << __FILE__ << __LINE__ << " temps CPU(mus): " << cumul << std::endl; tcount=0;cumul=0; } + + //============================================================================ // function : GEOM_Gen_i() // purpose : constructor to be called for servant creation. @@ -735,6 +746,7 @@ SALOMEDS::SObject_ptr GEOM_Gen_i::AddInStudy (SALOMEDS::Study_ptr theStudy, { SALOMEDS::SObject_var aResultSO; if(theObject->_is_nil() || theStudy->_is_nil()) return aResultSO; + //START_TIMING; SALOMEDS::StudyBuilder_var aStudyBuilder = theStudy->NewBuilder(); CORBA::String_var IOR; @@ -768,6 +780,7 @@ SALOMEDS::SObject_ptr GEOM_Gen_i::AddInStudy (SALOMEDS::Study_ptr theStudy, aSubSO->Destroy(); } + //END_TIMING(100); return aResultSO._retn(); } diff --git a/src/GEOM_I/GEOM_Object_i.cc b/src/GEOM_I/GEOM_Object_i.cc index 6b9d7ea00..f091c990f 100644 --- a/src/GEOM_I/GEOM_Object_i.cc +++ b/src/GEOM_I/GEOM_Object_i.cc @@ -65,7 +65,7 @@ GEOM_Object_i::GEOM_Object_i (PortableServer::POA_ptr thePOA, GEOM::GEOM_Gen_ptr GEOM_Object_i::~GEOM_Object_i() { - MESSAGE("GEOM_Object_i::~GEOM_Object_i"); + //MESSAGE("GEOM_Object_i::~GEOM_Object_i"); GEOM_Engine::GetEngine()->RemoveObject(_impl); } diff --git a/src/GroupGUI/GroupGUI_GroupDlg.cxx b/src/GroupGUI/GroupGUI_GroupDlg.cxx index 8391cb3bf..6ff6b6a0e 100644 --- a/src/GroupGUI/GroupGUI_GroupDlg.cxx +++ b/src/GroupGUI/GroupGUI_GroupDlg.cxx @@ -653,7 +653,8 @@ int GroupGUI_GroupDlg::getSelectedSubshapes (TColStd_IndexedMapOfInteger& theMap if (GEOMBase::GetShape(aGeomObj, aShape)) { if (aGeomObj->GetType() == GEOM_GROUP || aShape.ShapeType() == getShapeType()) { TopTools_IndexedMapOfShape aMainMap; - TopoDS_Shape aMainShape = GEOM_Client().GetShape(GeometryGUI::GetGeomGen(), myMainObj); + TopoDS_Shape aMainShape = GEOM_Client::ShapeReader.GetShape(GeometryGUI::GetGeomGen(), myMainObj); + //TopoDS_Shape aMainShape = GEOM_Client().GetShape(GeometryGUI::GetGeomGen(), myMainObj); TopExp::MapShapes(aMainShape, aMainMap); TopExp_Explorer anExp (aShape, getShapeType()); @@ -802,12 +803,14 @@ void GroupGUI_GroupDlg::activateSelection() SALOME_View* aView = dynamic_cast(aViewModel); if (aView == 0) return; - TopoDS_Shape aMainShape = GEOM_Client().GetShape(GeometryGUI::GetGeomGen(), myMainObj); + TopoDS_Shape aMainShape = GEOM_Client::ShapeReader.GetShape(GeometryGUI::GetGeomGen(), myMainObj); + //TopoDS_Shape aMainShape = GEOM_Client().GetShape(GeometryGUI::GetGeomGen(), myMainObj); TopoDS_Shape aRestrictionShape; if (subSelectionWay() == ALL_SUBSHAPES) aRestrictionShape = aMainShape; else if (!myInPlaceObj->_is_nil()) - aRestrictionShape = GEOM_Client().GetShape(GeometryGUI::GetGeomGen(), myInPlaceObj); + aRestrictionShape = GEOM_Client::ShapeReader.GetShape(GeometryGUI::GetGeomGen(), myInPlaceObj); + //aRestrictionShape = GEOM_Client().GetShape(GeometryGUI::GetGeomGen(), myInPlaceObj); else ; TopTools_IndexedMapOfShape aSubShapesMap; diff --git a/src/RepairGUI/RepairGUI_SuppressFacesDlg.cxx b/src/RepairGUI/RepairGUI_SuppressFacesDlg.cxx index 15796bc2f..c94c1a3ac 100644 --- a/src/RepairGUI/RepairGUI_SuppressFacesDlg.cxx +++ b/src/RepairGUI/RepairGUI_SuppressFacesDlg.cxx @@ -213,7 +213,8 @@ void RepairGUI_SuppressFacesDlg::SelectionIntoArgument() _PTR(Study) aStudy = appStudy->studyDS(); TopTools_IndexedMapOfShape aMainMap; - TopoDS_Shape aMainShape = GEOM_Client().GetShape(GeometryGUI::GetGeomGen(), myObject); + TopoDS_Shape aMainShape = GEOM_Client::ShapeReader.GetShape(GeometryGUI::GetGeomGen(), myObject); + //TopoDS_Shape aMainShape = GEOM_Client().GetShape(GeometryGUI::GetGeomGen(), myObject); TopExp::MapShapes(aMainShape, aMainMap); SALOME_ListIteratorOfListIO anIter (aSelList);