File indexing completed on 2026-09-20 09:18:50
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017 #ifndef _PrsDim_EqualDistanceRelation_HeaderFile
0018 #define _PrsDim_EqualDistanceRelation_HeaderFile
0019
0020 #include <PrsDim_Relation.hxx>
0021 #include <PrsDim_TypeOfDist.hxx>
0022 #include <DsgPrs_ArrowSide.hxx>
0023
0024 class Geom_Plane;
0025
0026
0027
0028
0029
0030
0031 class PrsDim_EqualDistanceRelation : public PrsDim_Relation
0032 {
0033 DEFINE_STANDARD_RTTIEXT(PrsDim_EqualDistanceRelation, PrsDim_Relation)
0034 public:
0035
0036
0037
0038
0039
0040 Standard_EXPORT PrsDim_EqualDistanceRelation(const TopoDS_Shape& aShape1,
0041 const TopoDS_Shape& aShape2,
0042 const TopoDS_Shape& aShape3,
0043 const TopoDS_Shape& aShape4,
0044 const occ::handle<Geom_Plane>& aPlane);
0045
0046
0047
0048 void SetShape3(const TopoDS_Shape& aShape) { myShape3 = aShape; }
0049
0050
0051
0052 const TopoDS_Shape& Shape3() const { return myShape3; }
0053
0054
0055
0056 void SetShape4(const TopoDS_Shape& aShape) { myShape4 = aShape; }
0057
0058
0059
0060 const TopoDS_Shape& Shape4() const { return myShape4; }
0061
0062 public:
0063
0064
0065
0066 Standard_EXPORT static void ComputeTwoEdgesLength(
0067 const occ::handle<Prs3d_Presentation>& aPresentation,
0068 const occ::handle<Prs3d_Drawer>& aDrawer,
0069 const double ArrowSize,
0070 const TopoDS_Edge& FirstEdge,
0071 const TopoDS_Edge& SecondEdge,
0072 const occ::handle<Geom_Plane>& Plane,
0073 const bool AutomaticPos,
0074 const bool IsSetBndBox,
0075 const Bnd_Box& BndBox,
0076 gp_Pnt& Position,
0077 gp_Pnt& FirstAttach,
0078 gp_Pnt& SecondAttach,
0079 gp_Pnt& FirstExtreme,
0080 gp_Pnt& SecondExtreme,
0081 DsgPrs_ArrowSide& SymbolPrs);
0082
0083
0084
0085 Standard_EXPORT static void ComputeTwoVerticesLength(
0086 const occ::handle<Prs3d_Presentation>& aPresentation,
0087 const occ::handle<Prs3d_Drawer>& aDrawer,
0088 const double ArrowSize,
0089 const TopoDS_Vertex& FirstVertex,
0090 const TopoDS_Vertex& SecondVertex,
0091 const occ::handle<Geom_Plane>& Plane,
0092 const bool AutomaticPos,
0093 const bool IsSetBndBox,
0094 const Bnd_Box& BndBox,
0095 const PrsDim_TypeOfDist TypeDist,
0096 gp_Pnt& Position,
0097 gp_Pnt& FirstAttach,
0098 gp_Pnt& SecondAttach,
0099 gp_Pnt& FirstExtreme,
0100 gp_Pnt& SecondExtreme,
0101 DsgPrs_ArrowSide& SymbolPrs);
0102
0103
0104
0105 Standard_EXPORT static void ComputeOneEdgeOneVertexLength(
0106 const occ::handle<Prs3d_Presentation>& aPresentation,
0107 const occ::handle<Prs3d_Drawer>& aDrawer,
0108 const double ArrowSize,
0109 const TopoDS_Shape& FirstShape,
0110 const TopoDS_Shape& SecondShape,
0111 const occ::handle<Geom_Plane>& Plane,
0112 const bool AutomaticPos,
0113 const bool IsSetBndBox,
0114 const Bnd_Box& BndBox,
0115 gp_Pnt& Position,
0116 gp_Pnt& FirstAttach,
0117 gp_Pnt& SecondAttach,
0118 gp_Pnt& FirstExtreme,
0119 gp_Pnt& SecondExtreme,
0120 DsgPrs_ArrowSide& SymbolPrs);
0121
0122 private:
0123 Standard_EXPORT void Compute(const occ::handle<PrsMgr_PresentationManager>& thePrsMgr,
0124 const occ::handle<Prs3d_Presentation>& thePrs,
0125 const int theMode) override;
0126
0127 Standard_EXPORT void ComputeSelection(const occ::handle<SelectMgr_Selection>& theSel,
0128 const int theMode) override;
0129
0130 private:
0131 TopoDS_Shape myShape3;
0132 TopoDS_Shape myShape4;
0133 gp_Pnt myAttachPoint1;
0134 gp_Pnt myAttachPoint2;
0135 gp_Pnt myAttachPoint3;
0136 gp_Pnt myAttachPoint4;
0137 gp_Pnt myPoint1;
0138 gp_Pnt myPoint2;
0139 gp_Pnt myPoint3;
0140 gp_Pnt myPoint4;
0141 };
0142
0143 #endif