gbm: Add gbm_bo_write entry point
authorKristian Høgsberg <krh@bitplanet.net>
Wed, 2 May 2012 19:30:13 +0000 (15:30 -0400)
committerKristian Høgsberg <krh@bitplanet.net>
Thu, 3 May 2012 14:57:32 +0000 (10:57 -0400)
commit4fddb2ba21add1c1968330e5224ecead59da3995
tree20b7a7e683f135f90e2fb5b67f1856e0f038e44b
parentb4789860c4416ba700ac5edeb692b59e33d45276
gbm: Add gbm_bo_write entry point

This new gbm entry point allows writing data into a gbm bo.  The bo has
to be created with the GBM_BO_USE_WRITE flag, and it's only required to
work for GBM_BO_USE_CURSOR_64X64 bos.

The gbm API is designed to be the glue layer between EGL and KMS, but there
was never a mechanism initialize a buffer suitable for use with KMS
hw cursors.  The hw cursor bo is typically not compatible with anything EGL
can render to, and thus there's no way to get data into such a bo.

gbm_bo_write() fills that gap while staying out of the efficient
cpu->gpu pixel transfer business.

Reviewed-by: Ander Conselvan de Oliveira <conselvan2@gmail.com>
include/GL/internal/dri_interface.h
src/gbm/backends/dri/gbm_dri.c
src/gbm/main/gbm.c
src/gbm/main/gbm.h
src/gbm/main/gbmint.h
src/mesa/drivers/dri/intel/intel_regions.h
src/mesa/drivers/dri/intel/intel_screen.c