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.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Object
impl<'de> Deserialize<'de> for Object
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl StructuralPartialEq for Object
Auto Trait Implementations§
impl Freeze for Object
impl RefUnwindSafe for Object
impl Send for Object
impl Sync for Object
impl Unpin for Object
impl UnwindSafe for Object
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more