mirror of
https://github.com/gfx-rs/wgpu.git
synced 2024-11-23 23:34:29 +00:00
13 lines
299 B
Plaintext
13 lines
299 B
Plaintext
#include <metal_stdlib>
|
|
#include <simd/simd.h>
|
|
|
|
|
|
struct splatOutput {
|
|
metal::float4 member [[position]];
|
|
};
|
|
vertex splatOutput splat(
|
|
) {
|
|
metal::float2 _e10 = ((1.0 + 2.0) - 3.0) / 4.0;
|
|
return splatOutput { metal::float4(_e10.x, _e10.y, _e10.x, _e10.y) + static_cast<float4>(5 % 2) };
|
|
}
|