File indexing completed on 2026-09-25 09:19:26
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016 #ifndef ChFi2d_AnaFilletAlgo_HeaderFile
0017 #define ChFi2d_AnaFilletAlgo_HeaderFile
0018
0019 #include <TopoDS_Wire.hxx>
0020 #include <TopoDS_Edge.hxx>
0021 #include <gp_Pln.hxx>
0022
0023
0024
0025 class ChFi2d_AnaFilletAlgo
0026 {
0027 public:
0028
0029
0030 Standard_EXPORT ChFi2d_AnaFilletAlgo();
0031
0032
0033
0034
0035
0036 Standard_EXPORT ChFi2d_AnaFilletAlgo(const TopoDS_Wire& theWire, const gp_Pln& thePlane);
0037
0038
0039
0040
0041
0042 Standard_EXPORT ChFi2d_AnaFilletAlgo(const TopoDS_Edge& theEdge1,
0043 const TopoDS_Edge& theEdge2,
0044 const gp_Pln& thePlane);
0045
0046
0047 Standard_EXPORT void Init(const TopoDS_Wire& theWire, const gp_Pln& thePlane);
0048
0049
0050 Standard_EXPORT void Init(const TopoDS_Edge& theEdge1,
0051 const TopoDS_Edge& theEdge2,
0052 const gp_Pln& thePlane);
0053
0054
0055 Standard_EXPORT bool Perform(const double radius);
0056
0057
0058 Standard_EXPORT const TopoDS_Edge& Result(TopoDS_Edge& e1, TopoDS_Edge& e2);
0059
0060 private:
0061
0062
0063
0064
0065
0066
0067 bool SegmentFilletSegment(const double radius,
0068 double& xc,
0069 double& yc,
0070 bool& cw,
0071 double& start,
0072 double& end);
0073
0074
0075 bool SegmentFilletArc(const double radius,
0076 double& xc,
0077 double& yc,
0078 bool& cw,
0079 double& start,
0080 double& end,
0081 double& xend,
0082 double& yend);
0083
0084
0085 bool ArcFilletSegment(const double radius,
0086 double& xc,
0087 double& yc,
0088 bool& cw,
0089 double& start,
0090 double& end,
0091 double& xstart,
0092 double& ystart);
0093
0094
0095
0096
0097
0098
0099
0100 bool ArcFilletArc(const double radius,
0101 double& xc,
0102 double& yc,
0103 bool& cw,
0104 double& start,
0105 double& end);
0106
0107
0108 bool Cut(const gp_Pln& plane, TopoDS_Edge& e1, TopoDS_Edge& e2);
0109
0110
0111 gp_Pln plane;
0112
0113
0114 TopoDS_Edge e1;
0115 bool segment1;
0116 double x11;
0117 double y11;
0118 double x12;
0119 double y12;
0120 double xc1;
0121 double yc1;
0122 double radius1;
0123 bool cw1;
0124
0125
0126 TopoDS_Edge e2;
0127 bool segment2;
0128 double x21;
0129 double y21;
0130 double x22;
0131 double y22;
0132 double xc2;
0133 double yc2;
0134 double radius2;
0135 bool cw2;
0136
0137
0138 TopoDS_Edge fillet;
0139 TopoDS_Edge shrinke1;
0140 TopoDS_Edge shrinke2;
0141 };
0142
0143 #endif