#[non_exhaustive]pub enum Uniform<'a> {
Float(FVec4),
Float2([FVec4; 2]),
Float3([FVec4; 3]),
Float4(Matrix4),
FloatArray(&'a [FVec4]),
Float4Array(&'a [Matrix4]),
Bool(bool),
Int(IVec),
GlamFloatArray(&'a [Vec4]),
GlamMatrixArray(&'a [Mat4]),
}Expand description
A uniform which may be bound as input to a shader program
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Float(FVec4)
Single float uniform (.fvec name)
Float2([FVec4; 2])
Two element float uniform (.fvec name[2])
Float3([FVec4; 3])
Three element float uniform (.fvec name[3])
Float4(Matrix4)
Matrix/4 element float uniform (.fvec name[4])
FloatArray(&'a [FVec4])
Uniform of an arbitrary number of floats (.fvec name[X])
Float4Array(&'a [Matrix4])
Uniform of an arbitrary number of Matrices/4x floats (.fvec name[X])
Bool(bool)
Bool uniform (.bool name)
Int(IVec)
Integer uniform (.ivec name)
GlamFloatArray(&'a [Vec4])
GlamMatrixArray(&'a [Mat4])
Implementations§
Trait Implementations§
impl<'a> Copy for Uniform<'a>
impl<'a> StructuralPartialEq for Uniform<'a>
Auto Trait Implementations§
impl<'a> Freeze for Uniform<'a>
impl<'a> RefUnwindSafe for Uniform<'a>
impl<'a> Send for Uniform<'a>
impl<'a> Sync for Uniform<'a>
impl<'a> Unpin for Uniform<'a>
impl<'a> UnwindSafe for Uniform<'a>
Blanket Implementations§
§impl<T> Any for Twhere
T: 'static + ?Sized,
impl<T> Any for Twhere
T: 'static + ?Sized,
§impl<T> Borrow<T> for Twhere
T: ?Sized,
impl<T> Borrow<T> for Twhere
T: ?Sized,
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit)