Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-05-20 08:17:09

0001 // Created on: 1997-02-18
0002 // Created by: Stagiaire Francois DUMONT
0003 // Copyright (c) 1997-1999 Matra Datavision
0004 // Copyright (c) 1999-2014 OPEN CASCADE SAS
0005 //
0006 // This file is part of Open CASCADE Technology software library.
0007 //
0008 // This library is free software; you can redistribute it and/or modify it under
0009 // the terms of the GNU Lesser General Public License version 2.1 as published
0010 // by the Free Software Foundation, with special exception defined in the file
0011 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
0012 // distribution for complete text of the license and disclaimer of any warranty.
0013 //
0014 // Alternatively, this file may be used under the terms of Open CASCADE
0015 // commercial license or contractual agreement.
0016 
0017 #ifndef _Hermit_HeaderFile
0018 #define _Hermit_HeaderFile
0019 
0020 #include <Standard.hxx>
0021 #include <Standard_DefineAlloc.hxx>
0022 #include <Standard_Handle.hxx>
0023 
0024 class Geom2d_BSplineCurve;
0025 class Geom_BSplineCurve;
0026 
0027 //! This  is used to  reparameterize Rational  BSpline
0028 //! Curves so that we can   concatenate them later to
0029 //! build C1 Curves  It builds and 1D-reparameterizing
0030 //! function starting from an Hermite interpolation and
0031 //! adding knots and modifying poles of the 1D BSpline
0032 //! obtained that way. The goal is to build a(u) so that
0033 //! if we consider a BSpline curve
0034 //! N(u)
0035 //! f(u) =  -----
0036 //! D(u)
0037 //!
0038 //! the function a(u)D(u) has value 1 at the umin and umax
0039 //! and has 0.0e0 derivative value a umin and umax.
0040 //! The details of the computation occurring in this package
0041 //! can be found by reading :
0042 //! " Etude sur la concatenation de NURBS en vue du
0043 //! balayage de surfaces" PFE n S85 Ensam Lille
0044 class Hermit
0045 {
0046 public:
0047   DEFINE_STANDARD_ALLOC
0048 
0049   //! returns the correct spline a(u) which will
0050   //! be multiplicated with BS later.
0051   Standard_EXPORT static Handle(Geom2d_BSplineCurve) Solution(
0052     const Handle(Geom_BSplineCurve)& BS,
0053     const Standard_Real              TolPoles = 0.000001,
0054     const Standard_Real              TolKnots = 0.000001);
0055 
0056   //! returns the correct spline a(u) which will
0057   //! be multiplicated with BS later.
0058   Standard_EXPORT static Handle(Geom2d_BSplineCurve) Solution(
0059     const Handle(Geom2d_BSplineCurve)& BS,
0060     const Standard_Real                TolPoles = 0.000001,
0061     const Standard_Real                TolKnots = 0.000001);
0062 
0063   //! returns the knots to insert to a(u) to
0064   //! stay with a constant sign and in the
0065   //! tolerances.
0066   Standard_EXPORT static void Solutionbis(const Handle(Geom_BSplineCurve)& BS,
0067                                           Standard_Real&                   Knotmin,
0068                                           Standard_Real&                   Knotmax,
0069                                           const Standard_Real              TolPoles = 0.000001,
0070                                           const Standard_Real              TolKnots = 0.000001);
0071 };
0072 
0073 #endif // _Hermit_HeaderFile