mirror of
https://github.com/hyprwm/wlroots-hyprland.git
synced 2024-12-22 18:09:49 +01: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
1 changed files with 6 additions and 0 deletions
|
@ -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 a new issue