1 // Created on: 2002-08-02
2 // Created by: Alexander KARTOMIN  (akm)
3 // Copyright (c) 2002-2014 OPEN CASCADE SAS
4 //
5 // This file is part of Open CASCADE Technology software library.
6 //
7 // This library is free software; you can redistribute it and/or modify it under
8 // the terms of the GNU Lesser General Public License version 2.1 as published
9 // by the Free Software Foundation, with special exception defined in the file
10 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
11 // distribution for complete text of the license and disclaimer of any warranty.
12 //
13 // Alternatively, this file may be used under the terms of Open CASCADE
14 // commercial license or contractual agreement.
15 
16 #ifndef _LProp3d_CurveTool_HeaderFile
17 #define _LProp3d_CurveTool_HeaderFile
18 
19 #include <Standard.hxx>
20 #include <Standard_DefineAlloc.hxx>
21 #include <Standard_Handle.hxx>
22 
23 #include <Standard_Real.hxx>
24 #include <Standard_Integer.hxx>
25 
26 class gp_Pnt;
27 class gp_Vec;
28 
29 
30 
31 class LProp3d_CurveTool
32 {
33 public:
34 
35   DEFINE_STANDARD_ALLOC
36 
37 
38   //! Computes the point <P> of parameter <U> on the HCurve <C>.
39   Standard_EXPORT static void Value (const Handle(Adaptor3d_Curve)& C, const Standard_Real U, gp_Pnt& P);
40 
41   //! Computes the point <P> and first derivative <V1> of
42   //! parameter <U> on the HCurve <C>.
43   Standard_EXPORT static void D1 (const Handle(Adaptor3d_Curve)& C, const Standard_Real U, gp_Pnt& P, gp_Vec& V1);
44 
45   //! Computes the point <P>, the first derivative <V1> and second
46   //! derivative <V2> of parameter <U> on the HCurve <C>.
47   Standard_EXPORT static void D2 (const Handle(Adaptor3d_Curve)& C, const Standard_Real U, gp_Pnt& P, gp_Vec& V1, gp_Vec& V2);
48 
49   //! Computes the point <P>, the first derivative <V1>, the
50   //! second derivative <V2> and third derivative <V3> of
51   //! parameter <U> on the HCurve <C>.
52   Standard_EXPORT static void D3 (const Handle(Adaptor3d_Curve)& C, const Standard_Real U, gp_Pnt& P, gp_Vec& V1, gp_Vec& V2, gp_Vec& V3);
53 
54   //! returns the order of continuity of the HCurve <C>.
55   //! returns 1 : first derivative only is computable
56   //! returns 2 : first and second derivative only are computable.
57   //! returns 3 : first, second and third are computable.
58   Standard_EXPORT static Standard_Integer Continuity (const Handle(Adaptor3d_Curve)& C);
59 
60   //! returns the first parameter bound of the HCurve.
61   Standard_EXPORT static Standard_Real FirstParameter (const Handle(Adaptor3d_Curve)& C);
62 
63   //! returns the last parameter bound of the HCurve.
64   //! FirstParameter must be less than LastParamenter.
65   Standard_EXPORT static Standard_Real LastParameter (const Handle(Adaptor3d_Curve)& C);
66 
67 
68 
69 
70 protected:
71 
72 
73 
74 
75 
76 private:
77 
78 
79 
80 
81 
82 };
83 
84 
85 
86 
87 
88 
89 
90 #endif // _LProp3d_CurveTool_HeaderFile
91