winzik/docker/ext/jumphp-xvfb
David Nurdin 7ce84c932f OpenGL + OpenAL: PHP-OpenGL / PHP-OpenAL (Ponup) in every runtime
- docker/ext/php-opengl.patch: framebuffers, glGetIntegerv/Floatv, uniforms,
  binary strings, non-fatal shader errors, glDelete*, WebGL guards
- desktop, desktop-async and the WebAssembly engine build both extensions
  (WebGL 1 / Web Audio in the browser)
- engine: OpenGl (raw gl* in SDL's context, begin/end, resources), WebGl
  rewritten on top of it (jumphp-gl.js removed), Audio3d (positional sound)
- headless test/shot run GL games on Xvfb (jumphp-xvfb), JUMPHP_GL
- stubs for phpstan (tools/gl-stubs.php)
- hello-webgl: RawGlScene (raw gl* + 3D beep); jumpball: mediump-safe post
- docs: AGENTS.md, api-web, build, READMEs

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-28 16:44:36 +01:00

12 lines
529 B
Shell
Executable file

#!/bin/sh
# jumphp-xvfb <command...>: runs the command with a virtual X display (Xvfb, Mesa llvmpipe OpenGL), for headless
# runs of games that use OpenGL (bin/jumphp test / shot). xvfb-run hangs when the container runs as a plain user.
display=:${JUMPHP_XVFB_DISPLAY:-99}
Xvfb "$display" -screen 0 1280x1024x24 -nolisten tcp >/tmp/xvfb.log 2>&1 &
xvfb=$!
i=0
while [ ! -e "/tmp/.X11-unix/X${display#:}" ] && [ $i -lt 100 ]; do sleep 0.05; i=$((i + 1)); done
DISPLAY=$display "$@"
status=$?
kill "$xvfb" 2>/dev/null
exit $status