Description
The motivation is to enable one glsl shader file that includes both vertex and fragment stages separated through preprocessing. This matches the behaviour of glslangValidator
cargo run -- my_shader.glsl my_shader.frag.wgsl --shader-stage fragment --entry-point main -D FRAGMENT_SHADER
cargo run -- my_shader.glsl my_shader.vert.wgsl --shader-stage vertex --entry-point main -D VERTEX_SHADER
Checklist
[x] Run cargo fmt.
[x] Run cargo clippy. If applicable, add:
[ ] --target wasm32-unknown-unknown
[ ] --target wasm32-unknown-emscripten
[x] Run cargo xtask test to run tests.
[x] Add change to CHANGELOG.md. See simple instructions inside file.
Description The motivation is to enable one glsl shader file that includes both vertex and fragment stages separated through preprocessing. This matches the behaviour of
glslangValidator
Example of this particular glsl shader:
Testing
Checklist
cargo fmt
.cargo clippy
. If applicable, add:--target wasm32-unknown-unknown
--target wasm32-unknown-emscripten
cargo xtask test
to run tests.CHANGELOG.md
. See simple instructions inside file.