From 82c6bcc9705eabcaf5b9e45bc81867b0e2d61a02 Mon Sep 17 00:00:00 2001 From: Eino-Ville Talvala Date: Thu, 19 Feb 2015 16:10:43 -0800 Subject: DO NOT MERGE 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 Cherry pick of I070bd2e7c56506055c419004c29e2e3feac725df Change-Id: I461952389c18051176c6b75e664f20ad369f5760 --- include/gui/Surface.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'include/gui/Surface.h') diff --git a/include/gui/Surface.h b/include/gui/Surface.h index 863f22bb0d..40e2fc1549 100644 --- a/include/gui/Surface.h +++ b/include/gui/Surface.h @@ -146,6 +146,7 @@ private: int dispatchLock(va_list args); int dispatchUnlockAndPost(va_list args); int dispatchSetSidebandStream(va_list args); + int dispatchSetBuffersDataSpace(va_list args); protected: virtual int dequeueBuffer(ANativeWindowBuffer** buffer, int* fenceFd); @@ -168,6 +169,7 @@ protected: virtual int setBuffersTransform(uint32_t transform); virtual int setBuffersStickyTransform(uint32_t transform); virtual int setBuffersTimestamp(int64_t timestamp); + virtual int setBuffersDataSpace(android_dataspace dataSpace); virtual int setCrop(Rect const* rect); virtual int setUsage(uint32_t reqUsage); @@ -223,6 +225,11 @@ private: // a timestamp is auto-generated when queueBuffer is called. int64_t mTimestamp; + // mDataSpace is the buffer dataSpace that will be used for the next buffer + // queue operation. It defaults to HAL_DATASPACE_UNKNOWN, which + // means that the buffer contains some type of color data. + android_dataspace mDataSpace; + // mCrop is the crop rectangle that will be used for the next buffer // that gets queued. It is set by calling setCrop. Rect mCrop; -- cgit v1.2.3-59-g8ed1b