fix(explode): correct arc/ellipse direction in mirrored INSERT blocks

Mirrored INSERTs reverse OCS handedness, but acadrust's explode used to
keep the original normal — making CCW-around-normal arcs and ellipses
sweep the wrong way. The fix lives in acadrust 7c711e9, which flips the
new normal when det < 0 and reprojects center/major_axis/angles into the
new OCS. H7CAD's fix_mirrored_arc workaround is no longer needed.
This commit is contained in:
Hakan Seven committed 2026-05-12 22:04:12 +03:00
1 parent 04b898106c
commit 200f10fd25
4 files changed
+7 -28

No files matched your search

-2
View File
@@ -3788,7 +3788,6 @@ fn tessellate_entity(
}
if let EntityType::Insert(ins) = e {
let is_mirrored = ins.x_scale() * ins.y_scale() < 0.0;
// Resolve the INSERT's own style so ByBlock sub-entities can inherit it.
let (ins_color, ins_pat_len, ins_pat, ins_lw_px, _) = render::render_style_for(document, e);
let ins_color = render::adapt_to_bg(ins_color, bg_color);
@@ -3797,7 +3796,6 @@ fn tessellate_entity(
.iter()
.cloned()
.map(crate::modules::home::modify::explode::normalize_insert_entity)
.map(|sub| crate::modules::home::modify::explode::fix_mirrored_arc(sub, is_mirrored))
.flat_map(|sub| {
let (sub_color, sub_pattern_length, sub_pattern, sub_line_weight_px, sub_aci) =
render::render_style_for_block_sub(