aboutsummaryrefslogtreecommitdiff
path: root/include/wlr/interfaces
diff options
context:
space:
mode:
authorSimon Ser <contact@emersion.fr>2020-12-02 10:35:27 +0100
committerSimon Ser <contact@emersion.fr>2021-06-02 11:08:52 +0200
commit91ee33e956b42c5390993da95172ee0507baeb2c (patch)
treebd5efacf1f9a34991f04a03715530058b7664c74 /include/wlr/interfaces
parent6430230d1fdab4c056300375606389d2b655f50b (diff)
output: add get_cursor_formats and get_cursor_size to interface
Diffstat (limited to 'include/wlr/interfaces')
-rw-r--r--include/wlr/interfaces/wlr_output.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/include/wlr/interfaces/wlr_output.h b/include/wlr/interfaces/wlr_output.h
index 83f9716f..7b07ea6e 100644
--- a/include/wlr/interfaces/wlr_output.h
+++ b/include/wlr/interfaces/wlr_output.h
@@ -87,6 +87,20 @@ struct wlr_output_impl {
*/
bool (*export_dmabuf)(struct wlr_output *output,
struct wlr_dmabuf_attributes *attribs);
+ /**
+ * Get the list of formats suitable for the cursor, assuming a buffer with
+ * the specified capabilities.
+ *
+ * If unimplemented, the cursor buffer has no format constraint. If NULL is
+ * returned, no format is suitable.
+ */
+ const struct wlr_drm_format_set *(*get_cursor_formats)(
+ struct wlr_output *output, uint32_t buffer_caps);
+ /**
+ * Get the size suitable for the cursor buffer. Attempts to use a different
+ * size for the cursor may fail.
+ */
+ void (*get_cursor_size)(struct wlr_output *output, int *width, int *height);
};
/**