Skip to main content

geop_core_topology/
solid.rs

1use super::ids::ShellId;
2
3/// A 3-dimensional topological entity: a region of space bounded by
4/// closed shells, each connected, which never cross. A point is inside the
5/// solid when it is inside an odd number of them, so a shell is a lump of
6/// its own or a void in one by where it lies, not by its place in
7/// `shells`: a boolean cutting a bar in two leaves two lumps, one leaving
8/// a sphere's room inside a block a lump and a void. A void's faces point
9/// into it, out of the material, so the volume it encloses is negative.
10#[derive(Clone, Debug, PartialEq, serde::Serialize, serde::Deserialize)]
11pub struct Solid {
12    pub shells: Vec<ShellId>,
13}