2018-07-13 12:40:56 +00:00
|
|
|
/*
|
|
|
|
* This an unstable interface of wlroots. No guarantees are made regarding the
|
|
|
|
* future consistency of this API.
|
|
|
|
*/
|
|
|
|
#ifndef WLR_USE_UNSTABLE
|
|
|
|
#error "Add -DWLR_USE_UNSTABLE to enable unstable wlroots features"
|
|
|
|
#endif
|
|
|
|
|
2018-06-19 18:07:29 +00:00
|
|
|
#ifndef WLR_TYPES_WLR_SCREENCOPY_V1_H
|
|
|
|
#define WLR_TYPES_WLR_SCREENCOPY_V1_H
|
|
|
|
|
2018-09-17 13:07:08 +00:00
|
|
|
#include <stdbool.h>
|
2019-07-27 08:53:54 +00:00
|
|
|
#include <wayland-server-core.h>
|
2021-07-01 20:36:01 +00:00
|
|
|
#include <wlr/util/box.h>
|
2018-06-19 18:07:29 +00:00
|
|
|
|
|
|
|
struct wlr_screencopy_manager_v1 {
|
|
|
|
struct wl_global *global;
|
|
|
|
struct wl_list frames; // wlr_screencopy_frame_v1::link
|
|
|
|
|
|
|
|
struct wl_listener display_destroy;
|
|
|
|
|
2018-08-26 21:23:12 +00:00
|
|
|
struct {
|
|
|
|
struct wl_signal destroy;
|
|
|
|
} events;
|
|
|
|
|
2018-06-19 18:07:29 +00:00
|
|
|
void *data;
|
|
|
|
};
|
|
|
|
|
2019-10-19 14:46:43 +00:00
|
|
|
struct wlr_screencopy_v1_client {
|
|
|
|
int ref;
|
|
|
|
struct wlr_screencopy_manager_v1 *manager;
|
|
|
|
struct wl_list damages;
|
|
|
|
};
|
|
|
|
|
2018-06-19 18:07:29 +00:00
|
|
|
struct wlr_screencopy_frame_v1 {
|
|
|
|
struct wl_resource *resource;
|
2019-10-19 14:46:43 +00:00
|
|
|
struct wlr_screencopy_v1_client *client;
|
2018-06-19 18:07:29 +00:00
|
|
|
struct wl_list link;
|
|
|
|
|
2018-06-23 17:41:40 +00:00
|
|
|
enum wl_shm_format format;
|
2020-04-22 23:24:19 +00:00
|
|
|
uint32_t fourcc;
|
2018-06-23 17:41:40 +00:00
|
|
|
struct wlr_box box;
|
|
|
|
int stride;
|
2018-06-19 18:07:29 +00:00
|
|
|
|
2018-09-17 13:07:08 +00:00
|
|
|
bool overlay_cursor, cursor_locked;
|
|
|
|
|
2019-10-19 14:46:43 +00:00
|
|
|
bool with_damage;
|
|
|
|
|
2020-04-22 23:24:19 +00:00
|
|
|
struct wl_shm_buffer *shm_buffer;
|
|
|
|
struct wlr_dmabuf_v1_buffer *dma_buffer;
|
|
|
|
|
2018-06-23 18:06:10 +00:00
|
|
|
struct wl_listener buffer_destroy;
|
2018-06-19 18:07:29 +00:00
|
|
|
|
|
|
|
struct wlr_output *output;
|
2020-11-04 15:03:54 +00:00
|
|
|
struct wl_listener output_commit;
|
2019-07-27 23:31:37 +00:00
|
|
|
struct wl_listener output_destroy;
|
|
|
|
struct wl_listener output_enable;
|
2018-06-19 18:07:29 +00:00
|
|
|
|
|
|
|
void *data;
|
|
|
|
};
|
|
|
|
|
|
|
|
struct wlr_screencopy_manager_v1 *wlr_screencopy_manager_v1_create(
|
|
|
|
struct wl_display *display);
|
|
|
|
|
|
|
|
#endif
|