Two faults found on the first run against a real DXGI multi-monitor host,
each of which left the composed view black while every geometry check
passed:
- Compose setup ran on the frame thread via onFrameFormat, but the VAO and
FBO it creates are container objects that only exist in the creating
context. The render thread drew with empty ones. Setup is now deferred to
the render thread and picked up before the next draw
(composeSetupPending), and a post-process pass is forced afterwards so a
frame that arrived before setup completed is not presented stale.
- A DMA-imported atlas is an external image and must be sampled with
samplerExternalOES. Compose only compiled the plain sampler2D variant, so
the DMA path sampled black. Both variants are now compiled and setup
selects one, mirroring what the desktop shaders already do.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WxYTZ8oBdHX3YrHGgdLKwC
build / host-windows-cross (push) Failing after 17s
build / obs (clang) (push) Failing after 18s
build / docs (push) Failing after 7s
build / obs (gcc) (push) Failing after 20s
build / host-windows-native (push) Canceled after 0s
build / idd (push) Canceled after 0s
Capture every guest display into a single frame and compose it back into
the guest's desktop on the client, so one Looking Glass session can carry
a multi-monitor guest instead of one instance per display.
KVMFR gains a per-frame display layout (version 24). A frame with
displayCount == 0 is a conventional single-display frame and behaves
exactly as before, so existing capture backends are unaffected.
- common: shared display layout and a shelf packer that minimises atlas
area, plus atlas/desktop coordinate mapping helpers and unit tests
- host: capture interface and host app carry the layout; a layout change
invalidates the format so clients re-read it
- host/XCB: enumerate RandR monitors and repack the root window into the
atlas directly in shared memory
- client/EGL: compose the atlas into the presented view as its own pass,
leaving post processing, HDR, cursor and damage handling unchanged
Also fixes the XCB backend writing a single row per frame instead of the
whole image.