ui: Rework GraphicBuffer + Allocator for 64bit usage
Removes gralloc1-style flags, and replaces with HIDL-style single 64bit
usage. Internal storage of the usage is still 32bit; to be addressed
with a future change.
Change-Id: I60062208cbb06bc8cf6c293e7c7e1530c1147912
Bug: b/33350696
Test: Bullhead: booted to launcher, take photo, watch youtube
diff --git a/include/ui/GraphicBufferAllocator.h b/include/ui/GraphicBufferAllocator.h
index c4cbfc4..fe99de1 100644
--- a/include/ui/GraphicBufferAllocator.h
+++ b/include/ui/GraphicBufferAllocator.h
@@ -49,7 +49,7 @@
static inline GraphicBufferAllocator& get() { return getInstance(); }
status_t allocate(uint32_t w, uint32_t h, PixelFormat format,
- uint32_t layerCount, uint64_t producerUsage, uint64_t consumerUsage,
+ uint32_t layerCount, uint64_t usage,
buffer_handle_t* handle, uint32_t* stride, uint64_t graphicBufferId,
std::string requestorName);
@@ -65,8 +65,7 @@
uint32_t stride;
PixelFormat format;
uint32_t layerCount;
- uint64_t producerUsage;
- uint64_t consumerUsage;
+ uint64_t usage;
size_t size;
std::string requestorName;
};