X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FGeomAlgoAPI%2FGeomAlgoAPI_EdgeBuilder.h;h=245e97f05888c0795f2d21e37dde3f242ae10e05;hb=09365c927ebe8d881de2eda7f96bc33a2d9511c8;hp=bb01b7bf52d96a912bfe33a1ef8ed72bfb7ad8c8;hpb=3ca758d1ecab7b2e601b36425ea4c20e9e857412;p=modules%2Fshaper.git diff --git a/src/GeomAlgoAPI/GeomAlgoAPI_EdgeBuilder.h b/src/GeomAlgoAPI/GeomAlgoAPI_EdgeBuilder.h index bb01b7bf5..245e97f05 100644 --- a/src/GeomAlgoAPI/GeomAlgoAPI_EdgeBuilder.h +++ b/src/GeomAlgoAPI/GeomAlgoAPI_EdgeBuilder.h @@ -1,15 +1,32 @@ -// File: GeomAlgoAPI_EdgeBuilder.h -// Created: 23 Apr 2014 -// Author: Mikhail PONIKAROV +// Copyright (C) 2014-2019 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 +// License as published by the Free Software Foundation; either +// version 2.1 of the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// 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/ or email : webmaster.salome@opencascade.com +// -#ifndef GeomAlgoAPI_EdgeBuilder_HeaderFile -#define GeomAlgoAPI_EdgeBuilder_HeaderFile +#ifndef GeomAlgoAPI_EdgeBuilder_H_ +#define GeomAlgoAPI_EdgeBuilder_H_ #include #include #include #include -#include +#include +#include +#include /**\class GeomAlgoAPI_EdgeBuilder * \ingroup DataAlgo @@ -18,22 +35,60 @@ class GEOMALGOAPI_EXPORT GeomAlgoAPI_EdgeBuilder { -public: - /// Creates linear edge by two points - static boost::shared_ptr line( - boost::shared_ptr theStart, boost::shared_ptr theEnd); + public: + /// Creates linear edge by two points. + /// \param theStart a first point of an edge + /// \param theEnd an end point of an edge + static std::shared_ptr line(std::shared_ptr theStart, + std::shared_ptr theEnd); + + /// Creates linear edge by three dimensions. + /// \param theX the X dimension + /// \param theY the Y dimension + /// \param theZ the Z dimension + static std::shared_ptr line(double theDX, + double theDY, + double theDZ); + + /// Creates linear edge by GeomAPI_Lin. + /// \param theLin line. + static std::shared_ptr line(const std::shared_ptr theLin); + + /// Creates edge - axis of the given cylindrical face. The result axis edge is infinite + static std::shared_ptr cylinderAxis( + std::shared_ptr theCylindricalFace); /// Creates linear edge in a form of a circle by a point and a circle radius - static boost::shared_ptr lineCircle( - boost::shared_ptr theCenter, - boost::shared_ptr theNormal, double theRadius); + static std::shared_ptr lineCircle(std::shared_ptr theCenter, + std::shared_ptr theNormal, + double theRadius); + + /// Creates linear edge in a form of a circle by GeomAPI_Circle + static std::shared_ptr lineCircle(std::shared_ptr theCircle); /// Creates linear edge in a form of a circle arc by a three points - static boost::shared_ptr lineCircleArc( - boost::shared_ptr theCenter, - boost::shared_ptr theStartPoint, - boost::shared_ptr theEndPoint, - boost::shared_ptr theNormal); + static std::shared_ptr lineCircleArc(std::shared_ptr theCenter, + std::shared_ptr theStartPoint, + std::shared_ptr theEndPoint, + std::shared_ptr theNormal); + + /// Creates elliptic edge + static std::shared_ptr ellipse(const std::shared_ptr& theCenter, + const std::shared_ptr& theNormal, + const std::shared_ptr& theMajorAxis, + const double theMajorRadius, + const double theMinorRadius); + + + /// Creates elliptic edge + static std::shared_ptr ellipticArc( + const std::shared_ptr& theCenter, + const std::shared_ptr& theNormal, + const std::shared_ptr& theMajorAxis, + const double theMajorRadius, + const double theMinorRadius, + const std::shared_ptr& theStart, + const std::shared_ptr& theEnd); }; #endif