Enum glium::uniforms::UniformValue
[−]
[src]
pub enum UniformValue<'a> {
Block(BufferViewAnySlice<'a>, fn(&UniformBlock) -> Result<(), LayoutMismatchError>),
SignedInt(i32),
UnsignedInt(u32),
Float(f32),
Mat2([[f32; 2]; 2]),
Mat3([[f32; 3]; 3]),
Mat4([[f32; 4]; 4]),
Vec2([f32; 2]),
Vec3([f32; 3]),
Vec4([f32; 4]),
Texture1d(&'a Texture1d, Option<SamplerBehavior>),
CompressedTexture1d(&'a CompressedTexture1d, Option<SamplerBehavior>),
SrgbTexture1d(&'a SrgbTexture1d, Option<SamplerBehavior>),
CompressedSrgbTexture1d(&'a CompressedSrgbTexture1d, Option<SamplerBehavior>),
IntegralTexture1d(&'a IntegralTexture1d, Option<SamplerBehavior>),
UnsignedTexture1d(&'a UnsignedTexture1d, Option<SamplerBehavior>),
DepthTexture1d(&'a DepthTexture1d, Option<SamplerBehavior>),
Texture2d(&'a Texture2d, Option<SamplerBehavior>),
CompressedTexture2d(&'a CompressedTexture2d, Option<SamplerBehavior>),
SrgbTexture2d(&'a SrgbTexture2d, Option<SamplerBehavior>),
CompressedSrgbTexture2d(&'a CompressedSrgbTexture2d, Option<SamplerBehavior>),
IntegralTexture2d(&'a IntegralTexture2d, Option<SamplerBehavior>),
UnsignedTexture2d(&'a UnsignedTexture2d, Option<SamplerBehavior>),
DepthTexture2d(&'a DepthTexture2d, Option<SamplerBehavior>),
Texture2dMultisample(&'a Texture2dMultisample, Option<SamplerBehavior>),
SrgbTexture2dMultisample(&'a SrgbTexture2dMultisample, Option<SamplerBehavior>),
IntegralTexture2dMultisample(&'a IntegralTexture2dMultisample, Option<SamplerBehavior>),
UnsignedTexture2dMultisample(&'a UnsignedTexture2dMultisample, Option<SamplerBehavior>),
DepthTexture2dMultisample(&'a DepthTexture2dMultisample, Option<SamplerBehavior>),
Texture3d(&'a Texture3d, Option<SamplerBehavior>),
CompressedTexture3d(&'a CompressedTexture3d, Option<SamplerBehavior>),
SrgbTexture3d(&'a SrgbTexture3d, Option<SamplerBehavior>),
CompressedSrgbTexture3d(&'a CompressedSrgbTexture3d, Option<SamplerBehavior>),
IntegralTexture3d(&'a IntegralTexture3d, Option<SamplerBehavior>),
UnsignedTexture3d(&'a UnsignedTexture3d, Option<SamplerBehavior>),
DepthTexture3d(&'a DepthTexture3d, Option<SamplerBehavior>),
Texture1dArray(&'a Texture1dArray, Option<SamplerBehavior>),
CompressedTexture1dArray(&'a CompressedTexture1dArray, Option<SamplerBehavior>),
SrgbTexture1dArray(&'a SrgbTexture1dArray, Option<SamplerBehavior>),
CompressedSrgbTexture1dArray(&'a CompressedSrgbTexture1dArray, Option<SamplerBehavior>),
IntegralTexture1dArray(&'a IntegralTexture1dArray, Option<SamplerBehavior>),
UnsignedTexture1dArray(&'a UnsignedTexture1dArray, Option<SamplerBehavior>),
DepthTexture1dArray(&'a DepthTexture1dArray, Option<SamplerBehavior>),
Texture2dArray(&'a Texture2dArray, Option<SamplerBehavior>),
CompressedTexture2dArray(&'a CompressedTexture2dArray, Option<SamplerBehavior>),
SrgbTexture2dArray(&'a SrgbTexture2dArray, Option<SamplerBehavior>),
CompressedSrgbTexture2dArray(&'a CompressedSrgbTexture2dArray, Option<SamplerBehavior>),
IntegralTexture2dArray(&'a IntegralTexture2dArray, Option<SamplerBehavior>),
UnsignedTexture2dArray(&'a UnsignedTexture2dArray, Option<SamplerBehavior>),
DepthTexture2dArray(&'a DepthTexture2dArray, Option<SamplerBehavior>),
Texture2dMultisampleArray(&'a Texture2dMultisampleArray, Option<SamplerBehavior>),
SrgbTexture2dMultisampleArray(&'a SrgbTexture2dMultisampleArray, Option<SamplerBehavior>),
IntegralTexture2dMultisampleArray(&'a IntegralTexture2dMultisampleArray, Option<SamplerBehavior>),
UnsignedTexture2dMultisampleArray(&'a UnsignedTexture2dMultisampleArray, Option<SamplerBehavior>),
DepthTexture2dMultisampleArray(&'a DepthTexture2dMultisampleArray, Option<SamplerBehavior>),
}Represents a value to bind to a uniform.
Variants
Block | Contains a handle to the buffer, and a function that indicates whether this buffer
can be binded on a block with the given layout.
The last parameter is a sender which must be used to send a |
SignedInt | |
UnsignedInt | |
Float | |
Mat2 | 2x2 column-major matrix. |
Mat3 | 3x3 column-major matrix. |
Mat4 | 4x4 column-major matrix. |
Vec2 | |
Vec3 | |
Vec4 | |
Texture1d | |
CompressedTexture1d | |
SrgbTexture1d | |
CompressedSrgbTexture1d | |
IntegralTexture1d | |
UnsignedTexture1d | |
DepthTexture1d | |
Texture2d | |
CompressedTexture2d | |
SrgbTexture2d | |
CompressedSrgbTexture2d | |
IntegralTexture2d | |
UnsignedTexture2d | |
DepthTexture2d | |
Texture2dMultisample | |
SrgbTexture2dMultisample | |
IntegralTexture2dMultisample | |
UnsignedTexture2dMultisample | |
DepthTexture2dMultisample | |
Texture3d | |
CompressedTexture3d | |
SrgbTexture3d | |
CompressedSrgbTexture3d | |
IntegralTexture3d | |
UnsignedTexture3d | |
DepthTexture3d | |
Texture1dArray | |
CompressedTexture1dArray | |
SrgbTexture1dArray | |
CompressedSrgbTexture1dArray | |
IntegralTexture1dArray | |
UnsignedTexture1dArray | |
DepthTexture1dArray | |
Texture2dArray | |
CompressedTexture2dArray | |
SrgbTexture2dArray | |
CompressedSrgbTexture2dArray | |
IntegralTexture2dArray | |
UnsignedTexture2dArray | |
DepthTexture2dArray | |
Texture2dMultisampleArray | |
SrgbTexture2dMultisampleArray | |
IntegralTexture2dMultisampleArray | |
UnsignedTexture2dMultisampleArray | |
DepthTexture2dMultisampleArray |
Methods
impl<'a> UniformValue<'a>
fn is_usable_with(&self, ty: &UniformType) -> bool
Returns true if this value can be used with a uniform of the given type.