commit | ca9f38634fcf3f782eb59db1894046aa117e857a | [log] [tgz] |
---|---|---|
author | Stephen White <senorblanco@chromium.org> | Wed Feb 07 18:08:23 2024 +0000 |
committer | Dawn LUCI CQ <dawn-scoped@luci-project-accounts.iam.gserviceaccount.com> | Wed Feb 07 18:08:23 2024 +0000 |
tree | 0dd22fa65b04fcab1a9d4830edc20bffc2d2d751 | |
parent | c11e2ed2572c4ea87355112d48a990c10951df07 [diff] [blame] |
GLSL: set integers to precision highp. In GLSL fragment shaders, int and uint default to mediump, which has implementation-defined precision. This means that a push constant block shared between vertex and fragment shader containing an integer type will error at link time. WGSL mandates that i32 and i32 are 32-bit (natch), so force fragment shader integers to highp, as we were already doing for floats. highp is guaranteed to be 32-bit in GLSL. Change-Id: I50c7bfafa5c28cb645ff50fbb7eff1ecdb578fcb Bug: dawn:2185 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/173802 Reviewed-by: Ben Clayton <bclayton@google.com> Commit-Queue: Stephen White <senorblanco@chromium.org> Kokoro: Kokoro <noreply+kokoro@google.com>
diff --git a/test/tint/builtins/gen/literal/textureSample/2149ec.wgsl.expected.glsl b/test/tint/builtins/gen/literal/textureSample/2149ec.wgsl.expected.glsl index 3906bb3..85ac0e5 100644 --- a/test/tint/builtins/gen/literal/textureSample/2149ec.wgsl.expected.glsl +++ b/test/tint/builtins/gen/literal/textureSample/2149ec.wgsl.expected.glsl
@@ -1,5 +1,6 @@ #version 310 es precision highp float; +precision highp int; uniform highp sampler3D arg_0_arg_1;