pub enum BuiltIn {
Show 32 variants
Position {
invariant: bool,
},
ViewIndex,
BaseInstance,
BaseVertex,
ClipDistance,
CullDistance,
InstanceIndex,
PointSize,
VertexIndex,
DrawID,
FragDepth,
PointCoord,
FrontFacing,
PrimitiveIndex,
Barycentric,
SampleIndex,
SampleMask,
GlobalInvocationId,
LocalInvocationId,
LocalInvocationIndex,
WorkGroupId,
WorkGroupSize,
NumWorkGroups,
NumSubgroups,
SubgroupId,
SubgroupSize,
SubgroupInvocationId,
MeshTaskSize,
CullPrimitive,
PointIndex,
LineIndices,
TriangleIndices,
}Expand description
Built-in inputs and outputs.
Variants§
Position
Written in vertex/mesh shaders, read in fragment shaders
ViewIndex
Read in task, mesh, vertex, and fragment shaders
BaseInstance
Read in vertex shaders
BaseVertex
Read in vertex shaders
ClipDistance
Written in vertex & mesh shaders
CullDistance
Written in vertex & mesh shaders
InstanceIndex
Read in vertex shaders
PointSize
Written in vertex & mesh shaders
VertexIndex
Read in vertex shaders
DrawID
Read in vertex & task shaders, or mesh shaders in pipelines without task shaders
FragDepth
Written in fragment shaders
PointCoord
Read in fragment shaders
FrontFacing
Read in fragment shaders
PrimitiveIndex
Read in fragment shaders, in the future may written in mesh shaders
Barycentric
Read in fragment shaders
SampleIndex
Read in fragment shaders
SampleMask
Read or written in fragment shaders
GlobalInvocationId
Read in compute, task, and mesh shaders
LocalInvocationId
Read in compute, task, and mesh shaders
LocalInvocationIndex
Read in compute, task, and mesh shaders
WorkGroupId
Read in compute, task, and mesh shaders
WorkGroupSize
Read in compute, task, and mesh shaders
NumWorkGroups
Read in compute, task, and mesh shaders
NumSubgroups
Read in compute, task, and mesh shaders
SubgroupId
Read in compute, task, and mesh shaders
SubgroupSize
Read in compute, fragment, task, and mesh shaders
SubgroupInvocationId
Read in compute, fragment, task, and mesh shaders
MeshTaskSize
Written in task shaders
CullPrimitive
Written in mesh shaders
PointIndex
Written in mesh shaders
LineIndices
Written in mesh shaders
TriangleIndices
Written in mesh shaders
Implementations§
Trait Implementations§
Source§impl<'arbitrary> Arbitrary<'arbitrary> for BuiltIn
impl<'arbitrary> Arbitrary<'arbitrary> for BuiltIn
Source§fn arbitrary(u: &mut Unstructured<'arbitrary>) -> Result<Self>
fn arbitrary(u: &mut Unstructured<'arbitrary>) -> Result<Self>
Self from the given unstructured data. Read moreSource§fn arbitrary_take_rest(u: Unstructured<'arbitrary>) -> Result<Self>
fn arbitrary_take_rest(u: Unstructured<'arbitrary>) -> Result<Self>
Self from the entirety of the given
unstructured data. Read moreSource§impl<'de> Deserialize<'de> for BuiltIn
impl<'de> Deserialize<'de> for BuiltIn
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl Ord for BuiltIn
impl Ord for BuiltIn
Source§impl PartialOrd for BuiltIn
impl PartialOrd for BuiltIn
Source§impl TryToWgsl for BuiltIn
impl TryToWgsl for BuiltIn
Source§const DESCRIPTION: &'static str = "builtin value"
const DESCRIPTION: &'static str = "builtin value"
Self represents.Source§fn try_to_wgsl(self) -> Option<&'static str>
fn try_to_wgsl(self) -> Option<&'static str>
impl Copy for BuiltIn
impl Eq for BuiltIn
impl StructuralPartialEq for BuiltIn
Auto Trait Implementations§
impl Freeze for BuiltIn
impl RefUnwindSafe for BuiltIn
impl Send for BuiltIn
impl Sync for BuiltIn
impl Unpin for BuiltIn
impl UnwindSafe for BuiltIn
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.