aboutsummaryrefslogtreecommitdiff
path: root/include/wlr
diff options
context:
space:
mode:
authorSimon Ser <contact@emersion.fr>2021-06-29 17:08:32 +0200
committerSimon Zeni <simon@bl4ckb0ne.ca>2021-09-10 13:16:10 -0400
commit4e7a8707cce75b4cdc046581ec0c1cc7c0c26e02 (patch)
tree34d086a258df5567d832e28d4622e19ec3517354 /include/wlr
parent105fdecd0cd893c4ae1e21f78c67404f70859af8 (diff)
buffer: add data_ptr access flags
This allows callers to specify the operations they'll perform on the returned data pointer. The motivations for this are: - The upcoming Linux MAP_NOSIGBUS flag may only be usable on read-only mappings. - gbm_bo_map with GBM_BO_TRANSFER_READ hurts performance.
Diffstat (limited to 'include/wlr')
-rw-r--r--include/wlr/types/wlr_buffer.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/wlr/types/wlr_buffer.h b/include/wlr/types/wlr_buffer.h
index c714ddb6..6bf3c97b 100644
--- a/include/wlr/types/wlr_buffer.h
+++ b/include/wlr/types/wlr_buffer.h
@@ -30,8 +30,8 @@ struct wlr_buffer_impl {
struct wlr_dmabuf_attributes *attribs);
bool (*get_shm)(struct wlr_buffer *buffer,
struct wlr_shm_attributes *attribs);
- bool (*begin_data_ptr_access)(struct wlr_buffer *buffer, void **data,
- uint32_t *format, size_t *stride);
+ bool (*begin_data_ptr_access)(struct wlr_buffer *buffer, uint32_t flags,
+ void **data, uint32_t *format, size_t *stride);
void (*end_data_ptr_access)(struct wlr_buffer *buffer);
};