Trait glitter::texture::TextureType
[−]
[src]
pub trait TextureType { type ImageTargetType: ImageTargetType; fn target() -> TextureBindingTarget; }
A trait implemented for a type that represent a type of texture (such
as 2D textures or cube map textures). For example, TxCubeMap
is a type that implements TextureType
, and
it represents cube map textures.
Associated Types
type ImageTargetType: ImageTargetType
The type that is used to indicate all of the possible target 2D images
for this type of texture. The associated ImageTargetType
in the impl
for TxCubeMap
, for example, is
TxCubeMapImageTarget
, which is an
enum with six variants, one for each of the six 2-dimensional images
that make up a cube map.
Required Methods
fn target() -> TextureBindingTarget
The actual variant that represents this type of texture. The
target()
method impl for TxCubeMap
, for
example, returns TextureBindingTarget::CubeMap
.
Implementors
impl TextureType for Tx2d type ImageTargetType = Tx2dImageTarget;
impl TextureType for TxCubeMap type ImageTargetType = TxCubeMapImageTarget;