pub struct ObjEncoder { /* private fields */ }Expand description
Wavefront OBJ encoder.
By default the encoder emits a standalone OBJ (no mtllib
directive). Call ObjEncoder::with_mtl_basename to embed an
mtllib <basename>.mtl line at the top, in which case the caller
is responsible for writing the companion MTL file alongside (use
crate::mtl::serialize_mtl for that).
The encoder is loss-tolerant — it preserves the OBJ-specific
extras (obj:groups, obj:smoothing_group, obj:original_face_arities,
obj:usemtl, obj:mtllibs) populated by the decoder, so a
decode → encode → decode round-trip is structurally stable.
Implementations§
Source§impl ObjEncoder
impl ObjEncoder
Trait Implementations§
Source§impl Debug for ObjEncoder
impl Debug for ObjEncoder
Source§impl Default for ObjEncoder
impl Default for ObjEncoder
Source§fn default() -> ObjEncoder
fn default() -> ObjEncoder
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for ObjEncoder
impl RefUnwindSafe for ObjEncoder
impl Send for ObjEncoder
impl Sync for ObjEncoder
impl Unpin for ObjEncoder
impl UnsafeUnpin for ObjEncoder
impl UnwindSafe for ObjEncoder
Blanket Implementations§
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
Mutably borrows from an owned value. Read more