pub struct Object {
pub id: ResourceId,
pub object_type: ObjectType,
pub name: Option<String>,
pub part_number: Option<String>,
pub uuid: Option<Uuid>,
pub pid: Option<ResourceId>,
pub pindex: Option<u32>,
pub thumbnail: Option<String>,
pub geometry: Geometry,
}Expand description
A 3D object resource containing geometry and metadata.
Objects are the primary reusable resources in a 3MF model. They define geometry (meshes, components, boolean shapes, etc.) and can be referenced by build items or composed into other objects via components.
Each object has an ObjectType that determines its validation requirements and
whether it can appear in the build. For example, Model and SolidSupport types
must be manifold closed volumes, while Support and Surface types can be
non-manifold.
§Examples
See Mesh for examples of creating geometry to place in an object.
Fields§
§id: ResourceIdUnique identifier for this resource within the model.
See ResourceId for details on the global namespace.
object_type: ObjectTypeObject type determining validation rules and build behavior.
name: Option<String>Human-readable name for the object (optional).
part_number: Option<String>Part number for inventory/manufacturing tracking (optional).
uuid: Option<Uuid>Production Extension UUID for unique identification (optional).
pid: Option<ResourceId>Default property resource ID (material/color) for this object (optional). Used when triangles don’t specify their own properties.
pindex: Option<u32>Default property index within the property resource (optional).
thumbnail: Option<String>Path to the thumbnail image in the 3MF package (optional). Used for object-level thumbnails (distinct from package thumbnail).
geometry: GeometryThe actual geometric content of the object.