X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=src%2FGEOMImpl%2FGEOMImpl_SketcherDriver.cxx;h=2a6eb0a7bb7185c8cbdc2b3cac985604aaa68035;hb=f04efe4ef1789801c70616f0e4a98cdb5a11d49e;hp=b6075c0b4394996a69008e76c0317f96a23ace0c;hpb=a62a321c849518376e3aa4d24a0b902a24167c64;p=modules%2Fgeom.git diff --git a/src/GEOMImpl/GEOMImpl_SketcherDriver.cxx b/src/GEOMImpl/GEOMImpl_SketcherDriver.cxx index b6075c0b4..2a6eb0a7b 100644 --- a/src/GEOMImpl/GEOMImpl_SketcherDriver.cxx +++ b/src/GEOMImpl/GEOMImpl_SketcherDriver.cxx @@ -15,7 +15,7 @@ // License along with this library; if not, write to the Free Software // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA // -// See http://www.salome-platform.org/ +// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com // #include @@ -25,6 +25,9 @@ #include #include +#include + +// OCCT Includes #include #include #include @@ -100,13 +103,14 @@ Standard_Integer GEOMImpl_SketcherDriver::Execute(TFunction_Logbook& log) const { Handle(GEOM_Function) aRefFace = aCI.GetWorkingPlane(); TopoDS_Shape aShape = aRefFace->GetValue(); - if ( aShape.IsNull() || aShape.ShapeType() != TopAbs_FACE ) - return 0; - Handle(Geom_Surface) aGS = BRep_Tool::Surface( TopoDS::Face( aShape )); - if ( aGS.IsNull() || !aGS->IsKind( STANDARD_TYPE( Geom_Plane ))) - return 0; - Handle(Geom_Plane) aGPlane = Handle(Geom_Plane)::DownCast( aGS ); - aWPlane = aGPlane->Pln().Position(); + //if ( aShape.IsNull() || aShape.ShapeType() != TopAbs_FACE ) + // return 0; + //Handle(Geom_Surface) aGS = BRep_Tool::Surface( TopoDS::Face( aShape )); + //if ( aGS.IsNull() || !aGS->IsKind( STANDARD_TYPE( Geom_Plane ))) + // return 0; + //Handle(Geom_Plane) aGPlane = Handle(Geom_Plane)::DownCast( aGS ); + //aWPlane = aGPlane->Pln().Position(); + aWPlane = GEOMImpl_IMeasureOperations::GetPosition(aShape); } gp_Trsf aTrans; aTrans.SetTransformation(aWPlane);