0033661: Data Exchange, Step Import - Tessellated GDTs are not imported
[occt.git] / src / IntPatch / IntPatch_HCurve2dTool.lxx
CommitLineData
b311480e 1// Created on: 1992-10-22
2// Created by: Laurent BUCHARD
3// Copyright (c) 1992-1999 Matra Datavision
973c2be1 4// Copyright (c) 1999-2014 OPEN CASCADE SAS
b311480e 5//
973c2be1 6// This file is part of Open CASCADE Technology software library.
b311480e 7//
d5f74e42 8// This library is free software; you can redistribute it and/or modify it under
9// the terms of the GNU Lesser General Public License version 2.1 as published
973c2be1 10// by the Free Software Foundation, with special exception defined in the file
11// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12// distribution for complete text of the license and disclaimer of any warranty.
b311480e 13//
973c2be1 14// Alternatively, this file may be used under the terms of Open CASCADE
15// commercial license or contractual agreement.
7fd59977 16
17#include <GeomAbs_CurveType.hxx>
18#include <GeomAbs_Shape.hxx>
19
20#include <gp_Vec2d.hxx>
21#include <gp_Lin2d.hxx>
22#include <gp_Circ2d.hxx>
23#include <gp_Elips2d.hxx>
24#include <gp_Parab2d.hxx>
25#include <gp_Hypr2d.hxx>
26
cb389a77 27#include <Geom2d_BezierCurve.hxx>
28#include <Geom2d_BSplineCurve.hxx>
7fd59977 29
30#include <TColStd_Array1OfReal.hxx>
31
c22b52d6 32#include <Adaptor2d_Curve2d.hxx>
7fd59977 33
34
35//============================================================
c22b52d6 36inline Standard_Real IntPatch_HCurve2dTool::FirstParameter (const Handle(Adaptor2d_Curve2d)& C) {
7fd59977 37 return(C->FirstParameter());
38}
39//============================================================
c22b52d6 40inline Standard_Real IntPatch_HCurve2dTool::LastParameter (const Handle(Adaptor2d_Curve2d)& C) {
7fd59977 41 return(C->LastParameter());
42}
43//============================================================
c22b52d6 44inline GeomAbs_Shape IntPatch_HCurve2dTool::Continuity (const Handle(Adaptor2d_Curve2d)& C) {
7fd59977 45 return(C->Continuity());
46}
47//============================================================
c22b52d6 48inline Standard_Integer IntPatch_HCurve2dTool::NbIntervals(const Handle(Adaptor2d_Curve2d)& C,const GeomAbs_Shape Sh) {
7fd59977 49 return(C->NbIntervals(Sh));
50}
51//============================================================
c22b52d6 52inline void IntPatch_HCurve2dTool::Intervals(const Handle(Adaptor2d_Curve2d)& C,
7fd59977 53 TColStd_Array1OfReal& Tab,
54 const GeomAbs_Shape Sh) {
55 C->Intervals(Tab,Sh);
56}
57//============================================================
c22b52d6 58inline Standard_Boolean IntPatch_HCurve2dTool::IsClosed(const Handle(Adaptor2d_Curve2d)& C) {
7fd59977 59 return(C->IsClosed());
60}
61//============================================================
c22b52d6 62inline Standard_Boolean IntPatch_HCurve2dTool::IsPeriodic(const Handle(Adaptor2d_Curve2d)& C) {
7fd59977 63 return(C->IsPeriodic());
64}
65//============================================================
c22b52d6 66inline Standard_Real IntPatch_HCurve2dTool::Period(const Handle(Adaptor2d_Curve2d)& C) {
7fd59977 67 return(C->Period());
68}
69//============================================================
c22b52d6 70inline gp_Pnt2d IntPatch_HCurve2dTool::Value (const Handle(Adaptor2d_Curve2d)& C,
7fd59977 71 const Standard_Real U) {
72 return(C->Value(U));
73}
74//============================================================
c22b52d6 75inline void IntPatch_HCurve2dTool::D0(const Handle(Adaptor2d_Curve2d)& C,
7fd59977 76 const Standard_Real U,
77 gp_Pnt2d& P) {
78 C->D0(U,P);
79}
80//============================================================
c22b52d6 81inline void IntPatch_HCurve2dTool::D1 (const Handle(Adaptor2d_Curve2d)& C,
7fd59977 82 const Standard_Real U,
83 gp_Pnt2d& P,
84 gp_Vec2d& T) {
85 C->D1(U,P,T);
86}
87//============================================================
c22b52d6 88inline void IntPatch_HCurve2dTool::D2 (const Handle(Adaptor2d_Curve2d)& C,
7fd59977 89 const Standard_Real U,
90 gp_Pnt2d& P,
91 gp_Vec2d& T,
92 gp_Vec2d& N) {
93 C->D2(U,P,T,N);
94}
95//============================================================
c22b52d6 96inline void IntPatch_HCurve2dTool::D3 (const Handle(Adaptor2d_Curve2d)& C,
7fd59977 97 const Standard_Real U,
98 gp_Pnt2d& P,
99 gp_Vec2d& V1,
100 gp_Vec2d& V2,
101 gp_Vec2d& V3) {
102 C->D3(U,P,V1,V2,V3);
103}
104//============================================================
c22b52d6 105inline gp_Vec2d IntPatch_HCurve2dTool::DN (const Handle(Adaptor2d_Curve2d)& C,
7fd59977 106 const Standard_Real U,
107 const Standard_Integer N) {
108 return(C->DN(U,N));
109}
110//============================================================
c22b52d6 111inline Standard_Real IntPatch_HCurve2dTool::Resolution(const Handle(Adaptor2d_Curve2d)& C,
7fd59977 112 const Standard_Real R3d) {
113 return(C->Resolution(R3d));
114}
115//============================================================
c22b52d6 116inline GeomAbs_CurveType IntPatch_HCurve2dTool::GetType(const Handle(Adaptor2d_Curve2d)& C) {
7fd59977 117 return(C->GetType());
118}
119//============================================================
c22b52d6 120inline gp_Lin2d IntPatch_HCurve2dTool::Line (const Handle(Adaptor2d_Curve2d)& C) {
7fd59977 121 return(C->Line());
122}
123//============================================================
c22b52d6 124inline gp_Circ2d IntPatch_HCurve2dTool::Circle (const Handle(Adaptor2d_Curve2d)& C) {
7fd59977 125 return(C->Circle());
126}
127//============================================================
c22b52d6 128inline gp_Elips2d IntPatch_HCurve2dTool::Ellipse (const Handle(Adaptor2d_Curve2d)& C) {
7fd59977 129 return(C->Ellipse());
130}
131//============================================================
c22b52d6 132inline gp_Parab2d IntPatch_HCurve2dTool::Parabola (const Handle(Adaptor2d_Curve2d)& C) {
7fd59977 133 return(C->Parabola());
134}
135//============================================================
c22b52d6 136inline gp_Hypr2d IntPatch_HCurve2dTool::Hyperbola (const Handle(Adaptor2d_Curve2d)& C) {
7fd59977 137 return(C->Hyperbola());
138}
139//============================================================
c22b52d6 140inline Handle(Geom2d_BezierCurve) IntPatch_HCurve2dTool::Bezier (const Handle(Adaptor2d_Curve2d)& C) {
7fd59977 141 return(C->Bezier());
142}
143//============================================================
c22b52d6 144inline Handle(Geom2d_BSplineCurve) IntPatch_HCurve2dTool::BSpline (const Handle(Adaptor2d_Curve2d)& C) {
7fd59977 145 return(C->BSpline());
146}
147//============================================================