Crate nannou_mesh[][src]

Expand description

An API for composing Meshs. Meshs may be composed of different sets of channels including position, color, texture-coordinate and normals. Note that this is quite a low-level representation. For a higher-level, graphics-related mesh API, see the draw module.

Re-exports

pub use self::channel::Channel;
pub use self::channel::ChannelMut;

Modules

Vertex types yielded by the mesh adaptors and their implementations.

Structs

The base mesh type with only a single vertex channel.

An iterator yielding the raw vertices (with combined channels) of a mesh.

An iterator yielding vertices in the order specified via the mesh’s Indices channel.

A Mesh type with an added channel containing colors.

A mesh type with an added channel containing indices describing the edges between vertices.

A Mesh type with an added channel containing vertex normals.

A Mesh type with an added channel containing texture coordinates.

Traits

Meshes whose indices and vertices buffers may be cleared for re-use.

Meshes whose Indices channel can be cleared.

Meshes whose vertices channels can be cleared.

Meshes that contain a channel of colors.

Meshes that may be extended from a slice of data.

Mesh types that can be indexed to produce a vertex.

Meshes that contain a channel of indices that describe the edges between points.

Meshes that contain a channel of vertex normals.

All meshes must contain at least one vertex channel.

Meshes that contain an Indices channel and can push new indices to it.

Meshes that can push vertices of type V while keeping all non-index channels the same length before and after the push.

Meshes that contain a channel of texture coordinates.

Functions

Clear all vertices and indices from the mesh.

Clear all indices from the mesh.

Clear all vertices from the mesh.

Extend the given mesh with the given indices.

Extend the given mesh with the given sequence of vertices.

Create a simple base mesh from the given channel of vertex points.

Push the given index to the given mesh.

Push the given vertex to the given mesh.

Get the number of vertices in the mesh.

An iterator yielding the raw vertices (with combined channels) of a mesh.

The number of triangles that would be yielded by a Triangles iterator for the given mesh.

Produce an iterator yielding triangles for every three vertices yielded in the order specified via the mesh’s Indices channel.

The number of vertices that would be yielded by a Vertices iterator for the given mesh.

Produce an iterator yielding vertices in the order specified via the mesh’s Indices channel.

Combine the given mesh with the given channel of vertex colors.

Combine the given mesh with the given channel of vertex indices.

Combine the given mesh with the given Normals channel.

Combine the given mesh with the given channel of vertex texture coordinates.

Type Definitions

An iterator yielding triangles in the order specified via the mesh’s Indices channel.