mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-08-05 11:45:54 +00:00
PromoteInitializersToLet was not handling sem::Materialize nodes. This can happen for const arrays when they are dynamically indexed. Fixed: tint:1653 Change-Id: I3d67d8139e481c89b31a3a30c7ef44384b7545ba Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/99500 Reviewed-by: Dan Sinclair <dsinclair@chromium.org> Commit-Queue: Ben Clayton <bclayton@google.com> Kokoro: Kokoro <noreply+kokoro@google.com>
7 lines
248 B
WebGPU Shading Language
7 lines
248 B
WebGPU Shading Language
const TRI_VERTICES = array(vec4(0.0, 0.0, 0.0, 1.0), vec4(0.0, 1.0, 0.0, 1.0), vec4(1.0, 1.0, 0.0, 1.0));
|
|
|
|
@vertex
|
|
fn vs_main(@builtin(vertex_index) in_vertex_index : u32) -> @builtin(position) vec4<f32> {
|
|
return TRI_VERTICES[in_vertex_index];
|
|
}
|