|
|
|||
File indexing completed on 2026-09-08 09:15:49
0001 // Created on: 1993-10-12 0002 // Created by: Remi LEQUETTE 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 _BRepPrimAPI_MakePrism_HeaderFile 0018 #define _BRepPrimAPI_MakePrism_HeaderFile 0019 0020 #include <Standard.hxx> 0021 #include <Standard_DefineAlloc.hxx> 0022 0023 #include <BRepSweep_Prism.hxx> 0024 #include <BRepPrimAPI_MakeSweep.hxx> 0025 #include <TopTools_ListOfShape.hxx> 0026 class TopoDS_Shape; 0027 class gp_Vec; 0028 class gp_Dir; 0029 0030 //! Describes functions to build linear swept topologies, called prisms. 0031 //! A prism is defined by: 0032 //! - a basis shape, which is swept, and 0033 //! - a sweeping direction, which is: 0034 //! - a vector for finite prisms, or 0035 //! - a direction for infinite or semi-infinite prisms. 0036 //! The basis shape must not contain any solids. 0037 //! The profile generates objects according to the following rules: 0038 //! - Vertices generate Edges 0039 //! - Edges generate Faces. 0040 //! - Wires generate Shells. 0041 //! - Faces generate Solids. 0042 //! - Shells generate Composite Solids 0043 //! A MakePrism object provides a framework for: 0044 //! - defining the construction of a prism, 0045 //! - implementing the construction algorithm, and 0046 //! - consulting the result. 0047 class BRepPrimAPI_MakePrism : public BRepPrimAPI_MakeSweep 0048 { 0049 public: 0050 DEFINE_STANDARD_ALLOC 0051 0052 //! Builds the prism of base S and vector V. If C is true, 0053 //! S is copied. If Canonize is true then generated surfaces 0054 //! are attempted to be canonized in simple types 0055 Standard_EXPORT BRepPrimAPI_MakePrism(const TopoDS_Shape& S, 0056 const gp_Vec& V, 0057 const Standard_Boolean Copy = Standard_False, 0058 const Standard_Boolean Canonize = Standard_True); 0059 0060 //! Builds a semi-infinite or an infinite prism of base S. 0061 //! If Inf is true the prism is infinite, if Inf is false 0062 //! the prism is semi-infinite (in the direction D). If C 0063 //! is true S is copied (for semi-infinite prisms). 0064 //! If Canonize is true then generated surfaces 0065 //! are attempted to be canonized in simple types 0066 Standard_EXPORT BRepPrimAPI_MakePrism(const TopoDS_Shape& S, 0067 const gp_Dir& D, 0068 const Standard_Boolean Inf = Standard_True, 0069 const Standard_Boolean Copy = Standard_False, 0070 const Standard_Boolean Canonize = Standard_True); 0071 0072 //! Returns the internal sweeping algorithm. 0073 Standard_EXPORT const BRepSweep_Prism& Prism() const; 0074 0075 //! Builds the resulting shape (redefined from MakeShape). 0076 Standard_EXPORT virtual void Build( 0077 const Message_ProgressRange& theRange = Message_ProgressRange()) Standard_OVERRIDE; 0078 0079 //! Returns the TopoDS Shape of the bottom of the prism. 0080 Standard_EXPORT TopoDS_Shape FirstShape() Standard_OVERRIDE; 0081 0082 //! Returns the TopoDS Shape of the top of the prism. 0083 //! In the case of a finite prism, FirstShape returns the 0084 //! basis of the prism, in other words, S if Copy is false; 0085 //! otherwise, the copy of S belonging to the prism. 0086 //! LastShape returns the copy of S translated by V at the 0087 //! time of construction. 0088 Standard_EXPORT TopoDS_Shape LastShape() Standard_OVERRIDE; 0089 0090 //! Returns ListOfShape from TopTools. 0091 Standard_EXPORT virtual const TopTools_ListOfShape& Generated(const TopoDS_Shape& S) 0092 Standard_OVERRIDE; 0093 0094 //! Returns true if the shape S has been deleted. 0095 Standard_EXPORT virtual Standard_Boolean IsDeleted(const TopoDS_Shape& S) Standard_OVERRIDE; 0096 0097 //! Returns the TopoDS Shape of the bottom of the prism. 0098 //! generated with theShape (subShape of the generating shape). 0099 Standard_EXPORT TopoDS_Shape FirstShape(const TopoDS_Shape& theShape); 0100 0101 //! Returns the TopoDS Shape of the top of the prism. 0102 //! generated with theShape (subShape of the generating shape). 0103 Standard_EXPORT TopoDS_Shape LastShape(const TopoDS_Shape& theShape); 0104 0105 protected: 0106 private: 0107 BRepSweep_Prism myPrism; 0108 }; 0109 0110 #endif // _BRepPrimAPI_MakePrism_HeaderFile
| [ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
|
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |
|