diff options
Diffstat (limited to 'src/gbm/main/gbmint.h')
-rw-r--r-- | src/gbm/main/gbmint.h | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/src/gbm/main/gbmint.h b/src/gbm/main/gbmint.h index 66c4c41..53d73f4 100644 --- a/src/gbm/main/gbmint.h +++ b/src/gbm/main/gbmint.h @@ -59,18 +59,27 @@ struct gbm_device { void (*destroy)(struct gbm_device *gbm); int (*is_format_supported)(struct gbm_device *gbm, - enum gbm_bo_format format, + uint32_t format, uint32_t usage); struct gbm_bo *(*bo_create)(struct gbm_device *gbm, uint32_t width, uint32_t height, - enum gbm_bo_format format, + uint32_t format, uint32_t usage); struct gbm_bo *(*bo_create_from_egl_image)(struct gbm_device *gbm, void *egl_dpy, void *egl_img, uint32_t width, uint32_t height, uint32_t usage); void (*bo_destroy)(struct gbm_bo *bo); + + struct gbm_surface *(*surface_create)(struct gbm_device *gbm, + uint32_t width, uint32_t height, + uint32_t format, uint32_t flags); + struct gbm_bo *(*surface_lock_front_buffer)(struct gbm_surface *surface); + void (*surface_release_buffer)(struct gbm_surface *surface, + struct gbm_bo *bo); + int (*surface_has_free_buffers)(struct gbm_surface *surface); + void (*surface_destroy)(struct gbm_surface *surface); }; /** @@ -87,6 +96,14 @@ struct gbm_bo { union gbm_bo_handle handle; }; +struct gbm_surface { + struct gbm_device *gbm; + uint32_t width; + uint32_t height; + uint32_t format; + uint32_t flags; +}; + struct gbm_backend { const char *backend_name; struct gbm_device *(*create_device)(int fd); |