render/timeline: add wlr_render_timeline_import_dmabuf

Same as wlr_render_timeline_import_sync_file, but takes a DMA-BUF
as argument. Depends on [1].

[1]: https://lore.kernel.org/dri-devel/20210610210925.642582-5-jason@jlekstrand.net/
This commit is contained in:
Simon Ser 2021-10-20 19:01:40 +02:00
parent 5a1f18666a
commit 7a661e4c38
2 changed files with 42 additions and 1 deletions

View file

@ -56,5 +56,16 @@ int wlr_render_timeline_export_sync_file(struct wlr_render_timeline *timeline,
*/
bool wlr_render_timeline_import_sync_file(struct wlr_render_timeline *timeline,
uint64_t dst_point, int sync_file_fd);
/**
* Import a timeline point from a DMA-BUF's implicit fence.
*
* The provided timeline point will be signalled when the DMA-BUF's producer
* has finished their write operations.
*
* This allows inter-operation with other APIs which don't support drm_syncobj
* nor sync_file yet.
*/
bool wlr_render_timeline_import_dmabuf(struct wlr_render_timeline *timeline,
uint64_t dst_point, int dmabuf_fd);
#endif