ENH: Tolerance of the connectors in mm instead of percents

github issue #1644

Change-Id: I7d7bd02f7b695108abbcbdb0c077d2c1ce911af4
(cherry picked from commit fd89cbdba2bd4a9808d43e8ad2d68b60d076ddb8)
This commit is contained in:
zhimin.zeng 2023-04-21 15:35:45 +08:00 committed by Lane.Wei
parent 2b9f3c9912
commit c720e1eb0f
4 changed files with 40 additions and 15 deletions

View file

@ -836,12 +836,15 @@ public:
bool is_connector{false};
bool is_processed{true};
CutConnectorType connector_type{CutConnectorType::Plug};
float radius{0.f};
float height{0.f};
float radius_tolerance{0.f}; // [0.f : 1.f]
float height_tolerance{0.f}; // [0.f : 1.f]
CutInfo() = default;
CutInfo(CutConnectorType type, float rad_tolerance, float h_tolerance, bool processed = false)
: is_connector(true), is_processed(processed), connector_type(type), radius_tolerance(rad_tolerance), height_tolerance(h_tolerance)
CutInfo(CutConnectorType type, float radius_, float height_, float rad_tolerance, float h_tolerance, bool processed = false)
: is_connector(true), is_processed(processed), connector_type(type)
, radius(radius_), height(height_), radius_tolerance(rad_tolerance), height_tolerance(h_tolerance)
{}
void set_processed() { is_processed = true; }