X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FSketchPlugin%2FSketchPlugin_Projection.h;h=64f7844b73ea76c353243aed8400abd41ad42725;hb=e8b0963c64ad81be042fffe660ce874ae4d3abd5;hp=b928dfabdd5c577428685e3805da92641c5e0b56;hpb=c4eab94a20a0d93100549a210582d46409fec1cc;p=modules%2Fshaper.git diff --git a/src/SketchPlugin/SketchPlugin_Projection.h b/src/SketchPlugin/SketchPlugin_Projection.h index b928dfabd..64f7844b7 100644 --- a/src/SketchPlugin/SketchPlugin_Projection.h +++ b/src/SketchPlugin/SketchPlugin_Projection.h @@ -1,4 +1,4 @@ -// Copyright (C) 2014-2019 CEA/DEN, EDF R&D +// Copyright (C) 2014-2020 CEA/DEN, EDF R&D // // This library is free software; you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public @@ -22,6 +22,8 @@ #include "SketchPlugin_SketchEntity.h" +class GeomAPI_Curve; + /** \class SketchPlugin_Projection * \ingroup Plugins * \brief Feature for creation of external feature as a projection onto the sketch plane. @@ -88,6 +90,44 @@ private: /// \brief Find projection of a feature onto sketch plane void computeProjection(const std::string& theID); + /// \brief Project point to the sketch plane + bool projectPoint(FeaturePtr& theProjection, const std::shared_ptr& thePoint); + /// \brief Project segment to the sketch plane + bool projectSegment(FeaturePtr& theProjection, const std::shared_ptr& theEdge); + /// \brief Project any edge to sketch plane + bool projectEdge(FeaturePtr& theProjection, const std::shared_ptr& theEdge); + + /// \brief Fill attributes of the Arc feature + bool fillArc(FeaturePtr& theProjection, + const std::shared_ptr& theArc, + const std::shared_ptr& thePlane); + /// \brief Fill attributes of the Circle feature + bool fillCircle(FeaturePtr& theProjection, + const std::shared_ptr& theCircle, + const std::shared_ptr& thePlane); + /// \brief Fill attributes of the Ellipse feature + bool fillEllipse(FeaturePtr& theProjection, + const std::shared_ptr& theEllipse, + const std::shared_ptr& thePlane); + /// \brief Fill attributes of the EllipticArc feature + bool fillEllipticArc(FeaturePtr& theProjection, + const std::shared_ptr& theEllipticArc, + const std::shared_ptr& thePlane); + /// \brief Fill attributes of the B-spline feature + bool fillBSpline(FeaturePtr& theProjection, + const std::shared_ptr& theCurve, + const std::shared_ptr& thePlane); + + /// \brief Delete already calculated projected feature + /// if the selection of the projection is changed + /// \param[in/out] theProjection projected feature + /// \param[in] theSupportedTypes types supported relatively to the base selection + /// \param[in] theRequestedFeature type of the new feature to be created + /// (remove only if empty string). + bool rebuildProjectedFeature(FeaturePtr& theProjection, + const std::set& theSupportedTypes, + const std::string& theRequestedFeature = std::string()); + bool myIsComputing; };