Intersection edge nodes advance along the curve at fine display qualities (#1615)
Thanks @jyviko.
This commit is contained in:
1 parent
61678654c2
commit
f57a62deb7
4 files changed
+1243
-15
No files matched your search
@@ -288,3 +288,27 @@ fn cut_of_a_whole_face_beside_round_corners_after_a_chamfer() {
|
||||
let top = mesh.bounds().max.z;
|
||||
assert!((top - 15.0).abs() < 1e-6, "top at {top}");
|
||||
}
|
||||
|
||||
/// The display tessellation of loft bodies joined into a bike frame plans at every display
|
||||
/// quality and every refinement step. The edge nodes on an intersection of two lofts once
|
||||
/// stepped back along the curve (the edge's fit rang where truck's parameter changes speed, and
|
||||
/// took a leader point off the curve past a vertex), so a face's boundary crossed itself and
|
||||
/// the body fell back to the reference mesher, which drew a sheet across the down tube.
|
||||
#[test]
|
||||
fn joined_loft_frames_plan_their_display_at_every_quality() {
|
||||
use solidcraft_doc::display_quality::{DisplayQuality, MAX_REFINE};
|
||||
for (script, name) in [
|
||||
(include_str!("../../../examples/regressions/loft_join_bracket_hull_triangle.json"), "DT2"),
|
||||
(include_str!("../../../examples/regressions/front_triangle_hull_triangle.json"), "FrontTriangle"),
|
||||
] {
|
||||
let s = replay(script);
|
||||
let state = s.model.state();
|
||||
let body = &state.body(name).unwrap().body;
|
||||
for q in DisplayQuality::ALL {
|
||||
for k in 0..=MAX_REFINE {
|
||||
let plan = body.display_plan_angular(q.refined_chord(body.size(), k), q.refined_angle(k));
|
||||
assert!(plan.is_ok(), "{name} at {} + {k}: {:?}", q.id(), plan.err());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user