pub struct Mesh {
pub vertices: Vec<Vertex>,
pub faces: Vec<Face>,
}
Expand description
Represents a mesh. A mesh contains a list of vertices and a list of faces.
Fields§
§vertices: Vec<Vertex>
The list of vertices.
faces: Vec<Face>
The list of faces.
Implementations§
Source§impl Mesh
impl Mesh
Sourcepub fn vertex_count(&self) -> usize
pub fn vertex_count(&self) -> usize
Returns the number of vertices in the mesh.
Sourcepub fn face_count(&self) -> usize
pub fn face_count(&self) -> usize
Returns the number of faces in the mesh.
Sourcepub fn edge_count(&self) -> usize
pub fn edge_count(&self) -> usize
Calculates the number of edges in the mesh.
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