mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-06-02 04:31:26 +00:00
Add a config parameter for the CanonicalizeEntryPoint transform that selects between emitting builtins as parameters (for MSL) or struct members (for HLSL). This fixes all of the shader IO issues in Tint's E2E tests for MSL. Fixed: tint:817 Change-Id: Ieb31cdbd2e4d96ac41f8d8515fd07ead8241d770 Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/53282 Kokoro: Kokoro <noreply+kokoro@google.com> Reviewed-by: Ben Clayton <bclayton@google.com> Commit-Queue: James Price <jrprice@google.com>
14 lines
345 B
Plaintext
14 lines
345 B
Plaintext
#include <metal_stdlib>
|
|
|
|
using namespace metal;
|
|
struct tint_symbol_2 {
|
|
float4 value [[position]];
|
|
};
|
|
|
|
vertex tint_symbol_2 tint_symbol(uint vertex_index [[vertex_id]], uint instance_index [[instance_id]]) {
|
|
uint const foo = (vertex_index + instance_index);
|
|
tint_symbol_2 const tint_symbol_3 = {.value=float4()};
|
|
return tint_symbol_3;
|
|
}
|
|
|