forked from 1b-agent/opencadstudio-upstream
fix(grips): arcs, circles and solids with a flipped normal show grips in place
Their grip code already works in world space, and the dispatch layer converted the grips through the OCS a second time, so for a normal of (0,0,-1) the grips (and grip edits) were mirrored across the Y axis. Fixes #1683 Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
1 parent
15c566c286
commit
551d4c1c60
1 file changed
+3
-3
@@ -34,12 +34,12 @@ pub fn prop_current_vertex() -> usize {
|
||||
/// through untouched. Per-entity grip code works in raw field space, so the
|
||||
/// dispatch layer converts: display grips OCS→WCS, incoming edits WCS→OCS.
|
||||
fn planar_ocs_normal(entity: &EntityType) -> Option<(f64, f64, f64)> {
|
||||
// Arc, Circle and Solid grips are already world-space (their grip code
|
||||
// places them through the OCS itself); converting them again mirrors
|
||||
// them for a flipped normal.
|
||||
let n = match entity {
|
||||
EntityType::Arc(e) => e.normal,
|
||||
EntityType::Circle(e) => e.normal,
|
||||
EntityType::LwPolyline(e) => e.normal,
|
||||
EntityType::Polyline2D(e) => e.normal,
|
||||
EntityType::Solid(e) => e.normal,
|
||||
EntityType::Text(e) => e.normal,
|
||||
EntityType::AttributeDefinition(e) => e.normal,
|
||||
EntityType::Hatch(e) => e.normal,
|
||||
|
||||
Reference in new issue
Block a user