learn-wgpu/code/showcase/pong/res/shaders/textured.frag.wgsl

18 lines
279 B
WebGPU Shading Language
Raw Normal View History

2021-10-22 21:55:39 +00:00
struct FragmentOutput {
2022-07-22 17:09:12 +00:00
@location(0) fColor: vec4<f32>,
}
2021-10-22 21:55:39 +00:00
var<private> fColor: vec4<f32>;
2021-12-27 19:09:25 +00:00
fn main_1() {
2021-10-22 21:55:39 +00:00
fColor = vec4<f32>(f32(1));
return;
}
2022-07-22 17:09:12 +00:00
@fragment
2021-10-22 21:55:39 +00:00
fn main() -> FragmentOutput {
2021-12-27 19:09:25 +00:00
main_1();
2022-07-22 17:09:12 +00:00
let _e3: vec4<f32> = fColor;
return FragmentOutput(_e3);
2021-10-22 21:55:39 +00:00
}