Version: 9.12.0
GEOMUtils_TrsfCurve2d.hxx
Go to the documentation of this file.
1 // Copyright (C) 2015-2023 CEA, EDF, OPEN CASCADE
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 _GEOMUtils_TrsfCurve2d_HXX_
21 #define _GEOMUtils_TrsfCurve2d_HXX_
22 
23 #include <GEOMUtils_Trsf2d.hxx>
24 
25 #include <Geom2dHatch_Hatcher.hxx>
26 #include <GeomAbs_IsoType.hxx>
27 #include <TColStd_HArray1OfInteger.hxx>
28 #include <TColStd_HArray1OfReal.hxx>
29 #include <TopoDS_Face.hxx>
30 
31 #include <Basics_OCCTVersion.hxx>
32 
33 
34 namespace GEOMUtils
35 {
41  {
42 #if OCC_VERSION_LARGE >= 0x07070000
43  DEFINE_STANDARD_RTTIEXT(TrsfCurve2d, Adaptor2d_Curve2d)
44 #endif
45 
46  public:
47 
53  Standard_EXPORT TrsfCurve2d(const Handle(Geom2d_Curve) &theCurve,
54  const Trsf2d &theTrsf);
55 
61  Standard_EXPORT TrsfCurve2d(const Handle(Geom2d_Curve) &theCurve,
62  const Standard_Real theUFirst,
63  const Standard_Real theULast,
64  const Trsf2d &theTrsf);
65 
69  Standard_EXPORT Standard_Real FirstParameter() const;
70 
74  Standard_EXPORT Standard_Real LastParameter() const;
75 
79  Standard_EXPORT const Handle(Geom2d_Curve)& Curve() const;
80 
84  Standard_EXPORT GeomAbs_CurveType GetType() const;
85 
89  Standard_EXPORT void Load(const Handle(Geom2d_Curve) &C);
90 
94  Standard_EXPORT void Load(const Handle(Geom2d_Curve) &C,
95  const Standard_Real UFirst,
96  const Standard_Real ULast);
97 
101  Standard_EXPORT GeomAbs_Shape Continuity() const;
102 
106  Standard_EXPORT Standard_Integer NbIntervals(const GeomAbs_Shape S) const;
107 
111  Standard_EXPORT void Intervals(TColStd_Array1OfReal &T,
112  const GeomAbs_Shape S) const;
113 
117 #if OCC_VERSION_LARGE < 0x07070000
118  Standard_EXPORT Handle(Adaptor2d_HCurve2d) Trim
119 #else
120  Standard_EXPORT Handle(Adaptor2d_Curve2d) Trim
121 #endif
122  (const Standard_Real First, const Standard_Real Last,
123  const Standard_Real ) const;
124 
128  Standard_EXPORT Standard_Boolean IsClosed() const;
129 
133  Standard_EXPORT Standard_Boolean IsPeriodic() const;
134 
138  Standard_EXPORT Standard_Real Period() const;
139 
143  Standard_EXPORT gp_Pnt2d Value(const Standard_Real U) const;
144 
148  Standard_EXPORT void D0(const Standard_Real U, gp_Pnt2d &P) const;
149 
153  Standard_EXPORT void D1(const Standard_Real U,
154  gp_Pnt2d &P, gp_Vec2d &V) const;
155 
159  Standard_EXPORT void D2(const Standard_Real U, gp_Pnt2d &P,
160  gp_Vec2d &V1, gp_Vec2d &V2) const;
161 
165  Standard_EXPORT void D3(const Standard_Real U, gp_Pnt2d &P,
166  gp_Vec2d &V1, gp_Vec2d &V2, gp_Vec2d &V3) const;
167 
171  Standard_EXPORT gp_Vec2d DN(const Standard_Real U,
172  const Standard_Integer N) const;
173 
177  Standard_EXPORT Standard_Real Resolution(const Standard_Real Ruv) const;
178 
182  Standard_EXPORT gp_Lin2d Line() const;
183 
187  Standard_EXPORT gp_Circ2d Circle() const;
188 
192  Standard_EXPORT gp_Elips2d Ellipse() const;
193 
197  Standard_EXPORT gp_Hypr2d Hyperbola() const;
198 
202  Standard_EXPORT gp_Parab2d Parabola() const;
203 
207  Standard_EXPORT Standard_Integer Degree() const;
208 
212  Standard_EXPORT Standard_Boolean IsRational() const;
213 
217  Standard_EXPORT Standard_Integer NbPoles() const;
218 
222  Standard_EXPORT Standard_Integer NbKnots() const;
223 
227  Standard_EXPORT Handle(Geom2d_BezierCurve) Bezier() const;
228 
232  Standard_EXPORT Handle(Geom2d_BSplineCurve) BSpline() const;
233 
237  Standard_EXPORT Standard_Integer NbSamples() const;
238 
239  private:
240 
241  Geom2dAdaptor_Curve myCurve;
243 
244  };
245 
246 #if OCC_VERSION_LARGE >= 0x07070000
248 #endif
249 
250 }
251 
252 #endif
DEFINE_STANDARD_HANDLE(GEOM_Field, GEOM_BaseObject) DEFINE_STANDARD_HANDLE(GEOM_FieldStep
Definition: GEOMUtils_Trsf2d.hxx:48
Definition: GEOMUtils_TrsfCurve2d.hxx:41
Standard_EXPORT gp_Elips2d Ellipse() const
Redefined method from the base class.
Standard_EXPORT const Handle(Geom2d_Curve) &Curve() const
Redefined method from the base class.
Standard_EXPORT Standard_Integer NbPoles() const
Redefined method from the base class.
Standard_EXPORT Standard_Real FirstParameter() const
Redefined method from the base class.
Definition: GEOMUtils_TrsfCurve2d.cxx:60
Standard_EXPORT void Load(const Handle(Geom2d_Curve) &C)
Redefined method from the base class.
Standard_EXPORT gp_Pnt2d Value(const Standard_Real U) const
Redefined method from the base class.
Standard_EXPORT void D3(const Standard_Real U, gp_Pnt2d &P, gp_Vec2d &V1, gp_Vec2d &V2, gp_Vec2d &V3) const
Redefined method from the base class.
Standard_EXPORT gp_Lin2d Line() const
Redefined method from the base class.
Standard_EXPORT TrsfCurve2d(const Handle(Geom2d_Curve) &theCurve, const Trsf2d &theTrsf)
Constructor.
Definition: GEOMUtils_TrsfCurve2d.cxx:36
Standard_EXPORT Standard_Real LastParameter() const
Redefined method from the base class.
Definition: GEOMUtils_TrsfCurve2d.cxx:69
Geom2dAdaptor_Curve myCurve
Definition: GEOMUtils_TrsfCurve2d.hxx:241
Standard_EXPORT Standard_Boolean IsRational() const
Redefined method from the base class.
Standard_EXPORT Standard_Integer Degree() const
Redefined method from the base class.
Trsf2d myTrsf
Definition: GEOMUtils_TrsfCurve2d.hxx:242
Standard_EXPORT Standard_Integer NbIntervals(const GeomAbs_Shape S) const
Redefined method from the base class.
Definition: GEOMUtils_TrsfCurve2d.cxx:126
Standard_EXPORT Standard_Boolean IsClosed() const
Redefined method from the base class.
Standard_EXPORT gp_Circ2d Circle() const
Redefined method from the base class.
Standard_EXPORT void D1(const Standard_Real U, gp_Pnt2d &P, gp_Vec2d &V) const
Redefined method from the base class.
Standard_EXPORT gp_Vec2d DN(const Standard_Real U, const Standard_Integer N) const
Redefined method from the base class.
Standard_EXPORT gp_Hypr2d Hyperbola() const
Redefined method from the base class.
Standard_EXPORT void Intervals(TColStd_Array1OfReal &T, const GeomAbs_Shape S) const
Redefined method from the base class.
Definition: GEOMUtils_TrsfCurve2d.cxx:135
Standard_EXPORT Standard_Integer NbSamples() const
Redefined method from the base class.
Standard_EXPORT void D0(const Standard_Real U, gp_Pnt2d &P) const
Redefined method from the base class.
Standard_EXPORT Handle(Adaptor2d_HCurve2d) Trim(const Standard_Real First
Redefined method from the base class.
Standard_EXPORT Standard_Boolean IsPeriodic() const
Redefined method from the base class.
Standard_EXPORT Handle(Geom2d_BezierCurve) Bezier() const
Redefined method from the base class.
Standard_EXPORT Standard_Real Period() const
Redefined method from the base class.
Standard_EXPORT Standard_Real Resolution(const Standard_Real Ruv) const
Redefined method from the base class.
Standard_EXPORT GeomAbs_CurveType GetType() const
Redefined method from the base class.
Standard_EXPORT Handle(Geom2d_BSplineCurve) BSpline() const
Redefined method from the base class.
Standard_EXPORT gp_Parab2d Parabola() const
Redefined method from the base class.
Standard_EXPORT const Standard_Real Last
Definition: GEOMUtils_TrsfCurve2d.hxx:122
Standard_EXPORT Standard_Integer NbKnots() const
Redefined method from the base class.
Standard_EXPORT GeomAbs_Shape Continuity() const
Redefined method from the base class.
Definition: GEOMUtils_TrsfCurve2d.cxx:116
Standard_EXPORT void D2(const Standard_Real U, gp_Pnt2d &P, gp_Vec2d &V1, gp_Vec2d &V2) const
Redefined method from the base class.
Definition: GEOMUtils.hxx:56
@ Bezier
Definition: GEOM_Gen.idl:182