MCPcopy Create free account
hub / github.com/InteractiveComputerGraphics/splashsurf / main

Function main

splashsurf_lib/examples/minimal_levelset.rs:174–192  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

172}
173
174fn main() -> Result<(), anyhow::Error> {
175 let level_set = example_level_set();
176
177 let domain = Aabb3d::new(Vector3::new(-1.5, -1.5, -1.5), Vector3::new(1.5, 1.5, 1.5));
178 let cube_size = 0.05;
179
180 let mesh = marching_cubes(level_set, &domain, cube_size)?;
181
182 println!(
183 "Vertices: {} triangles: {}",
184 mesh.vertices.len(),
185 mesh.triangles.len()
186 );
187
188 #[cfg(feature = "io")]
189 io::vtk_format::write_vtk(&mesh, "out/sdf_test.vtk", "mesh")?;
190
191 Ok(())
192}

Callers

nothing calls this directly

Calls 3

example_level_setFunction · 0.85
write_vtkFunction · 0.85
marching_cubesFunction · 0.70

Tested by

no test coverage detected