SHAPER 9.16.0
GeomAPI_Circ.h
1// Copyright (C) 2014-2026 CEA, EDF
2//
3// This library is free software; you can redistribute it and/or
4// modify it under the terms of the GNU Lesser General Public
5// License as published by the Free Software Foundation; either
6// version 2.1 of the License, or (at your option) any later version.
7//
8// This library is distributed in the hope that it will be useful,
9// but WITHOUT ANY WARRANTY; without even the implied warranty of
10// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11// Lesser General Public License for more details.
12//
13// You should have received a copy of the GNU Lesser General Public
14// License along with this library; if not, write to the Free Software
15// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
16//
17// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18//
19
20#ifndef GeomAPI_Circ_H_
21#define GeomAPI_Circ_H_
22
23#include <GeomAPI_Interface.h>
24#include <GeomAPI_Curve.h>
25#include <memory>
26
27class GeomAPI_Ax2;
28class GeomAPI_Pnt;
29class GeomAPI_Dir;
30
37{
38 public:
39
47 GEOMAPI_EXPORT GeomAPI_Circ(const std::shared_ptr<GeomAPI_Ax2> theAx2,
48 const double theRadius);
49
51 GEOMAPI_EXPORT GeomAPI_Circ(const std::shared_ptr<GeomAPI_Pnt>& theCenter,
52 const std::shared_ptr<GeomAPI_Dir>& theDir, double theRadius);
53
55 GEOMAPI_EXPORT GeomAPI_Circ(const GeomCurvePtr& theCurve);
56
58 GEOMAPI_EXPORT const std::shared_ptr<GeomAPI_Pnt> center() const;
59
61 GEOMAPI_EXPORT double radius() const;
62
64 GEOMAPI_EXPORT std::shared_ptr<GeomAPI_Dir> normal() const;
65
67 GEOMAPI_EXPORT const std::shared_ptr<GeomAPI_Pnt> project(
68 const std::shared_ptr<GeomAPI_Pnt>& thePoint) const;
69
79 GEOMAPI_EXPORT const bool parameter(const std::shared_ptr<GeomAPI_Pnt> thePoint,
80 const double theTolerance,
81 double& theParameter) const;
82};
83
85typedef std::shared_ptr<GeomAPI_Circ> GeomCirclePtr;
86
87#endif
88
The class represents an axis in 3D space.
Definition: GeomAPI_Ax2.h:31
Circle in 3D.
Definition: GeomAPI_Circ.h:37
GEOMAPI_EXPORT std::shared_ptr< GeomAPI_Dir > normal() const
Return orthogonal direction to the circle's plane.
Definition: GeomAPI_Circ.cpp:122
GEOMAPI_EXPORT const bool parameter(const std::shared_ptr< GeomAPI_Pnt > thePoint, const double theTolerance, double &theParameter) const
Computes the parameter of a given point on a circle.
Definition: GeomAPI_Circ.cpp:112
GEOMAPI_EXPORT double radius() const
Return radius of the circle.
Definition: GeomAPI_Circ.cpp:77
GEOMAPI_EXPORT const std::shared_ptr< GeomAPI_Pnt > project(const std::shared_ptr< GeomAPI_Pnt > &thePoint) const
Project point on circle.
Definition: GeomAPI_Circ.cpp:83
GEOMAPI_EXPORT GeomAPI_Circ(const std::shared_ptr< GeomAPI_Ax2 > theAx2, const double theRadius)
Constructs a circle of radius Radius, where theAx2 locates the circle and defines its orientation in ...
Definition: GeomAPI_Circ.cpp:43
GEOMAPI_EXPORT const std::shared_ptr< GeomAPI_Pnt > center() const
Return center of the circle.
Definition: GeomAPI_Circ.cpp:70
3D direction defined by three normalized coordinates
Definition: GeomAPI_Dir.h:34
General base class for all interfaces in this package.
Definition: GeomAPI_Interface.h:38
3D point defined by three coordinates
Definition: GeomAPI_Pnt.h:38