From ec37d55a5eb76d6ac516f14ebfead7bfffb6426a Mon Sep 17 00:00:00 2001 From: Austin Shafer Date: Fri, 22 Jul 2022 17:16:41 -0400 Subject: Add union function for format sets --- include/wlr/render/drm_format_set.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'include') diff --git a/include/wlr/render/drm_format_set.h b/include/wlr/render/drm_format_set.h index 6dbdc749..d7dfd779 100644 --- a/include/wlr/render/drm_format_set.h +++ b/include/wlr/render/drm_format_set.h @@ -72,4 +72,12 @@ bool wlr_drm_format_set_add(struct wlr_drm_format_set *set, uint32_t format, bool wlr_drm_format_set_intersect(struct wlr_drm_format_set *dst, const struct wlr_drm_format_set *a, const struct wlr_drm_format_set *b); +/** + * Unions DRM format set `a` and `b`, storing in the destination set + * `dst`. + * + * Returns false on failure. + */ +bool wlr_drm_format_set_union(struct wlr_drm_format_set *dst, + const struct wlr_drm_format_set *a, const struct wlr_drm_format_set *b); #endif -- cgit v1.2.3