pub struct Mesh { /* private fields */ }Expand description
A triangle mesh represented as a vector of Triangle.
Implementations§
Source§impl Mesh
impl Mesh
Sourcepub fn vertices(&self) -> impl Iterator<Item = [f32; 3]> + '_
pub fn vertices(&self) -> impl Iterator<Item = [f32; 3]> + '_
Returns the an iterator of vertices of all triangles. This function clones/copies every vertex, and does not deduplicate vertices.
Sourcepub fn vertices_ref(&self) -> impl Iterator<Item = &[f32; 3]>
pub fn vertices_ref(&self) -> impl Iterator<Item = &[f32; 3]>
Returns an iterator of vertex references for all triangles. Does not deduplicate any vertices.
Sourcepub fn unique_vertices(&self) -> impl Iterator<Item = [f32; 3]>
pub fn unique_vertices(&self) -> impl Iterator<Item = [f32; 3]>
Returns an iterator of all unique vertices in the mesh. This function clones/copies every vertex.
Trait Implementations§
impl StructuralPartialEq for Mesh
Auto Trait Implementations§
impl Freeze for Mesh
impl RefUnwindSafe for Mesh
impl Send for Mesh
impl Sync for Mesh
impl Unpin for Mesh
impl UnwindSafe for Mesh
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