diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/wlr/interfaces/wlr_output.h | 2 | ||||
-rw-r--r-- | include/wlr/render.h | 2 | ||||
-rw-r--r-- | include/wlr/render/interface.h | 2 | ||||
-rw-r--r-- | include/wlr/types/wlr_output.h | 10 |
4 files changed, 14 insertions, 2 deletions
diff --git a/include/wlr/interfaces/wlr_output.h b/include/wlr/interfaces/wlr_output.h index 0949bca3..5f9bfdd2 100644 --- a/include/wlr/interfaces/wlr_output.h +++ b/include/wlr/interfaces/wlr_output.h @@ -13,6 +13,8 @@ struct wlr_output_impl { const uint8_t *buf, int32_t stride, uint32_t width, uint32_t height); bool (*move_cursor)(struct wlr_output_state *state, int x, int y); void (*destroy)(struct wlr_output_state *state); + void (*make_current)(struct wlr_output_state *state); + void (*swap_buffers)(struct wlr_output_state *state); }; struct wlr_output *wlr_output_create(struct wlr_output_impl *impl, diff --git a/include/wlr/render.h b/include/wlr/render.h index bb333723..30648a20 100644 --- a/include/wlr/render.h +++ b/include/wlr/render.h @@ -64,7 +64,7 @@ struct wlr_surface { * calling this function. */ bool wlr_surface_attach_pixels(struct wlr_surface *surf, - enum wl_shm_format format, int width, int height, + enum wl_shm_format format, int stride, int width, int height, const unsigned char *pixels); /** * Attaches pixels from a wl_shm_buffer to this surface. The shm buffer may be diff --git a/include/wlr/render/interface.h b/include/wlr/render/interface.h index f2168dcd..ed804bb4 100644 --- a/include/wlr/render/interface.h +++ b/include/wlr/render/interface.h @@ -33,7 +33,7 @@ struct wlr_renderer *wlr_renderer_init(struct wlr_renderer_state *state, struct wlr_surface_impl { bool (*attach_pixels)(struct wlr_surface_state *state, - enum wl_shm_format format, int width, int height, + enum wl_shm_format format, int stride, int width, int height, const unsigned char *pixels); bool (*attach_shm)(struct wlr_surface_state *state, uint32_t format, struct wl_shm_buffer *shm); diff --git a/include/wlr/types/wlr_output.h b/include/wlr/types/wlr_output.h index 6c7c320d..cfc4cc0e 100644 --- a/include/wlr/types/wlr_output.h +++ b/include/wlr/types/wlr_output.h @@ -43,6 +43,14 @@ struct wlr_output { struct wl_signal frame; struct wl_signal resolution; } events; + + struct { + bool is_sw; + int32_t x, y; + uint32_t width, height; + struct wlr_renderer *renderer; + struct wlr_surface *texture; + } cursor; }; void wlr_output_enable(struct wlr_output *output, bool enable); @@ -56,5 +64,7 @@ bool wlr_output_move_cursor(struct wlr_output *output, int x, int y); void wlr_output_destroy(struct wlr_output *output); void wlr_output_effective_resolution(struct wlr_output *output, int *width, int *height); +void wlr_output_make_current(struct wlr_output *output); +void wlr_output_swap_buffers(struct wlr_output *output); #endif |