1
0

Added shader file name as 4th command-line argument.

This commit is contained in:
m11
2026-02-04 19:36:45 +01:00
parent 41b04481aa
commit f949adbbcc

View File

@@ -1,6 +1,14 @@
#!/bin/bash
if [[ -n "$4" ]]; then
shaderfile="shaders/${4}.frag"
if [[ ! -f "$shaderfile" ]]; then
echo "Error: shader file '$shaderfile' does not exist." >&2
exit 1
fi
else
shaderfile="$(shuf -n1 -e shaders/*)"
fi
export EGL_PLATFORM=surfaceless
export MESA_GL_VERSION_OVERRIDE=3.3