diff options
Diffstat (limited to 'src/gbm/main/gbm.c')
-rw-r--r-- | src/gbm/main/gbm.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/gbm/main/gbm.c b/src/gbm/main/gbm.c index 0a9f0bef7ee..afcca63da3a 100644 --- a/src/gbm/main/gbm.c +++ b/src/gbm/main/gbm.c @@ -194,6 +194,21 @@ gbm_bo_get_format(struct gbm_bo *bo) return bo->format; } +/** Get the offset for the data of the specified plane + * + * Extra planes, and even the first plane, may have an offset from the start of + * the buffer object. This function will provide the offset for the given plane + * to be used in various KMS APIs. + * + * \param bo The buffer object + * \return The offset + */ +GBM_EXPORT int64_t +gbm_bo_get_offset(struct gbm_bo *bo, int plane) +{ + return bo->gbm->bo_get_offset(bo, plane); +} + /** Get the gbm device used to create the buffer object * * \param bo The buffer object |