Struct gfx::render::mesh::Slice
[−]
[src]
pub struct Slice<R: Resources> { pub start: VertexCount, pub end: VertexCount, pub prim_type: PrimitiveType, pub kind: SliceKind<R>, }
Description of a subset of Mesh
data to render.
Only vertices between start
and end
are rendered. The
source of the vertex data is dependent on the kind
value.
The prim_type
defines how the mesh contents are interpreted.
For example, Point
typed vertex slice can be used to do shape
blending, while still rendereing it as an indexed TriangleList
.
Fields
start | Start index of vertices to draw. |
end | End index of vertices to draw. |
prim_type | Primitive type to render collections of vertices as. |
kind | Source of the vertex ordering when drawing. |
Methods
impl<R: Resources> Slice<R>
fn get_prim_count(&self) -> u32
Get the number of primitives in this slice.