Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:05:27

0001 // Created on: 1998-11-25
0002 // Created by: Xuan PHAM PHU
0003 // Copyright (c) 1998-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 _TopOpeBRepTool_CORRISO_HeaderFile
0018 #define _TopOpeBRepTool_CORRISO_HeaderFile
0019 
0020 #include <Standard.hxx>
0021 #include <Standard_DefineAlloc.hxx>
0022 
0023 #include <TopoDS_Face.hxx>
0024 #include <GeomAdaptor_Surface.hxx>
0025 #include <TopoDS_Shape.hxx>
0026 #include <TopTools_ListOfShape.hxx>
0027 #include <TopOpeBRepTool_DataMapOfOrientedShapeC2DF.hxx>
0028 #include <TopTools_DataMapOfShapeListOfShape.hxx>
0029 #include <TopTools_DataMapOfOrientedShapeInteger.hxx>
0030 class TopoDS_Edge;
0031 class TopOpeBRepTool_C2DF;
0032 class TopoDS_Vertex;
0033 
0034 
0035 //! Fref is built on x-periodic surface (x=u,v).
0036 //! S built on Fref's geometry, should be UVClosed.
0037 //!
0038 //! Give us E, an edge of S. 2drep(E) is not UV connexed.
0039 //! We translate 2drep(E) in xdir*xperiod if necessary.
0040 //!
0041 //! call : TopOpeBRepTool_CORRISO Tool(Fref);
0042 //! Tool.Init(S);
0043 //! if (!Tool.UVClosed()) {
0044 //! // initialize EdsToCheck,nfybounds,stopatfirst
0045 //!
0046 //! Tool.EdgeWithFaultyUV(EdsToCheck,nfybounds,FyEds,stopatfirst);
0047 //! if (Tool.SetUVClosed()) S = Tool.GetnewS();
0048 //! }
0049 class TopOpeBRepTool_CORRISO 
0050 {
0051 public:
0052 
0053   DEFINE_STANDARD_ALLOC
0054 
0055   
0056   Standard_EXPORT TopOpeBRepTool_CORRISO();
0057   
0058   Standard_EXPORT TopOpeBRepTool_CORRISO(const TopoDS_Face& FRef);
0059   
0060   Standard_EXPORT const TopoDS_Face& Fref() const;
0061   
0062   Standard_EXPORT const GeomAdaptor_Surface& GASref() const;
0063   
0064   Standard_EXPORT Standard_Boolean Refclosed (const Standard_Integer x, Standard_Real& xperiod) const;
0065   
0066   Standard_EXPORT Standard_Boolean Init (const TopoDS_Shape& S);
0067   
0068   Standard_EXPORT const TopoDS_Shape& S() const;
0069   
0070   Standard_EXPORT const TopTools_ListOfShape& Eds() const;
0071   
0072   Standard_EXPORT Standard_Boolean UVClosed() const;
0073   
0074   Standard_EXPORT Standard_Real Tol (const Standard_Integer I, const Standard_Real tol3d) const;
0075   
0076   Standard_EXPORT Standard_Boolean PurgeFyClosingE (const TopTools_ListOfShape& ClEds, TopTools_ListOfShape& fyClEds) const;
0077   
0078   Standard_EXPORT Standard_Integer EdgeOUTofBoundsUV (const TopoDS_Edge& E, const Standard_Boolean onU, const Standard_Real tolx, Standard_Real& parspE) const;
0079   
0080   Standard_EXPORT Standard_Boolean EdgesOUTofBoundsUV (const TopTools_ListOfShape& EdsToCheck, const Standard_Boolean onU, const Standard_Real tolx, TopTools_DataMapOfOrientedShapeInteger& FyEds) const;
0081   
0082   Standard_EXPORT Standard_Boolean EdgeWithFaultyUV (const TopoDS_Edge& E, Standard_Integer& Ivfaulty) const;
0083   
0084   Standard_EXPORT Standard_Boolean EdgesWithFaultyUV (const TopTools_ListOfShape& EdsToCheck, const Standard_Integer nfybounds, TopTools_DataMapOfOrientedShapeInteger& FyEds, const Standard_Boolean stopatfirst = Standard_False) const;
0085   
0086   Standard_EXPORT Standard_Boolean EdgeWithFaultyUV (const TopTools_ListOfShape& EdsToCheck, const Standard_Integer nfybounds, TopoDS_Shape& fyE, Standard_Integer& Ifaulty) const;
0087   
0088   Standard_EXPORT Standard_Boolean TrslUV (const Standard_Boolean onU, const TopTools_DataMapOfOrientedShapeInteger& FyEds);
0089   
0090   Standard_EXPORT Standard_Boolean GetnewS (TopoDS_Face& newS) const;
0091   
0092   Standard_EXPORT Standard_Boolean UVRep (const TopoDS_Edge& E, TopOpeBRepTool_C2DF& C2DF) const;
0093   
0094   Standard_EXPORT Standard_Boolean SetUVRep (const TopoDS_Edge& E, const TopOpeBRepTool_C2DF& C2DF);
0095   
0096   Standard_EXPORT Standard_Boolean Connexity (const TopoDS_Vertex& V, TopTools_ListOfShape& Eds) const;
0097   
0098   Standard_EXPORT Standard_Boolean SetConnexity (const TopoDS_Vertex& V, const TopTools_ListOfShape& Eds);
0099   
0100   Standard_EXPORT Standard_Boolean AddNewConnexity (const TopoDS_Vertex& V, const TopoDS_Edge& E);
0101   
0102   Standard_EXPORT Standard_Boolean RemoveOldConnexity (const TopoDS_Vertex& V, const TopoDS_Edge& E);
0103 
0104 
0105 
0106 
0107 protected:
0108 
0109 
0110 
0111 
0112 
0113 private:
0114 
0115 
0116 
0117   TopoDS_Face myFref;
0118   GeomAdaptor_Surface myGAS;
0119   Standard_Boolean myUclosed;
0120   Standard_Boolean myVclosed;
0121   Standard_Real myUper;
0122   Standard_Real myVper;
0123   TopoDS_Shape myS;
0124   TopTools_ListOfShape myEds;
0125   TopOpeBRepTool_DataMapOfOrientedShapeC2DF myERep2d;
0126   TopTools_DataMapOfShapeListOfShape myVEds;
0127 
0128 
0129 };
0130 
0131 
0132 
0133 
0134 
0135 
0136 
0137 #endif // _TopOpeBRepTool_CORRISO_HeaderFile