mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-11-15 06:59:43 -05:00
backend/drm: fix hardware cursors not moving
This adds back `wlr_output::needs_swap`. This allows a backend to request buffer swaps even if the output isn't damaged. This is needed by the DRM backend to trigger pageflips when the cursor moves.
This commit is contained in:
parent
bc001e90e9
commit
4ca38b84ed
6 changed files with 43 additions and 19 deletions
|
|
@ -16,11 +16,11 @@ struct roots_output {
|
|||
|
||||
struct timespec last_frame;
|
||||
pixman_region32_t damage, previous_damage;
|
||||
bool frame_scheduled;
|
||||
bool frame_pending;
|
||||
|
||||
struct wl_listener frame;
|
||||
struct wl_listener mode;
|
||||
struct wl_listener damage_listener;
|
||||
struct wl_listener needs_swap;
|
||||
};
|
||||
|
||||
void output_add_notify(struct wl_listener *listener, void *data);
|
||||
|
|
|
|||
|
|
@ -32,5 +32,6 @@ void wlr_output_update_mode(struct wlr_output *output,
|
|||
void wlr_output_update_custom_mode(struct wlr_output *output, int32_t width,
|
||||
int32_t height, int32_t refresh);
|
||||
void wlr_output_update_enabled(struct wlr_output *output, bool enabled);
|
||||
void wlr_output_update_needs_swap(struct wlr_output *output);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -54,6 +54,7 @@ struct wlr_output {
|
|||
enum wl_output_subpixel subpixel;
|
||||
enum wl_output_transform transform;
|
||||
|
||||
bool needs_swap;
|
||||
pixman_region32_t damage, previous_damage;
|
||||
float transform_matrix[16];
|
||||
|
||||
|
|
@ -64,8 +65,8 @@ struct wlr_output {
|
|||
int32_t refresh; // mHz
|
||||
|
||||
struct {
|
||||
struct wl_signal damage;
|
||||
struct wl_signal frame;
|
||||
struct wl_signal needs_swap;
|
||||
struct wl_signal swap_buffers;
|
||||
struct wl_signal enable;
|
||||
struct wl_signal mode;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue