0024624: Lost word in license statement in source files
[occt.git] / src / Adaptor3d / Adaptor3d_Surface.cdl
1 -- Created on: 1993-03-31
2 -- Created by: Bruno DUMORTIER
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 deferred class Surface from Adaptor3d 
18
19         ---Purpose: Root class for surfaces on which geometric algorithms work.
20         -- An adapted surface is an interface between the
21         -- services provided by a surface and those required of
22         -- the surface by algorithms which use it.
23         -- A derived concrete class is provided:
24         -- GeomAdaptor_Surface for a surface from the Geom package.
25         -- The  Surface class describes  the standard behaviour
26         --          of a surface for generic algorithms.
27         --          
28         --          The Surface can  be decomposed in intervals of any
29         --          continuity    in  U    and    V using  the  method
30         --          NbIntervals.  A current interval can be set.  Most
31         --          of the methods apply to the current interval.
32         --  Warning: All the methods are virtual and implemented with a
33         --          raise to allow to redefined only the methods realy
34         --          used.
35 uses
36      Array1OfReal    from TColStd,
37      Shape           from GeomAbs,
38      SurfaceType     from GeomAbs,
39      Vec             from gp,
40      Dir             from gp,
41      Pnt             from gp,
42      Pln             from gp,
43      Cone            from gp,
44      Cylinder        from gp,
45      Sphere          from gp,
46      Torus           from gp,
47      Ax1             from gp,
48      BezierSurface   from Geom,
49      BSplineSurface  from Geom,
50      HSurface        from Adaptor3d,
51      HCurve          from Adaptor3d
52
53 raises
54
55     OutOfRange          from Standard,
56     NoSuchObject        from Standard,
57     DomainError         from Standard
58  
59 is
60     
61     --
62     --     Global methods - Apply to the whole surface.
63     --     
64     
65     Delete(me:out) is virtual;
66     ---C++: alias "Standard_EXPORT virtual ~Adaptor3d_Surface(){Delete();}"
67     
68     FirstUParameter(me) returns Real
69     is virtual;
70
71     LastUParameter(me) returns Real
72     is virtual;
73     
74     FirstVParameter(me) returns Real
75     is virtual;
76
77     LastVParameter(me) returns Real
78     is virtual;
79     
80     UContinuity(me) returns Shape from GeomAbs
81     is virtual;
82     
83     VContinuity(me) returns Shape from GeomAbs
84     is virtual;
85     
86     NbUIntervals(me; S : Shape from GeomAbs) returns Integer
87         ---Purpose: Returns the number of U intervals for  continuity
88         --          <S>. May be one if UContinuity(me) >= <S>
89     is virtual;
90     
91     NbVIntervals(me; S : Shape from GeomAbs) returns Integer
92         ---Purpose: Returns the number of V intervals for  continuity
93         --          <S>. May be one if VContinuity(me) >= <S>
94     is virtual;
95     
96     UIntervals(me; T : in out Array1OfReal from TColStd; 
97                 S : Shape from GeomAbs ) 
98         ---Purpose: Returns the  intervals with the requested continuity
99         --          in the U direction.
100     raises
101         OutOfRange from Standard -- if the Length of the array does
102                                  -- have enought slots to accomodate
103                                  -- the result.
104     is virtual;
105
106     VIntervals(me; T : in out Array1OfReal from TColStd; 
107                 S : Shape from GeomAbs ) 
108         ---Purpose: Returns the  intervals with the requested continuity
109         --          in the V direction.
110     raises
111         OutOfRange from Standard -- if the Length of the array does
112                                  -- have enought slots to accomodate
113                                  -- the result.
114     is virtual;
115     
116     UTrim(me; First, Last, Tol : Real) returns HSurface from Adaptor3d
117         ---Purpose: Returns    a  surface trimmed in the U direction
118         --           equivalent   of  <me>  between
119         --          parameters <First>  and <Last>. <Tol>  is used  to
120         --          test for 3d points confusion.
121     raises
122         OutOfRange from Standard
123         ---Purpose: If <First> >= <Last> 
124     is virtual ;
125     
126     VTrim(me; First, Last, Tol : Real) returns HSurface from Adaptor3d
127         ---Purpose: Returns    a  surface trimmed in the V direction  between
128         --          parameters <First>  and <Last>. <Tol>  is used  to
129         --          test for 3d points confusion.
130     raises
131         OutOfRange from Standard
132         ---Purpose: If <First> >= <Last> 
133     is virtual ;
134
135     IsUClosed(me) returns Boolean
136     is virtual;
137      
138     IsVClosed(me) returns Boolean
139     is virtual;
140      
141     IsUPeriodic(me) returns Boolean
142     is virtual;
143     
144     UPeriod(me) returns Real
145     raises
146         DomainError from Standard -- if the curve is not periodic
147     is virtual;
148      
149     IsVPeriodic(me) returns Boolean
150     is virtual;
151     
152     VPeriod(me) returns Real
153     raises
154         DomainError from Standard -- if the curve is not periodic
155     is virtual;
156      
157     Value (me; U, V : Real)  returns Pnt from gp
158         --- Purpose : Computes the point of parameters U,V on the surface.
159     is virtual;
160
161     D0 (me; U, V : Real; P : out Pnt from gp)
162         --- Purpose : Computes the point of parameters U,V on the surface.
163     is virtual;
164
165     D1 (me; U, V : Real; P : out Pnt from gp; D1U, D1V : out Vec from gp)
166         --- Purpose : Computes the point  and the first derivatives on
167         --  the surface.
168     raises DomainError from Standard
169         --- Purpose   : Raised   if  the continuity  of   the  current
170         --  intervals is not C1.
171     is virtual;
172
173     D2 (me; U, V : Real; P : out Pnt from gp; D1U, D1V, D2U, D2V, D2UV : out Vec from gp)
174         --- Purpose  :  Computes   the point,  the  first  and  second
175         --  derivatives on the surface.
176     raises DomainError from Standard
177         --- Purpose   : Raised  if   the   continuity   of the current
178         --  intervals is not C2.
179     is virtual;
180
181     D3 (me; U, V : Real; P : out Pnt from gp; 
182             D1U, D1V, D2U, D2V, D2UV, D3U, D3V, D3UUV, D3UVV : out Vec from gp)
183         --- Purpose : Computes the point,  the first, second and third
184         --  derivatives on the surface.
185     raises DomainError from Standard
186         --- Purpose   : Raised  if   the   continuity   of the current
187         --  intervals is not C3.
188     is virtual;
189
190     DN (me; U, V : Real; Nu, Nv : Integer)   returns Vec from gp
191         --- Purpose :  Computes the derivative of order Nu in the direction U and Nv
192         --  in the direction V at the point P(U, V).
193     raises DomainError from Standard,
194         --- Purpose : Raised if the current U  interval is not not CNu
195         --  and the current V interval is not CNv.
196            OutOfRange from Standard
197         --- Purpose : Raised if Nu + Nv < 1 or Nu < 0 or Nv < 0.
198     is virtual;
199     
200     UResolution(me; R3d : Real ) returns Real
201          ---Purpose :  Returns the parametric U  resolution corresponding
202          --         to the real space resolution <R3d>.
203     is virtual;
204   
205     VResolution(me; R3d : Real ) returns Real
206          ---Purpose :  Returns the parametric V  resolution corresponding
207          --         to the real space resolution <R3d>.
208     is virtual;
209   
210     GetType(me) returns SurfaceType from GeomAbs
211         ---Purpose: Returns the type of the surface : Plane, Cylinder,
212         --          Cone,      Sphere,        Torus,    BezierSurface,
213         --          BSplineSurface,               SurfaceOfRevolution,
214         --          SurfaceOfExtrusion, OtherSurface
215     is virtual;
216     
217     --
218     --     The following methods must  be called when GetType returned
219     --     the corresponding type.
220     --     
221
222     Plane(me) returns Pln from gp
223       raises NoSuchObject from Standard
224     is virtual;
225     
226     Cylinder(me) returns Cylinder from gp
227       raises NoSuchObject from Standard
228     is virtual;
229     
230     Cone(me) returns Cone from gp
231       raises NoSuchObject from Standard
232     is virtual;
233     
234     Sphere(me) returns Sphere from gp
235       raises NoSuchObject from Standard
236     is virtual;
237     
238     Torus(me) returns Torus from gp
239       raises NoSuchObject from Standard
240     is virtual;
241
242
243     UDegree(me) returns Integer
244      raises NoSuchObject from Standard
245     is virtual;
246
247     NbUPoles(me) returns Integer
248      raises NoSuchObject from Standard
249     is virtual;
250
251     VDegree(me) returns Integer
252      raises NoSuchObject from Standard
253     is virtual;
254
255     NbVPoles(me) returns Integer
256      raises NoSuchObject from Standard
257     is virtual;
258     
259     
260     NbUKnots(me) returns Integer
261     raises 
262        NoSuchObject from Standard
263     is virtual;
264     
265     
266     NbVKnots(me) returns Integer
267     raises 
268        NoSuchObject from Standard
269     is virtual;
270     
271     
272     IsURational(me) returns Boolean
273     raises
274         NoSuchObject from Standard
275     is virtual;
276     
277     IsVRational(me) returns Boolean
278     raises
279         NoSuchObject from Standard
280     is virtual;
281     
282
283
284     Bezier(me) returns BezierSurface from Geom
285     raises 
286         NoSuchObject from Standard
287     is virtual;
288     
289     BSpline(me) returns BSplineSurface from Geom
290     raises 
291         NoSuchObject from Standard
292     is virtual;
293     
294     AxeOfRevolution(me) returns Ax1 from gp
295     raises 
296        NoSuchObject from Standard -- only for SurfaceOfRevolution
297     is virtual;
298
299     Direction(me) returns Dir from gp
300     raises 
301        NoSuchObject from Standard -- only for SurfaceOfExtrusion
302     is virtual;
303
304     BasisCurve(me) returns HCurve from Adaptor3d
305     raises 
306        NoSuchObject from Standard -- only for SurfaceOfExtrusion
307     is virtual;
308
309     BasisSurface(me) returns HSurface from Adaptor3d
310     raises 
311        NoSuchObject from Standard -- only for Offset Surface
312     is virtual;
313
314     OffsetValue(me) returns Real from Standard
315     raises 
316        NoSuchObject from Standard -- only for Offset Surface
317     is virtual;
318         
319 end Surface;
320
321
322
323
324
325
326
327