File indexing completed on 2026-10-04 09:13:49
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014 #ifndef _BRepFill_Draft_HeaderFile
0015 #define _BRepFill_Draft_HeaderFile
0016
0017 #include <Standard.hxx>
0018 #include <Standard_DefineAlloc.hxx>
0019 #include <Standard_Handle.hxx>
0020
0021 #include <gp_Dir.hxx>
0022 #include <Standard_Real.hxx>
0023 #include <TopoDS_Shape.hxx>
0024 #include <NCollection_Array2.hxx>
0025 #include <NCollection_HArray2.hxx>
0026 #include <NCollection_List.hxx>
0027 #include <TopoDS_Shell.hxx>
0028 #include <TopoDS_Wire.hxx>
0029 #include <GeomAbs_Shape.hxx>
0030 #include <BRepFill_TransitionStyle.hxx>
0031 #include <Standard_Boolean.hxx>
0032 class BRepFill_DraftLaw;
0033 class BRepFill_SectionLaw;
0034 class Geom_Surface;
0035 class Bnd_Box;
0036
0037 class BRepFill_Draft
0038 {
0039 public:
0040 DEFINE_STANDARD_ALLOC
0041
0042 Standard_EXPORT BRepFill_Draft(const TopoDS_Shape& Shape, const gp_Dir& Dir, const double Angle);
0043
0044 Standard_EXPORT void SetOptions(const BRepFill_TransitionStyle Style = BRepFill_Right,
0045 const double AngleMin = 0.01,
0046 const double AngleMax = 3.0);
0047
0048 Standard_EXPORT void SetDraft(const bool IsInternal = false);
0049
0050 Standard_EXPORT void Perform(const double LengthMax);
0051
0052 Standard_EXPORT void Perform(const occ::handle<Geom_Surface>& Surface,
0053 const bool KeepInsideSurface = true);
0054
0055 Standard_EXPORT void Perform(const TopoDS_Shape& StopShape, const bool KeepOutSide = true);
0056
0057 Standard_EXPORT bool IsDone() const;
0058
0059
0060
0061
0062 Standard_EXPORT TopoDS_Shell Shell() const;
0063
0064
0065
0066 Standard_EXPORT const NCollection_List<TopoDS_Shape>& Generated(const TopoDS_Shape& S);
0067
0068 Standard_EXPORT TopoDS_Shape Shape() const;
0069
0070 private:
0071 Standard_EXPORT void Init(const occ::handle<Geom_Surface>& Surf,
0072 const double Length,
0073 const Bnd_Box& Box);
0074
0075 Standard_EXPORT void BuildShell(const occ::handle<Geom_Surface>& Surf,
0076 const bool KeepOutSide = false);
0077
0078 Standard_EXPORT bool Fuse(const TopoDS_Shape& S, const bool KeepOutSide);
0079
0080 Standard_EXPORT bool Sewing();
0081
0082 gp_Dir myDir;
0083 double myAngle;
0084 double angmin;
0085 double angmax;
0086 double myTol;
0087 occ::handle<BRepFill_DraftLaw> myLoc;
0088 occ::handle<BRepFill_SectionLaw> mySec;
0089 occ::handle<NCollection_HArray2<TopoDS_Shape>> mySections;
0090 occ::handle<NCollection_HArray2<TopoDS_Shape>> myFaces;
0091 NCollection_List<TopoDS_Shape> myGenerated;
0092 TopoDS_Shape myShape;
0093 TopoDS_Shape myTop;
0094 TopoDS_Shell myShell;
0095 TopoDS_Wire myWire;
0096 GeomAbs_Shape myCont;
0097 BRepFill_TransitionStyle myStyle;
0098 bool IsInternal;
0099 bool myDone;
0100 };
0101
0102 #endif