Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-06-05 08:33:53

0001 // Created on: 1992-09-28
0002 // Created by: Remi GILET
0003 // Copyright (c) 1992-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 _GC_MakeArcOfParabola_HeaderFile
0018 #define _GC_MakeArcOfParabola_HeaderFile
0019 
0020 #include <Standard.hxx>
0021 #include <Standard_DefineAlloc.hxx>
0022 #include <Standard_Handle.hxx>
0023 
0024 #include <GC_Root.hxx>
0025 #include <Geom_TrimmedCurve.hxx>
0026 
0027 class gp_Parab;
0028 class gp_Pnt;
0029 
0030 //! Implements construction algorithms for an arc
0031 //! of parabola in 3D space. The result is a Geom_TrimmedCurve curve.
0032 //! A MakeArcOfParabola object provides a framework for:
0033 //! -   defining the construction of the arc of parabola,
0034 //! -   implementing the construction algorithm, and
0035 //! -   consulting the results. In particular, the
0036 //! Value function returns the constructed arc of parabola.
0037 class GC_MakeArcOfParabola : public GC_Root
0038 {
0039 public:
0040   DEFINE_STANDARD_ALLOC
0041 
0042   //! Creates an arc of Parabola (TrimmedCurve from Geom) from
0043   //! a Parabola between two parameters Alpha1 and Alpha2
0044   //! (given in radians).
0045   Standard_EXPORT GC_MakeArcOfParabola(const gp_Parab&        Parab,
0046                                        const Standard_Real    Alpha1,
0047                                        const Standard_Real    Alpha2,
0048                                        const Standard_Boolean Sense);
0049 
0050   //! Creates an arc of Parabola (TrimmedCurve from Geom) from
0051   //! a Parabola between point <P> and the parameter
0052   //! Alpha (given in radians).
0053   Standard_EXPORT GC_MakeArcOfParabola(const gp_Parab&        Parab,
0054                                        const gp_Pnt&          P,
0055                                        const Standard_Real    Alpha,
0056                                        const Standard_Boolean Sense);
0057 
0058   //! Creates an arc of Parabola (TrimmedCurve from Geom) from
0059   //! a Parabola between two points P1 and P2.
0060   Standard_EXPORT GC_MakeArcOfParabola(const gp_Parab&        Parab,
0061                                        const gp_Pnt&          P1,
0062                                        const gp_Pnt&          P2,
0063                                        const Standard_Boolean Sense);
0064 
0065   //! Returns the constructed arc of parabola.
0066   Standard_EXPORT const Handle(Geom_TrimmedCurve)& Value() const;
0067 
0068   operator const Handle(Geom_TrimmedCurve) & () const { return Value(); }
0069 
0070 private:
0071   Handle(Geom_TrimmedCurve) TheArc;
0072 };
0073 
0074 #endif // _GC_MakeArcOfParabola_HeaderFile