mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-08-06 12:15:43 +00:00
Don't generate them either, which generated a lot of test churn. Fixed: tint:1380 Change-Id: I0a7cfdd2ef0ffe8e7fda111fbc57997b36b949e0 Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/77165 Auto-Submit: James Price <jrprice@google.com> Reviewed-by: Ben Clayton <bclayton@google.com> Kokoro: Kokoro <noreply+kokoro@google.com>
15 lines
466 B
WebGPU Shading Language
15 lines
466 B
WebGPU Shading Language
struct Result {
|
|
values : array<f32>;
|
|
}
|
|
|
|
let width : u32 = 128u;
|
|
|
|
[[group(0), binding(0)]] var tex : texture_depth_2d;
|
|
|
|
[[group(0), binding(1)]] var<storage, read_write> result : Result;
|
|
|
|
[[stage(compute), workgroup_size(1)]]
|
|
fn main([[builtin(global_invocation_id)]] GlobalInvocationId : vec3<u32>) {
|
|
result.values[((GlobalInvocationId.y * width) + GlobalInvocationId.x)] = textureLoad(tex, vec2<i32>(i32(GlobalInvocationId.x), i32(GlobalInvocationId.y)), 0);
|
|
}
|