Enum gfx::IndexBuffer [−][src]
Type of index-buffer used in a Slice.
The Auto
variant represents a hypothetical index-buffer from 0 to infinity. In other words,
all vertices get processed in order. Do note that the Slice
’s start
and end
restrictions
still apply for this variant. To render every vertex in the VertexBuffer
, you would set
start
to 0, and end
to the VertexBuffer
’s length.
The Index*
variants represent an actual Buffer
with a list of vertex-indices. The numeric
suffix specifies the amount of bits to use per index. Each of these also contains a
base-vertex. This is the index of the first vertex in the VertexBuffer
. This value will be
added to every index in the index-buffer, effectively moving the start of the VertexBuffer
to
this base-vertex.
Construction & Handling
A IndexBuffer
can be constructed using the IntoIndexBuffer
trait, from either a slice or a
Buffer
of integers, using a factory.
An IndexBuffer
is exclusively used to create Slice
s.
Variants
Represents a hypothetical index-buffer from 0 to infinity. In other words, all vertices get processed in order.
An index-buffer with unsigned 16 bit indices.
An index-buffer with unsigned 32 bit indices.
Trait Implementations
impl<R: Clone + Resources> Clone for IndexBuffer<R>
[src][+]
impl<R: Debug + Resources> Debug for IndexBuffer<R>
[src][+]
impl<R: Resources> Default for IndexBuffer<R>
[src][+]
impl<R: Eq + Resources> Eq for IndexBuffer<R>
[src]
impl<R: Hash + Resources> Hash for IndexBuffer<R>
[src][+]
impl<R: Resources> IntoIndexBuffer<R> for IndexBuffer<R>
[src][+]
impl<R: PartialEq + Resources> PartialEq<IndexBuffer<R>> for IndexBuffer<R>
[src][+]
impl<R: Resources> StructuralEq for IndexBuffer<R>
[src]
impl<R: Resources> StructuralPartialEq for IndexBuffer<R>
[src]
Auto Trait Implementations
impl<R> !RefUnwindSafe for IndexBuffer<R>
impl<R> Send for IndexBuffer<R>
impl<R> Sync for IndexBuffer<R>
impl<R> Unpin for IndexBuffer<R>
impl<R> !UnwindSafe for IndexBuffer<R>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src][+]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src][+]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src][+]
T: ?Sized,
impl<T> From<T> for T
[src][+]
impl<T, U> Into<U> for T where
U: From<T>,
[src][+]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src][+]
T: Clone,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src][+]
U: Into<T>,
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src][+]
U: TryFrom<T>,