From 310d8d189d14eb6c29be205bf2c9e98187b2fa84 Mon Sep 17 00:00:00 2001 From: Ander Conselvan de Oliveira Date: Mon, 30 Apr 2012 13:27:51 +0300 Subject: gbm: add gbm_bo_get/set_user_data() This allows the user to associate some data to a gbm_bo and get a callback when the bo is destroyed. --- src/gbm/main/gbm.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/gbm/main/gbm.h') diff --git a/src/gbm/main/gbm.h b/src/gbm/main/gbm.h index 6748752d8f1..16489f36bba 100644 --- a/src/gbm/main/gbm.h +++ b/src/gbm/main/gbm.h @@ -245,6 +245,13 @@ gbm_bo_get_format(struct gbm_bo *bo); union gbm_bo_handle gbm_bo_get_handle(struct gbm_bo *bo); +void +gbm_bo_set_user_data(struct gbm_bo *bo, void *data, + void (*destroy_user_data)(struct gbm_bo *, void *)); + +void * +gbm_bo_get_user_data(struct gbm_bo *bo); + void gbm_bo_destroy(struct gbm_bo *bo); -- cgit v1.2.3