wlroots headers can mostly be included with extern "C" blocks. Two
exceptions are the use of `static` for array args and `class` as a
struct field. These can be #define'ed to avoid C++ build errors.
This allows the whole project to be built as a single C++ codebase,
without having to maintain hybrid header files.
- Add a commit wait thread that just waits for the work associated with
an in-bound dma-buff is done. We'd like to be getting a fence directly
from Wayland, but in the absence of that we'll make our own by tapping
into implicit-sync, DX11-style. gpuvis logging of the outcome of the
waits in the thread are consistent with the end of GPU work.
- Rework wayland commit handoff between wlserver and steamcompmgr to let
steamcompmgr have full access to the commit queue, letting it remove
elements in the middle and still keep going, compared to the previous
interface. This lets steamcompmgr get one commit per window per loop,
for now. We should be able to kick off waits and ref/unref resources
for all pending commits soon, with some work on the accounting first.
This should also fix an issue introduced recently where the overlay
could get really starved in embedded mode, as we were just getting
the first commit in the queue for a single frame.
Use an empty dummy texture for unbound slots, as the driver can't know
what the shader will sample from.
Also remove any sort of implicit attempts at compaction of slots.
Import libliftoff as subproject and plumb our planes through it.
Wait for a flip to complete immediately after queuing it for now.
Also immediately wait for cursor image uploads, as we don't have to
do Vulkan rendering anymore after queuing an upload.
Cursor shows up with format hack, but is badly corrupt. We might need
to use a DRM dumb_fb rather than going through the same Vulkan image.
Alpha bits of surfaces are ignored again, need to make Steam select
an ARGB visual for overlay windows, probably.
Setting up the "alpha" plane property somehow makes overlays not
show up at all despite liftoff happily letting us go with scanout.
We're in sole control of the cursor now, there's no "fake" cursor anymore.
Don't attempt to hide it in X, it doesn't matter.
Also Vulkan rendering of a texture populated from arbitrary bits.
Also add the third layer to the shader... Badly needs clean-up.
Doesn't help running out right now, as the DMA-BUFs from a new app
frame get imported as different Vulkan textures. Not sure how to
ensure continuity across several sightings of the original swapchain
images yet.