forked from 1b-agent/fieldcraft-upstream
UI: datum planes and axes in the viewport, datums and partitions in the browser
Datum planes draw as a hatched square around the model, axes as a line through it, each with its name, in the desktop viewport and the headless render. The browser's Geometry node lists the datums and the partitions with the datum each cuts by. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01UhhZMBTviDQxZvwnyP89fo
This commit is contained in:
1 parent
22f1006f71
commit
f6d227d8cb
6 files changed
+112
-4
No files matched your search
@@ -69,6 +69,11 @@ pub fn symbols(s: &mut Scene, glyphs: &Glyphs, pos: impl Fn(u32) -> Option<Vec3>
|
||||
glyphs.draw(pos, GlyphShow { loads: show.loads, interactions: show.interactions }, &colors, s)
|
||||
}
|
||||
|
||||
/// Draw the model's datum planes and axes around `bounds` into `s`; returns the box around them.
|
||||
pub fn datums(s: &mut Scene, model: &fieldcraft_model::Model, bounds: &Aabb3, t: &Tokens) -> Aabb3 {
|
||||
fieldcraft_render::glyphs::datums(model, bounds, &t.glyph_colors(), s)
|
||||
}
|
||||
|
||||
/// The scene for `display` drawn in `style`.
|
||||
pub fn build(display: &DisplayMesh, style: Style, show: Show, t: &Tokens) -> Scene {
|
||||
let mut s = Scene { background: Some((rgb(t.viewport_top), rgb(t.viewport_bottom))), ..Default::default() };
|
||||
|
||||
Reference in new issue
Block a user