forked from 1b-agent/opencadstudio-upstream
Reverse complete helix geometry and preserve top radius semantics
This commit is contained in:
1 parent
f80e9f742c
commit
25ac594d85
3 files changed
+36
-11
No files matched your search
@@ -134,7 +134,7 @@ impl HelixCommand {
|
||||
let start = self.center + start_direction * curve.base_radius;
|
||||
helix.start_point = Vector3::new(start.x, start.y, start.z);
|
||||
helix.axis_vector = Vector3::new(axis.x, axis.y, axis.z);
|
||||
helix.radius = curve.base_radius;
|
||||
helix.radius = curve.top_radius;
|
||||
helix.turns = curve.turns;
|
||||
helix.turn_height = height / curve.turns;
|
||||
helix.handedness = self.counter_clockwise;
|
||||
|
||||
@@ -76,6 +76,7 @@ impl ReverseCommand {
|
||||
Some(EntityType::Polyline3D(out))
|
||||
}
|
||||
EntityType::Spline(sp) => Some(EntityType::Spline(reverse_spline(sp))),
|
||||
EntityType::Helix(helix) => crate::entities::helix::reversed(helix).map(EntityType::Helix),
|
||||
_ => None,
|
||||
}
|
||||
}
|
||||
@@ -199,7 +200,7 @@ impl CadCommand for ReverseCommand {
|
||||
}
|
||||
|
||||
fn prompt(&self) -> String {
|
||||
t!("REVERSE Select line, polyline or spline to reverse:").into_owned()
|
||||
t!("REVERSE Select line, polyline, spline or helix to reverse:").into_owned()
|
||||
}
|
||||
|
||||
fn needs_entity_pick(&self) -> bool {
|
||||
|
||||
Reference in new issue
Block a user