mirror of
https://github.com/gfx-rs/wgpu.git
synced 2026-04-22 03:02:01 -04:00
7 lines
180 B
WebGPU Shading Language
7 lines
180 B
WebGPU Shading Language
[[stage(vertex)]]
|
|
fn splat() -> [[builtin(position)]] vec4<f32> {
|
|
let a = (1.0 + vec2<f32>(2.0) - 3.0) / 4.0;
|
|
let b = vec4<i32>(5) % 2;
|
|
return a.xyxy + vec4<f32>(b);
|
|
}
|