mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2024-11-21 22:52:20 +00:00
backend/drm: add explicit sync support to libliftoff interface
This commit is contained in:
parent
d7223eae02
commit
0d6284eb62
@ -1646,8 +1646,7 @@ static bool connect_drm_connector(struct wlr_drm_connector *wlr_conn,
|
|||||||
output->non_desktop = non_desktop;
|
output->non_desktop = non_desktop;
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: support sync timelines with libliftoff
|
output->timeline = drm->iface != &legacy_iface;
|
||||||
output->timeline = drm->iface == &atomic_iface;
|
|
||||||
if (drm->parent) {
|
if (drm->parent) {
|
||||||
output->timeline = output->timeline && drm->mgpu_renderer.wlr_rend->features.timeline;
|
output->timeline = output->timeline && drm->mgpu_renderer.wlr_rend->features.timeline;
|
||||||
}
|
}
|
||||||
|
@ -339,6 +339,17 @@ static bool add_connector(drmModeAtomicReq *req,
|
|||||||
liftoff_layer_set_property(crtc->liftoff_composition_layer,
|
liftoff_layer_set_property(crtc->liftoff_composition_layer,
|
||||||
"FB_DAMAGE_CLIPS", state->fb_damage_clips);
|
"FB_DAMAGE_CLIPS", state->fb_damage_clips);
|
||||||
|
|
||||||
|
if (state->primary_in_fence_fd >= 0) {
|
||||||
|
liftoff_layer_set_property(crtc->primary->liftoff_layer,
|
||||||
|
"IN_FENCE_FD", state->primary_in_fence_fd);
|
||||||
|
liftoff_layer_set_property(crtc->liftoff_composition_layer,
|
||||||
|
"IN_FENCE_FD", state->primary_in_fence_fd);
|
||||||
|
}
|
||||||
|
if (state->base->committed & WLR_OUTPUT_STATE_SIGNAL_TIMELINE) {
|
||||||
|
ok = ok && add_prop(req, crtc->id, crtc->props.out_fence_ptr,
|
||||||
|
(uintptr_t)&state->out_fence_fd);
|
||||||
|
}
|
||||||
|
|
||||||
if (state->base->committed & WLR_OUTPUT_STATE_LAYERS) {
|
if (state->base->committed & WLR_OUTPUT_STATE_LAYERS) {
|
||||||
for (size_t i = 0; i < state->base->layers_len; i++) {
|
for (size_t i = 0; i < state->base->layers_len; i++) {
|
||||||
const struct wlr_output_layer_state *layer_state = &state->base->layers[i];
|
const struct wlr_output_layer_state *layer_state = &state->base->layers[i];
|
||||||
|
Loading…
Reference in New Issue
Block a user