diff options
| author | 2015-02-19 16:10:43 -0800 | |
|---|---|---|
| committer | 2015-03-23 20:00:29 -0700 | |
| commit | 63e8376d0baf494f9dd7e866d8dedb26ffab2a6b (patch) | |
| tree | 371a1417546ccd23e1b7b517c448230968922b78 /include/gui/IGraphicBufferConsumer.h | |
| parent | 28dbde32c2fa4a19a8bf3875e1756fb2a787695c (diff) | |
Add dataSpace to buffer queues; remove old format enums.
- Wire up new dataSpace parameter through buffer queue stack
- Update tests to include the parameter
- Switch eglApi to using dataSpace to indicate sRGB gamma/linear
difference
- Remove RAW_SENSOR in favor of RAW16
- Remove use of sRGB format enums
- Add default dataspace to buffer queue core
- Add query for default dataspace
Change-Id: I070bd2e7c56506055c419004c29e2e3feac725df
Diffstat (limited to 'include/gui/IGraphicBufferConsumer.h')
| -rw-r--r-- | include/gui/IGraphicBufferConsumer.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/include/gui/IGraphicBufferConsumer.h b/include/gui/IGraphicBufferConsumer.h index 15f51fe8c0..04f25436c2 100644 --- a/include/gui/IGraphicBufferConsumer.h +++ b/include/gui/IGraphicBufferConsumer.h @@ -25,6 +25,7 @@ #include <utils/Timers.h> #include <binder/IInterface.h> +#include <system/graphics.h> #include <ui/Rect.h> #include <EGL/egl.h> @@ -85,6 +86,10 @@ public: // automatically when the buffer was queued. bool mIsAutoTimestamp; + // mDataSpace is the current dataSpace for this buffer slot. This gets + // set by queueBuffer each time this slot is queued. + android_dataspace mDataSpace; + // mFrameNumber is the number of the queued frame for this slot. uint64_t mFrameNumber; @@ -286,6 +291,14 @@ public: // Return of a value other than NO_ERROR means an unknown error has occurred. virtual status_t setDefaultBufferFormat(uint32_t defaultFormat) = 0; + // setDefaultBufferDataSpace is a request to the producer to provide buffers + // of the indicated dataSpace. The producer may ignore this request. + // The initial default is HAL_DATASPACE_UNKNOWN. + // + // Return of a value other than NO_ERROR means an unknown error has occurred. + virtual status_t setDefaultBufferDataSpace( + android_dataspace defaultDataSpace) = 0; + // setConsumerUsageBits will turn on additional usage bits for dequeueBuffer. // These are merged with the bits passed to dequeueBuffer. The values are // enumerated in gralloc.h, e.g. GRALLOC_USAGE_HW_RENDER; the default is 0. |