Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:03:21

0001 // Created on: 1995-04-24
0002 // Created by: Modelistation
0003 // Copyright (c) 1995-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 _ChFiDS_FilSpine_HeaderFile
0018 #define _ChFiDS_FilSpine_HeaderFile
0019 
0020 #include <ChFiDS_Spine.hxx>
0021 #include <ChFiDS_ElSpine.hxx>
0022 #include <Law_Laws.hxx>
0023 #include <TColgp_SequenceOfXY.hxx>
0024 
0025 class TopoDS_Edge;
0026 class TopoDS_Vertex;
0027 class gp_XY;
0028 class Law_Function;
0029 class Law_Composite;
0030 
0031 class ChFiDS_FilSpine;
0032 DEFINE_STANDARD_HANDLE(ChFiDS_FilSpine, ChFiDS_Spine)
0033 
0034 //! Provides  data specific to  the fillets -
0035 //! vector or rule  of evolution (C2).
0036 class ChFiDS_FilSpine : public ChFiDS_Spine
0037 {
0038 
0039 public:
0040 
0041   
0042   Standard_EXPORT ChFiDS_FilSpine();
0043   
0044   Standard_EXPORT ChFiDS_FilSpine(const Standard_Real Tol);
0045   
0046   Standard_EXPORT virtual void Reset (const Standard_Boolean AllData = Standard_False) Standard_OVERRIDE;
0047   
0048   //! initializes the constant vector on edge E.
0049   Standard_EXPORT void SetRadius (const Standard_Real Radius, const TopoDS_Edge& E);
0050   
0051   //! resets the constant vector  on   edge E.
0052   Standard_EXPORT void UnSetRadius (const TopoDS_Edge& E);
0053   
0054   //! initializes the  vector on Vertex V.
0055   Standard_EXPORT void SetRadius (const Standard_Real Radius, const TopoDS_Vertex& V);
0056   
0057   //! resets the vector on Vertex V.
0058   Standard_EXPORT void UnSetRadius (const TopoDS_Vertex& V);
0059   
0060   //! initializes the vector on the point of parameter W.
0061   Standard_EXPORT void SetRadius (const gp_XY& UandR, const Standard_Integer IinC);
0062   
0063   //! initializes the constant vector on all spine.
0064   Standard_EXPORT void SetRadius (const Standard_Real Radius);
0065   
0066   //! initializes the rule of evolution on all spine.
0067   Standard_EXPORT void SetRadius (const Handle(Law_Function)& C, const Standard_Integer IinC);
0068   
0069   //! returns true if the radius is constant
0070   //! all along the spine.
0071   Standard_EXPORT Standard_Boolean IsConstant() const;
0072   
0073   //! returns true if the radius is constant
0074   //! all along the edge E.
0075   Standard_EXPORT Standard_Boolean IsConstant (const Standard_Integer IE) const;
0076   
0077   //! returns the radius if the fillet is constant
0078   //! all along the spine.
0079   Standard_EXPORT Standard_Real Radius() const;
0080   
0081   //! returns the radius if the fillet is constant
0082   //! all along the edge E.
0083   Standard_EXPORT Standard_Real Radius (const Standard_Integer IE) const;
0084   
0085   //! returns the radius if the fillet is constant
0086   //! all along the edge E.
0087   Standard_EXPORT Standard_Real Radius (const TopoDS_Edge& E) const;
0088   
0089   Standard_EXPORT virtual void AppendElSpine (const Handle(ChFiDS_ElSpine)& Els) Standard_OVERRIDE;
0090   
0091   Standard_EXPORT Handle(Law_Composite) Law (const Handle(ChFiDS_ElSpine)& Els) const;
0092   
0093   //! returns the elementary law
0094   Standard_EXPORT Handle(Law_Function)& ChangeLaw (const TopoDS_Edge& E);
0095   
0096   //! returns the maximum radius if the fillet is non-constant
0097   Standard_EXPORT Standard_Real MaxRadFromSeqAndLaws() const;
0098 
0099 
0100 
0101 
0102   DEFINE_STANDARD_RTTIEXT(ChFiDS_FilSpine,ChFiDS_Spine)
0103 
0104 protected:
0105 
0106 
0107 
0108 
0109 private:
0110 
0111   
0112   Standard_EXPORT Handle(Law_Composite) ComputeLaw (const Handle(ChFiDS_ElSpine)& Els);
0113   
0114   Standard_EXPORT void AppendLaw (const Handle(ChFiDS_ElSpine)& Els);
0115 
0116   TColgp_SequenceOfXY parandrad;
0117   Law_Laws laws;
0118 
0119 
0120 };
0121 
0122 
0123 
0124 
0125 
0126 
0127 
0128 #endif // _ChFiDS_FilSpine_HeaderFile