mirror of
https://github.com/DeeJanuz/frametop.git
synced 2026-10-06 01:00:06 +02:00
The panel drew each picture with SetOverlayRaw, a new texture upload every time: the full calibration's 1024x768 picture flickered on every change, and in a live test the headset kept showing the last calibration picture after the panel had drawn the fit check (2026-10-01). Now, as screens/keyboard.cpp does, it writes into three linear DMA-BUFs SteamVR imported once (the size of the biggest panel; texture bounds show the part in use) and switches between them. A show makes the overlay visible once its first picture is in. The full calibration's and the five-dot check's dots wait for a left click or Meta+J while you look at the dot, in place of capturing any steady gaze (which can be a look somewhere else); no capture ring, no 8 s skip, and the check closes after 2 minutes without a click. The quick check still captures itself. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
21 lines
1.6 KiB
Bash
Executable File
21 lines
1.6 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
# Build ft-gaze and the calibration panel ft-gazepanel in the dev container on the Frame
|
|
# (gaze/build/; they also run there). The panel draws its text with stb_truetype (public
|
|
# domain, one header, pinned as in screens/build.sh).
|
|
# The eye tracking API (IVRInput::GetEyeTrackingDataRelativeToNow) is newer than the header
|
|
# shipped with SteamVR's samples, so this uses the pinned public header ft-screens fetches.
|
|
set -euo pipefail
|
|
root=$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)
|
|
"$root/scripts/sync.sh" >/dev/null
|
|
exec "$root/scripts/frame.sh" -C gaze 'set -e; mkdir -p build/include
|
|
openvr=v2.15.6
|
|
[ -f build/include/openvr-$openvr ] || { curl -fsSL "https://raw.githubusercontent.com/ValveSoftware/openvr/$openvr/headers/openvr.h" -o build/include/openvr.h && touch build/include/openvr-$openvr; }
|
|
g++ -std=c++17 -O2 -Wall -Wno-unused-parameter -Wno-missing-field-initializers -Ibuild/include -I../pointer/common \
|
|
-o build/ft-gaze ft-gaze.cpp -L/opt/steamvr/bin/linuxarm64 -lopenvr_api -Wl,-rpath,/opt/steamvr/bin/linuxarm64 -lpthread
|
|
stb=2c980bb59875b0d32144a71867fbdebb2f77cd20
|
|
[ -f build/include/stb-$stb ] || { curl -fsSL "https://raw.githubusercontent.com/nothings/stb/$stb/stb_truetype.h" -o build/include/stb_truetype.h && touch build/include/stb-$stb; }
|
|
g++ -std=c++17 -O2 -Wall -Wno-unused-parameter -Wno-missing-field-initializers -Ibuild/include $(pkg-config --cflags gbm libdrm) \
|
|
-o build/ft-gazepanel panel/ft-gazepanel.cpp -L/opt/steamvr/bin/linuxarm64 -lopenvr_api -Wl,-rpath,/opt/steamvr/bin/linuxarm64 \
|
|
$(pkg-config --libs gbm libdrm) -lpthread
|
|
echo "built build/ft-gaze build/ft-gazepanel"'
|