X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FGeomAPI%2FGeomAPI_WireExplorer.cpp;h=635c9b6fbbdf79332f27588338444e5276deb35c;hb=41645ab455d24dcda650377d8c044e0578e01529;hp=318819f9996385b4873676f505ace738cb535da9;hpb=47f4ee100cab87409534ba8b57e7c64582511fe3;p=modules%2Fshaper.git diff --git a/src/GeomAPI/GeomAPI_WireExplorer.cpp b/src/GeomAPI/GeomAPI_WireExplorer.cpp index 318819f99..635c9b6fb 100644 --- a/src/GeomAPI/GeomAPI_WireExplorer.cpp +++ b/src/GeomAPI/GeomAPI_WireExplorer.cpp @@ -18,6 +18,9 @@ // #include + +#include +#include #include #include @@ -49,11 +52,19 @@ void GeomAPI_WireExplorer::next() MY_EXPLORER->Next(); } -std::shared_ptr GeomAPI_WireExplorer::current() +std::shared_ptr GeomAPI_WireExplorer::current() +{ + const TopoDS_Edge& aShape = MY_EXPLORER->Current(); + std::shared_ptr aGeomShape(new GeomAPI_Edge()); + aGeomShape->setImpl(new TopoDS_Edge(aShape)); + return aGeomShape; +} + +std::shared_ptr GeomAPI_WireExplorer::currentVertex() { - const TopoDS_Shape& aShape = MY_EXPLORER->Current(); - std::shared_ptr aGeomShape(new GeomAPI_Shape()); - aGeomShape->setImpl(new TopoDS_Shape(aShape)); + const TopoDS_Vertex& aShape = MY_EXPLORER->CurrentVertex(); + std::shared_ptr aGeomShape(new GeomAPI_Vertex()); + aGeomShape->setImpl(new TopoDS_Vertex(aShape)); return aGeomShape; }