0028966: Coding Rules - remove Adaptor2d_HCurve2d, Adaptor3d_HCurve and Adaptor3d_HSu...
[occt.git] / src / Adaptor3d / Adaptor3d_HSurfaceTool.hxx
CommitLineData
42cf5bc1 1// Created on: 1993-07-02
2// Created by: Laurent BUCHARD
3// Copyright (c) 1993-1999 Matra Datavision
4// Copyright (c) 1999-2014 OPEN CASCADE SAS
5//
6// This file is part of Open CASCADE Technology software library.
7//
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
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.
13//
14// Alternatively, this file may be used under the terms of Open CASCADE
15// commercial license or contractual agreement.
16
17#ifndef _Adaptor3d_HSurfaceTool_HeaderFile
18#define _Adaptor3d_HSurfaceTool_HeaderFile
19
c22b52d6 20#include <Adaptor3d_Surface.hxx>
21#include <Adaptor3d_Curve.hxx>
22#include <Geom_BezierSurface.hxx>
23#include <Geom_BSplineSurface.hxx>
42cf5bc1 24#include <GeomAbs_Shape.hxx>
42cf5bc1 25#include <GeomAbs_SurfaceType.hxx>
c22b52d6 26#include <gp_Ax1.hxx>
27#include <gp_Dir.hxx>
42cf5bc1 28#include <gp_Cylinder.hxx>
29#include <gp_Cone.hxx>
c22b52d6 30#include <gp_Pln.hxx>
31#include <gp_Pnt.hxx>
42cf5bc1 32#include <gp_Sphere.hxx>
c22b52d6 33#include <gp_Torus.hxx>
34#include <gp_Vec.hxx>
35#include <Standard.hxx>
36#include <Standard_DefineAlloc.hxx>
37#include <Standard_Handle.hxx>
38#include <Standard_Boolean.hxx>
39#include <TColStd_Array1OfReal.hxx>
42cf5bc1 40
41class Adaptor3d_HSurfaceTool
42{
43public:
44
45 DEFINE_STANDARD_ALLOC
46
c22b52d6 47 static Standard_Real FirstUParameter (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->FirstUParameter(); }
48
49 static Standard_Real FirstVParameter (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->FirstVParameter(); }
50
51 static Standard_Real LastUParameter (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->LastUParameter(); }
52
53 static Standard_Real LastVParameter (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->LastVParameter(); }
54
55 static Standard_Integer NbUIntervals (const Handle(Adaptor3d_Surface)& theSurf, const GeomAbs_Shape theSh) { return theSurf->NbUIntervals (theSh); }
56
57 static Standard_Integer NbVIntervals (const Handle(Adaptor3d_Surface)& theSurf, const GeomAbs_Shape theSh) { return theSurf->NbVIntervals (theSh); }
58
59 static void UIntervals (const Handle(Adaptor3d_Surface)& theSurf, TColStd_Array1OfReal& theTab, const GeomAbs_Shape theSh) { theSurf->UIntervals (theTab, theSh); }
60
61 static void VIntervals (const Handle(Adaptor3d_Surface)& theSurf, TColStd_Array1OfReal& theTab, const GeomAbs_Shape theSh) { theSurf->VIntervals (theTab, theSh); }
62
42cf5bc1 63 //! If <First> >= <Last>
c22b52d6 64 static Handle(Adaptor3d_Surface) UTrim (const Handle(Adaptor3d_Surface)& theSurf,
65 const Standard_Real theFirst, const Standard_Real theLast, const Standard_Real theTol)
66 {
67 return theSurf->UTrim (theFirst, theLast, theTol);
68 }
69
42cf5bc1 70 //! If <First> >= <Last>
c22b52d6 71 static Handle(Adaptor3d_Surface) VTrim (const Handle(Adaptor3d_Surface)& theSurf,
72 const Standard_Real theFirst, const Standard_Real theLast, const Standard_Real theTol)
73 {
74 return theSurf->VTrim (theFirst, theLast, theTol);
75 }
42cf5bc1 76
c22b52d6 77 static Standard_Boolean IsUClosed (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->IsUClosed(); }
78
79 static Standard_Boolean IsVClosed (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->IsVClosed(); }
42cf5bc1 80
c22b52d6 81 static Standard_Boolean IsUPeriodic (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->IsUPeriodic(); }
82
83 static Standard_Real UPeriod (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->UPeriod(); }
84
85 static Standard_Boolean IsVPeriodic (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->IsVPeriodic(); }
42cf5bc1 86
c22b52d6 87 static Standard_Real VPeriod (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->VPeriod(); }
42cf5bc1 88
c22b52d6 89 static gp_Pnt Value (const Handle(Adaptor3d_Surface)& theSurf, const Standard_Real theU, const Standard_Real theV) { return theSurf->Value (theU, theV); }
42cf5bc1 90
c22b52d6 91 static void D0 (const Handle(Adaptor3d_Surface)& theSurf,
92 const Standard_Real theU, const Standard_Real theV,
93 gp_Pnt& thePnt)
94 {
95 theSurf->D0 (theU, theV, thePnt);
96 }
42cf5bc1 97
c22b52d6 98 static void D1 (const Handle(Adaptor3d_Surface)& theSurf,
99 const Standard_Real theU, const Standard_Real theV,
100 gp_Pnt& thePnt,
101 gp_Vec& theD1U, gp_Vec& theD1V)
102 {
103 theSurf->D1 (theU, theV, thePnt, theD1U, theD1V);
104 }
42cf5bc1 105
c22b52d6 106 static void D2 (const Handle(Adaptor3d_Surface)& theSurf,
107 const Standard_Real theU, const Standard_Real theV,
108 gp_Pnt& thePnt,
109 gp_Vec& theD1U, gp_Vec& theD1V,
110 gp_Vec& theD2U, gp_Vec& theD2V, gp_Vec& theD2UV)
111 {
112 theSurf->D2 (theU, theV, thePnt, theD1U, theD1V, theD2U, theD2V, theD2UV);
113 }
42cf5bc1 114
c22b52d6 115 static void D3 (const Handle(Adaptor3d_Surface)& theSurf,
116 const Standard_Real theU, const Standard_Real theV,
117 gp_Pnt& thePnt,
118 gp_Vec& theD1U, gp_Vec& theD1V,
119 gp_Vec& theD2U, gp_Vec& theD2V, gp_Vec& theD2UV,
120 gp_Vec& theD3U, gp_Vec& theD3V, gp_Vec& theD3UUV, gp_Vec& theD3UVV)
121 {
122 theSurf->D3 (theU, theV, thePnt, theD1U, theD1V, theD2U, theD2V, theD2UV, theD3U, theD3V, theD3UUV, theD3UVV);
123 }
42cf5bc1 124
c22b52d6 125 static gp_Vec DN (const Handle(Adaptor3d_Surface)& theSurf,
126 const Standard_Real theU, const Standard_Real theV,
127 const Standard_Integer theNU, const Standard_Integer theNV)
128 {
129 return theSurf->DN (theU, theV, theNU, theNV);
130 }
42cf5bc1 131
c22b52d6 132 static Standard_Real UResolution (const Handle(Adaptor3d_Surface)& theSurf, const Standard_Real theR3d)
133 {
134 return theSurf->UResolution (theR3d);
135 }
42cf5bc1 136
c22b52d6 137 static Standard_Real VResolution (const Handle(Adaptor3d_Surface)& theSurf, const Standard_Real theR3d)
138 {
139 return theSurf->VResolution (theR3d);
140 }
42cf5bc1 141
c22b52d6 142 static GeomAbs_SurfaceType GetType (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->GetType(); }
42cf5bc1 143
c22b52d6 144 static gp_Pln Plane (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->Plane(); }
42cf5bc1 145
c22b52d6 146 static gp_Cylinder Cylinder (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->Cylinder(); }
42cf5bc1 147
c22b52d6 148 static gp_Cone Cone (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->Cone(); }
42cf5bc1 149
c22b52d6 150 static gp_Torus Torus (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->Torus(); }
42cf5bc1 151
c22b52d6 152 static gp_Sphere Sphere (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->Sphere(); }
153
154 static Handle(Geom_BezierSurface) Bezier (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->Bezier(); }
155
156 static Handle(Geom_BSplineSurface) BSpline (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->BSpline(); }
42cf5bc1 157
c22b52d6 158 static gp_Ax1 AxeOfRevolution (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->AxeOfRevolution(); }
42cf5bc1 159
c22b52d6 160 static gp_Dir Direction (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->Direction(); }
42cf5bc1 161
c22b52d6 162 static Handle(Adaptor3d_Curve) BasisCurve (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->BasisCurve(); }
42cf5bc1 163
c22b52d6 164 static Handle(Adaptor3d_Surface) BasisSurface (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->BasisSurface(); }
42cf5bc1 165
c22b52d6 166 static Standard_Real OffsetValue (const Handle(Adaptor3d_Surface)& theSurf) { return theSurf->OffsetValue(); }
42cf5bc1 167
c22b52d6 168 Standard_EXPORT static Standard_Integer NbSamplesU (const Handle(Adaptor3d_Surface)& S);
169
170 Standard_EXPORT static Standard_Integer NbSamplesV (const Handle(Adaptor3d_Surface)& S);
171
172 Standard_EXPORT static Standard_Integer NbSamplesU (const Handle(Adaptor3d_Surface)& S, const Standard_Real u1, const Standard_Real u2);
173
174 Standard_EXPORT static Standard_Integer NbSamplesV (const Handle(Adaptor3d_Surface)& , const Standard_Real v1, const Standard_Real v2);
175
176};
42cf5bc1 177
178#endif // _Adaptor3d_HSurfaceTool_HeaderFile