#[repr(u32)]pub enum MaterialParam {
Show 16 variants
Unknown = 0,
Float = 1,
Color128 = 2,
Vec2 = 3,
Vec3 = 4,
Vec4 = 5,
Matrix = 6,
Texture = 7,
Int = 8,
Int2 = 9,
Int3 = 10,
Int4 = 11,
UInt = 12,
UInt2 = 13,
UInt3 = 14,
UInt4 = 15,
}
Expand description
TODO: v0.4 This may need significant revision? What type of data does this material parameter need? This is used to tell the shader how large the data is, and where to attach it to on the shader. https://stereokit.net/Pages/StereoKit/MaterialParam.html
Variants§
Unknown = 0
This data type is not currently recognized. Please report your case on GitHub Issues!
Float = 1
A single 32 bit float value
Color128 = 2
A color value described by 4 floating point values. Memory-wise this is the same as a Vector4, but in the shader this variable has a ‘:color’ tag applied to it using StereoKits’s shader info syntax, indicating it’s a color value. Color values for shaders should be in linear space, not gamma.
Vec2 = 3
A 2 component vector composed of floating point values
Vec3 = 4
A 3 component vector composed of floating point values
Vec4 = 5
A 4 component vector composed of floating point values
Matrix = 6
A 4x4 matrix of floats.
Texture = 7
Texture information!
Int = 8
An i32, or 1 component array composed of i32 values
Int2 = 9
A 2 component array composed of i32 values
Int3 = 10
A 3 component array composed of i32 values
Int4 = 11
A 4 component array composed of i32 values
UInt = 12
A u32, or 1 component array composed of u32 values
UInt2 = 13
A 2 component array composed of u32 values
UInt3 = 14
A 3 component array composed of u32 values
UInt4 = 15
A 4 component array composed of u32 values
Trait Implementations§
Source§impl Clone for MaterialParam
impl Clone for MaterialParam
Source§fn clone(&self) -> MaterialParam
fn clone(&self) -> MaterialParam
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more