pub struct TriangleMesh {
pub positions: Vec<f32>,
pub indices: Vec<u32>,
}Expand description
Indexed triangle mesh with interleaved XYZ positions.
Fields§
§positions: Vec<f32>Interleaved XYZ vertex positions.
indices: Vec<u32>Triangle indices (groups of three).
Implementations§
Source§impl TriangleMesh
impl TriangleMesh
Sourcepub fn vertex_count(&self) -> usize
pub fn vertex_count(&self) -> usize
Returns the vertex count.
Sourcepub fn triangle_count(&self) -> usize
pub fn triangle_count(&self) -> usize
Returns the triangle count.
Trait Implementations§
Source§impl Clone for TriangleMesh
impl Clone for TriangleMesh
Source§fn clone(&self) -> TriangleMesh
fn clone(&self) -> TriangleMesh
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for TriangleMesh
impl Debug for TriangleMesh
Source§impl Default for TriangleMesh
impl Default for TriangleMesh
Source§fn default() -> TriangleMesh
fn default() -> TriangleMesh
Returns the “default value” for a type. Read more
Source§impl PartialEq for TriangleMesh
impl PartialEq for TriangleMesh
Source§fn eq(&self, other: &TriangleMesh) -> bool
fn eq(&self, other: &TriangleMesh) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for TriangleMesh
Auto Trait Implementations§
impl Freeze for TriangleMesh
impl RefUnwindSafe for TriangleMesh
impl Send for TriangleMesh
impl Sync for TriangleMesh
impl Unpin for TriangleMesh
impl UnsafeUnpin for TriangleMesh
impl UnwindSafe for TriangleMesh
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