Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:04:09

0001 // Created on: 2015-02-18
0002 // Created by: Nikolai BUKHALOV
0003 // Copyright (c) 1992-1999 Matra Datavision
0004 // Copyright (c) 1999-2015 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 _IntPatch_PointLine_HeaderFile
0018 #define _IntPatch_PointLine_HeaderFile
0019 
0020 #include <Adaptor3d_Surface.hxx>
0021 #include <IntPatch_Line.hxx>
0022 
0023 class gp_Pnt;
0024 class gp_Pnt2d;
0025 class IntSurf_PntOn2S;
0026 class IntSurf_LineOn2S;
0027 class IntPatch_Point;
0028 
0029 DEFINE_STANDARD_HANDLE(IntPatch_PointLine, IntPatch_Line)
0030 
0031 //! Definition of an intersection line between two
0032 //! surfaces.
0033 //! A line defined by a set of points
0034 //! (e.g. coming from a walking algorithm) as
0035 //! defined in the class WLine or RLine (Restriction line).
0036 class IntPatch_PointLine : public IntPatch_Line
0037 {
0038 public:
0039 
0040   //! Adds a vertex in the list. If theIsPrepend == TRUE the new
0041   //! vertex will be added before the first element of vertices sequence.
0042   //! Otherwise, to the end of the sequence
0043   Standard_EXPORT virtual
0044             void AddVertex (const IntPatch_Point& Pnt,
0045                             const Standard_Boolean theIsPrepend = Standard_False) = 0;
0046 
0047   //! Returns the number of intersection points.
0048   Standard_EXPORT virtual Standard_Integer NbPnts() const = 0;
0049 
0050   //! Returns number of vertices (IntPatch_Point) of the line
0051   Standard_EXPORT virtual Standard_Integer NbVertex() const = 0;
0052 
0053   //! Returns the intersection point of range Index.
0054   Standard_EXPORT virtual const IntSurf_PntOn2S& Point (const Standard_Integer Index) const = 0;
0055 
0056   //! Returns the vertex of range Index on the line.
0057   Standard_EXPORT virtual const IntPatch_Point& Vertex (const Standard_Integer Index) const = 0;
0058 
0059   //! Returns the vertex of range Index on the line.
0060   virtual IntPatch_Point& ChangeVertex (const Standard_Integer Index) = 0;
0061 
0062   //! Removes vertices from the line
0063   Standard_EXPORT virtual void ClearVertexes() = 0;
0064 
0065   //! Removes single vertex from the line
0066   Standard_EXPORT virtual void RemoveVertex (const Standard_Integer theIndex) = 0;
0067 
0068   //! Returns set of intersection points
0069   Standard_EXPORT virtual Handle(IntSurf_LineOn2S) Curve() const = 0;
0070 
0071   //! Returns TRUE if P1 is out of the box built from
0072   //! the points on 1st surface
0073   Standard_EXPORT virtual Standard_Boolean IsOutSurf1Box(const gp_Pnt2d& P1) const = 0;
0074 
0075   //! Returns TRUE if P2 is out of the box built from
0076   //! the points on 2nd surface
0077   Standard_EXPORT virtual Standard_Boolean IsOutSurf2Box(const gp_Pnt2d& P2) const = 0;
0078 
0079   //! Returns TRUE if P is out of the box built from 3D-points.
0080   Standard_EXPORT virtual Standard_Boolean IsOutBox(const gp_Pnt& P) const = 0;
0081 
0082   //! Returns the radius of curvature of
0083   //! the intersection line in given point.
0084   //! Returns negative value if computation is not possible.
0085   Standard_EXPORT static Standard_Real
0086             CurvatureRadiusOfIntersLine(const Handle(Adaptor3d_Surface)& theS1,
0087                                         const Handle(Adaptor3d_Surface)& theS2,
0088                                         const IntSurf_PntOn2S& theUVPoint);
0089 
0090   DEFINE_STANDARD_RTTIEXT(IntPatch_PointLine,IntPatch_Line)
0091 
0092 protected:
0093 
0094   
0095   //! To initialize the fields, when the transitions
0096   //! are In or Out.
0097   Standard_EXPORT IntPatch_PointLine(const Standard_Boolean Tang, const IntSurf_TypeTrans Trans1, const IntSurf_TypeTrans Trans2);
0098   
0099   //! To initialize the fields, when the transitions
0100   //! are Touch.
0101   Standard_EXPORT IntPatch_PointLine(const Standard_Boolean Tang, const IntSurf_Situation Situ1, const IntSurf_Situation Situ2);
0102   
0103   //! To initialize the fields, when the transitions
0104   //! are Undecided.
0105   Standard_EXPORT IntPatch_PointLine(const Standard_Boolean Tang);
0106 
0107 
0108 
0109 private:
0110 
0111 
0112 
0113 
0114 };
0115 
0116 
0117 
0118 
0119 
0120 
0121 
0122 #endif // _IntPatch_PointLine_HeaderFile