Import glTF 2.0 files (.glb, .gltf) as mesh bodies (#1512)

glTF files open, insert and drop like 3MF/STL/OBJ: a component named after the file, the node tree as nested rigid components, repeated meshes as occurrences, metres to mm, Y up turned to Z up by default (up: z keeps axes), materials as PBR appearances. Bounded, hostile-input tested reader; no new persisted data. Closes #1505.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
bherbruckandClaude Opus 5.5 authored and GitHub committed 2026-10-15 17:27:29 -04:00
1 parent 5823900439
commit a13124acdd
19 files changed
+1889 -71

No files matched your search

+2 -2
View File
@@ -953,7 +953,7 @@ impl SolveApp {
file_load::begin(self, path, true);
}
/// Insert a STEP file's bodies (an Import base feature) or a 3MF/STL file's meshes into the
/// Insert a STEP file's bodies (an Import base feature) or a mesh file's meshes into the
/// current design.
pub fn insert_path(&mut self, path: &str) {
let cmd = if solidcraft_engine::io::is_mesh_path(path) { "file.insert_mesh" } else { "file.insert_step" };
@@ -967,7 +967,7 @@ impl SolveApp {
}
}
/// A dropped file: a STEP, 3MF or STL file joins a design that has features, anything else
/// A dropped file: a STEP or mesh file (3MF, STL, OBJ, glTF) joins a design that has features, anything else
/// opens.
pub fn drop_path(&mut self, path: &str) {
let import = solidcraft_engine::io::is_step_path(path) || solidcraft_engine::io::is_mesh_path(path);