kms_vaapi: add cursor capture for amd/intel monitor capture

Always find largest drm buf, to fix some cases
when there are multiple planes and we accidentally
capture a drm buf that isn't the target buf.
We always want the full SCREEN drm buf.
This commit is contained in:
dec05eba
2023-04-22 00:46:48 +02:00
committed by dec05eba
parent 2021456be0
commit e1c613666e
15 changed files with 248 additions and 175 deletions

View File

@@ -15,6 +15,7 @@ typedef struct {
unsigned int texture_id;
vec2i size;
vec2i hotspot;
vec2i position;
bool cursor_image_set;
} gsr_cursor;
@@ -24,5 +25,6 @@ void gsr_cursor_deinit(gsr_cursor *self);
int gsr_cursor_change_window_target(gsr_cursor *self, Window window);
void gsr_cursor_update(gsr_cursor *self, XEvent *xev);
void gsr_cursor_tick(gsr_cursor *self);
#endif /* GSR_CURSOR_H */