Back to home page

EIC code displayed by LXR

 
 

    


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

0001 // Created on: 1993-02-22
0002 // Created by: Jacques GOUSSARD
0003 // Copyright (c) 1993-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 _IntSurf_LineOn2S_HeaderFile
0018 #define _IntSurf_LineOn2S_HeaderFile
0019 
0020 #include <Standard.hxx>
0021 
0022 #include <Bnd_Box.hxx>
0023 #include <Bnd_Box2d.hxx>
0024 #include <IntSurf_SequenceOfPntOn2S.hxx>
0025 #include <Standard_Transient.hxx>
0026 #include <IntSurf_Allocator.hxx>
0027 #include <Standard_Integer.hxx>
0028 #include <Standard_Real.hxx>
0029 class IntSurf_PntOn2S;
0030 
0031 
0032 class IntSurf_LineOn2S;
0033 DEFINE_STANDARD_HANDLE(IntSurf_LineOn2S, Standard_Transient)
0034 
0035 
0036 class IntSurf_LineOn2S : public Standard_Transient
0037 {
0038 
0039 public:
0040 
0041   
0042   Standard_EXPORT IntSurf_LineOn2S(const IntSurf_Allocator& theAllocator = 0);
0043   
0044   //! Adds a point in the line.
0045   Standard_EXPORT void Add(const IntSurf_PntOn2S& P);
0046   
0047   //! Returns the number of points in the line.
0048     Standard_Integer NbPoints() const;
0049   
0050   //! Returns the point of range Index in the line.
0051     const IntSurf_PntOn2S& Value (const Standard_Integer Index) const;
0052   
0053   //! Reverses the order of points of the line.
0054     void Reverse();
0055   
0056   //! Keeps in <me> the points 1 to Index-1, and returns
0057   //! the items Index to the end.
0058   Standard_EXPORT Handle(IntSurf_LineOn2S) Split (const Standard_Integer Index);
0059   
0060   //! Replaces the point of range Index in the line.
0061     void Value (const Standard_Integer Index, const IntSurf_PntOn2S& P);
0062   
0063   //! Sets the 3D point of the Index-th PntOn2S
0064   Standard_EXPORT void SetPoint(const Standard_Integer Index, const gp_Pnt& thePnt);
0065   
0066   //! Sets the parametric coordinates on one of the surfaces
0067   //! of the point of range Index in the line.
0068   Standard_EXPORT void SetUV(const Standard_Integer Index,
0069                              const Standard_Boolean OnFirst,
0070                              const Standard_Real U, const Standard_Real V);
0071   
0072     void Clear();
0073   
0074   Standard_EXPORT void InsertBefore (const Standard_Integer I, const IntSurf_PntOn2S& P);
0075   
0076   Standard_EXPORT void RemovePoint (const Standard_Integer I);
0077 
0078   //! Returns TRUE if theP is out of the box built from
0079   //! the points on 1st surface
0080   Standard_EXPORT Standard_Boolean IsOutSurf1Box(const gp_Pnt2d& theP);
0081 
0082   //! Returns TRUE if theP is out of the box built from
0083   //! the points on 2nd surface
0084   Standard_EXPORT Standard_Boolean IsOutSurf2Box(const gp_Pnt2d& theP);
0085 
0086   //! Returns TRUE if theP is out of the box built from 3D-points.
0087   Standard_EXPORT Standard_Boolean IsOutBox(const gp_Pnt& theP);
0088 
0089   DEFINE_STANDARD_RTTIEXT(IntSurf_LineOn2S,Standard_Transient)
0090 
0091 protected:
0092 
0093 
0094 
0095 
0096 private:
0097 
0098 
0099   IntSurf_SequenceOfPntOn2S mySeq;
0100   Bnd_Box2d myBuv1;
0101   Bnd_Box2d myBuv2;
0102   Bnd_Box myBxyz;
0103 
0104 };
0105 
0106 
0107 #include <IntSurf_LineOn2S.lxx>
0108 
0109 
0110 
0111 
0112 
0113 #endif // _IntSurf_LineOn2S_HeaderFile