Back to home page

EIC code displayed by LXR

 
 

    


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

0001 // Created on: 1995-01-27
0002 // Created by: Jacques GOUSSARD
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 _GeomInt_TheMultiLineToolOfWLApprox_HeaderFile
0018 #define _GeomInt_TheMultiLineToolOfWLApprox_HeaderFile
0019 
0020 #include <Standard.hxx>
0021 #include <Standard_DefineAlloc.hxx>
0022 #include <Standard_Handle.hxx>
0023 
0024 #include <TColgp_Array1OfPnt.hxx>
0025 #include <Standard_Boolean.hxx>
0026 class GeomInt_TheMultiLineOfWLApprox;
0027 class ApproxInt_SvSurfaces;
0028 
0029 
0030 
0031 class GeomInt_TheMultiLineToolOfWLApprox 
0032 {
0033 public:
0034 
0035   DEFINE_STANDARD_ALLOC
0036 
0037   
0038   //! Returns the number of multipoints of the TheMultiLine.
0039     static Standard_Integer FirstPoint (const GeomInt_TheMultiLineOfWLApprox& ML);
0040   
0041   //! Returns the number of multipoints of the TheMultiLine.
0042     static Standard_Integer LastPoint (const GeomInt_TheMultiLineOfWLApprox& ML);
0043   
0044   //! Returns the number of 2d points of a TheMultiLine.
0045     static Standard_Integer NbP2d (const GeomInt_TheMultiLineOfWLApprox& ML);
0046   
0047   //! Returns the number of 3d points of a TheMultiLine.
0048     static Standard_Integer NbP3d (const GeomInt_TheMultiLineOfWLApprox& ML);
0049   
0050   //! returns the 3d points of the multipoint <MPointIndex>
0051   //! when only 3d points exist.
0052     static void Value (const GeomInt_TheMultiLineOfWLApprox& ML, const Standard_Integer MPointIndex, TColgp_Array1OfPnt& tabPt);
0053   
0054   //! returns the 2d points of the multipoint <MPointIndex>
0055   //! when only 2d points exist.
0056     static void Value (const GeomInt_TheMultiLineOfWLApprox& ML, const Standard_Integer MPointIndex, TColgp_Array1OfPnt2d& tabPt2d);
0057   
0058   //! returns the 3d and 2d points of the multipoint
0059   //! <MPointIndex>.
0060     static void Value (const GeomInt_TheMultiLineOfWLApprox& ML, const Standard_Integer MPointIndex, TColgp_Array1OfPnt& tabPt, TColgp_Array1OfPnt2d& tabPt2d);
0061   
0062   //! returns the 3d points of the multipoint <MPointIndex>
0063   //! when only 3d points exist.
0064     static Standard_Boolean Tangency (const GeomInt_TheMultiLineOfWLApprox& ML, const Standard_Integer MPointIndex, TColgp_Array1OfVec& tabV);
0065   
0066   //! returns the 2d tangency points of the multipoint
0067   //! <MPointIndex> only when 2d points exist.
0068     static Standard_Boolean Tangency (const GeomInt_TheMultiLineOfWLApprox& ML, const Standard_Integer MPointIndex, TColgp_Array1OfVec2d& tabV2d);
0069   
0070   //! returns the 3d and 2d points of the multipoint
0071   //! <MPointIndex>.
0072     static Standard_Boolean Tangency (const GeomInt_TheMultiLineOfWLApprox& ML, const Standard_Integer MPointIndex, TColgp_Array1OfVec& tabV, TColgp_Array1OfVec2d& tabV2d);
0073   
0074   //! returns the 3d curvature of the multipoint <MPointIndex>
0075   //! when only 3d points exist.
0076     static Standard_Boolean Curvature (const GeomInt_TheMultiLineOfWLApprox& ML, const Standard_Integer MPointIndex, TColgp_Array1OfVec& tabV);
0077   
0078   //! returns the 2d curvature points of the multipoint
0079   //! <MPointIndex> only when 2d points exist.
0080     static Standard_Boolean Curvature (const GeomInt_TheMultiLineOfWLApprox& ML, const Standard_Integer MPointIndex, TColgp_Array1OfVec2d& tabV2d);
0081   
0082   //! returns the 3d and 2d curvature of the multipoint
0083   //! <MPointIndex>.
0084     static Standard_Boolean Curvature (const GeomInt_TheMultiLineOfWLApprox& ML, const Standard_Integer MPointIndex, TColgp_Array1OfVec& tabV, TColgp_Array1OfVec2d& tabV2d);
0085   
0086   //! Is called if WhatStatus returned "PointsAdded".
0087     static GeomInt_TheMultiLineOfWLApprox MakeMLBetween (const GeomInt_TheMultiLineOfWLApprox& ML, const Standard_Integer I1, const Standard_Integer I2, const Standard_Integer NbPMin);
0088   
0089   //! Is called when the Bezier curve contains a loop
0090     static Standard_Boolean MakeMLOneMorePoint (const GeomInt_TheMultiLineOfWLApprox& ML,
0091                                                 const Standard_Integer I1,
0092                                                 const Standard_Integer I2,
0093                                                 const Standard_Integer indbad,
0094                                                 GeomInt_TheMultiLineOfWLApprox& OtherLine);
0095   
0096     static Approx_Status WhatStatus (const GeomInt_TheMultiLineOfWLApprox& ML, const Standard_Integer I1, const Standard_Integer I2);
0097   
0098   //! Dump of the current multi-line.
0099   static void Dump (const GeomInt_TheMultiLineOfWLApprox& ML);
0100 
0101 
0102 
0103 
0104 protected:
0105 
0106 
0107 
0108 
0109 
0110 private:
0111 
0112 
0113 
0114 
0115 
0116 };
0117 
0118 #define TheMultiLine GeomInt_TheMultiLineOfWLApprox
0119 #define TheMultiLine_hxx <GeomInt_TheMultiLineOfWLApprox.hxx>
0120 #define TheMultiMPoint ApproxInt_SvSurfaces
0121 #define TheMultiMPoint_hxx <ApproxInt_SvSurfaces.hxx>
0122 #define ApproxInt_MultiLineTool GeomInt_TheMultiLineToolOfWLApprox
0123 #define ApproxInt_MultiLineTool_hxx <GeomInt_TheMultiLineToolOfWLApprox.hxx>
0124 
0125 #include <ApproxInt_MultiLineTool.lxx>
0126 
0127 #undef TheMultiLine
0128 #undef TheMultiLine_hxx
0129 #undef TheMultiMPoint
0130 #undef TheMultiMPoint_hxx
0131 #undef ApproxInt_MultiLineTool
0132 #undef ApproxInt_MultiLineTool_hxx
0133 
0134 
0135 
0136 
0137 #endif // _GeomInt_TheMultiLineToolOfWLApprox_HeaderFile