File indexing completed on 2026-09-12 09:17:46
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017 #ifndef _IntCurveSurface_ThePolygonOfHInter_HeaderFile
0018 #define _IntCurveSurface_ThePolygonOfHInter_HeaderFile
0019
0020 #include <Adaptor3d_Curve.hxx>
0021 #include <Bnd_Box.hxx>
0022 #include <gp_Pnt.hxx>
0023 #include <NCollection_Array1.hxx>
0024 #include <NCollection_HArray1.hxx>
0025 class Standard_OutOfRange;
0026 class IntCurveSurface_TheHCurveTool;
0027 class Bnd_Box;
0028 class gp_Pnt;
0029
0030 class IntCurveSurface_ThePolygonOfHInter
0031 {
0032 public:
0033 DEFINE_STANDARD_ALLOC
0034
0035 Standard_EXPORT IntCurveSurface_ThePolygonOfHInter(const occ::handle<Adaptor3d_Curve>& Curve,
0036 const int NbPnt);
0037
0038 Standard_EXPORT IntCurveSurface_ThePolygonOfHInter(const occ::handle<Adaptor3d_Curve>& Curve,
0039 const double U1,
0040 const double U2,
0041 const int NbPnt);
0042
0043 Standard_EXPORT IntCurveSurface_ThePolygonOfHInter(const occ::handle<Adaptor3d_Curve>& Curve,
0044 const NCollection_Array1<double>& Upars);
0045
0046
0047 const Bnd_Box& Bounding() const { return TheBnd; }
0048
0049 double DeflectionOverEstimation() const { return TheDeflection; }
0050
0051 void SetDeflectionOverEstimation(const double x)
0052 {
0053 TheDeflection = x;
0054 TheBnd.Enlarge(TheDeflection);
0055 }
0056
0057 void Closed(const bool flag) { ClosedPolygon = flag; }
0058
0059
0060 bool Closed() const { return ClosedPolygon; }
0061
0062
0063
0064
0065 int NbSegments() const { return NbPntIn - 1; }
0066
0067
0068 const gp_Pnt& BeginOfSeg(const int theIndex) const { return ThePnts(theIndex); }
0069
0070
0071 const gp_Pnt& EndOfSeg(const int theIndex) const { return ThePnts(theIndex + 1); }
0072
0073
0074
0075 double InfParameter() const { return Binf; }
0076
0077
0078
0079 double SupParameter() const { return Bsup; }
0080
0081
0082
0083 Standard_EXPORT double ApproxParamOnCurve(const int Index, const double ParamOnLine) const;
0084
0085 Standard_EXPORT void Dump() const;
0086
0087 protected:
0088 Standard_EXPORT void Init(const occ::handle<Adaptor3d_Curve>& Curve);
0089
0090 Standard_EXPORT void Init(const occ::handle<Adaptor3d_Curve>& Curve,
0091 const NCollection_Array1<double>& Upars);
0092
0093 private:
0094 Bnd_Box TheBnd;
0095 double TheDeflection;
0096 int NbPntIn;
0097 NCollection_Array1<gp_Pnt> ThePnts;
0098 bool ClosedPolygon;
0099 double Binf;
0100 double Bsup;
0101 occ::handle<NCollection_HArray1<double>> myParams;
0102 };
0103
0104 #endif