The default limit of 1ms might be too short if the compositor
calls liftoff_output_apply() early in the vblank cycle, or too
long if the refresh rate is high. The compositor is in a better
spot to decide how much time should be spent on atomic tests, so
add an option for that.
Closes: https://gitlab.freedesktop.org/emersion/libliftoff/-/issues/78
Right now, compositors are expected to query liftoff_layer_get_plane_id to
decide whether a layer needs to be composited.
However there are cases where a layer has no plane, but still doesn't need
composition (e.g. when FB_ID is zero or when alpha is zero, in the future when
the layer is out of CRTC bounds etc).
Add a new API to make users' life simpler.
Closes: https://github.com/emersion/libliftoff/issues/54
When the caller wants to perform a modeset, they will need to pass
DRM_MODE_ATOMIC_ALLOW_MODESET in the atomic commit flags, otherwise the driver
will fail the commit. libliftoff also needs to provide these flags in its
test-only commits.
This fixes a misunderstanding of the DRM API. Only a regular commit applies
properties.
Fixes: b16078769e ("test/libdrm_mock: a test-only commit applies properties")