feat: record at the source's size, only once capture works
Rust checks / windows-cross-check (push) Successful in 41s
Rust checks / linux (push) Failing after 5m37s

Encoders and the segment output are created when the capture source first
has a picture, at its own size (portrait monitors record portrait) unless a
resolution is configured, so nothing is written while waiting for a source.
SPEC.md records both decisions; validation docs cover how sessions should end
when the game closes.
This commit is contained in:
2026-10-08 15:34:42 +02:00
parent 96590e9c4a
commit 795118c200
9 changed files with 448 additions and 260 deletions
+4 -2
View File
@@ -101,13 +101,15 @@ else
result "${name}" 1
fi
# 8. The portal refuses the request: an actionable failure, never Recording.
# 8. The portal refuses the request: an actionable failure, never Recording,
# and no footage written (output starts only once capture has a picture).
name=portal-refused
CLIPBIN_RIG_PORTAL_OUTPUT=NO-SUCH-OUTPUT "${rig}" "${probe}" record --seconds 8 --out "${out}/${name}" \
> "${out}/${name}.log" 2>&1
probe_exit=$?
if [[ "${probe_exit}" != 0 ]] && ! has "${out}/${name}.log" "status=Recording" \
&& has "${out}/${name}.log" "status=failed reason=screen capture was not allowed"; then
&& has "${out}/${name}.log" "status=failed reason=screen capture was not allowed" \
&& [[ -z "$(ls -A "${out}/${name}/session" 2>/dev/null)" ]]; then
result "${name}" 0 "$(grep -m1 -o 'status=failed reason=.*' "${out}/${name}.log")"
else
result "${name}" 1