render/pixman: implement texture_from_buffer

This commit is contained in:
Simon Ser 2021-04-26 19:41:43 +02:00 committed by Simon Zeni
parent 6e43d642b2
commit 625c66ef75
2 changed files with 94 additions and 15 deletions

View file

@ -40,9 +40,12 @@ struct wlr_pixman_texture {
struct wlr_pixman_renderer *renderer;
struct wl_list link; // wlr_pixman_renderer.textures
void *data;
pixman_image_t *image;
const struct wlr_pixel_format_info *format;
pixman_format_code_t format;
const struct wlr_pixel_format_info *format_info;
void *data; // if created via texture_from_pixels
struct wlr_buffer *buffer; // if created via texture_from_buffer
};
pixman_format_code_t get_pixman_format_from_drm(uint32_t fmt);