Pong/resources/shaders/Compile.sh
Karutoh b905a949f2
Some checks failed
Build & Release / Linux-AARCH64-Build (push) Failing after 1m29s
Build & Release / Windows-AMD64-Build (push) Failing after 1m40s
Build & Release / Linux-AMD64-Build (push) Successful in 3m5s
Added CI/CD.
2024-07-01 19:55:24 -07:00

26 lines
474 B
Bash

#!/bin/bash
for file in ./*.vert; do
if [ -f "$file" ]; then
filename=$(basename -- "$file")
echo "Compiling vertex shader, ${filename}"
filename="${filename%.*}"
glslangValidator -V "${file}" -o "./${filename}_Vert.spv"
fi
done
for file in ./*.frag; do
if [ -f "$file" ]; then
filename=$(basename -- "$file")
echo "Compiling vertex shader, ${filename}"
filename="${filename%.*}"
glslangValidator -V "${file}" -o "./${filename}_Frag.spv"
fi
done