2021-06-03 09:38:34 +00:00
|
|
|
struct FragmentInputs {
|
|
|
|
[[builtin(position)]]
|
|
|
|
position : vec4<f32>;
|
|
|
|
[[builtin(front_facing)]]
|
|
|
|
front_facing : bool;
|
|
|
|
[[builtin(sample_index)]]
|
|
|
|
sample_index : u32;
|
|
|
|
[[builtin(sample_mask)]]
|
|
|
|
sample_mask : u32;
|
2022-01-19 18:11:17 +00:00
|
|
|
}
|
2021-06-03 09:38:34 +00:00
|
|
|
|
|
|
|
[[stage(fragment)]]
|
|
|
|
fn main(inputs : FragmentInputs) {
|
|
|
|
if (inputs.front_facing) {
|
|
|
|
let foo : vec4<f32> = inputs.position;
|
|
|
|
let bar : u32 = (inputs.sample_index + inputs.sample_mask);
|
|
|
|
}
|
|
|
|
}
|