mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2024-11-21 22:52:20 +00:00
drm_plane_pick_render_format: return false if no format could be found
Commit 90d08f8f1c
changed the way
wlr_drm_format_intersect worked, including passing in a destination
format list. This breaks scenarios where the intersection doesn't
find any matching formats, since we still have a valid destination
format set. This changes it to only return true if more than one
matching format is present in the intersection list.
This commit is contained in:
parent
3dc5c7e5e7
commit
0910fa9179
@ -177,6 +177,12 @@ bool drm_plane_pick_render_format(struct wlr_drm_plane *plane,
|
||||
return false;
|
||||
}
|
||||
|
||||
if (fmt->len == 0) {
|
||||
wlr_drm_format_finish(fmt);
|
||||
wlr_log(WLR_DEBUG, "Failed to find matching plane and renderer modifiers");
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user