diff options
author | Mathias Agopian <mathias@google.com> | 2013-07-12 22:06:26 -0700 |
---|---|---|
committer | Mathias Agopian <mathias@google.com> | 2013-07-12 22:06:26 -0700 |
commit | 8f938a53385a3c6d1c6aa24b3f38437bb2cc47ae (patch) | |
tree | cfb65e937ffc8b4a3ed574b2bca828ef5ab4c18f /include/gui | |
parent | cdd7d8bc145bbbd21a1689ed87a381287aeec229 (diff) | |
download | frameworks_native-8f938a53385a3c6d1c6aa24b3f38437bb2cc47ae.zip frameworks_native-8f938a53385a3c6d1c6aa24b3f38437bb2cc47ae.tar.gz frameworks_native-8f938a53385a3c6d1c6aa24b3f38437bb2cc47ae.tar.bz2 |
always pass the BufferQueue explicitely to consumers
Change-Id: I883b0a7b19d8e722f9ab714ba6f49e658b02ca86
Diffstat (limited to 'include/gui')
-rw-r--r-- | include/gui/BufferItemConsumer.h | 4 | ||||
-rw-r--r-- | include/gui/CpuConsumer.h | 5 | ||||
-rw-r--r-- | include/gui/GLConsumer.h | 6 |
3 files changed, 10 insertions, 5 deletions
diff --git a/include/gui/BufferItemConsumer.h b/include/gui/BufferItemConsumer.h index 5bf9acb..0af6f8e 100644 --- a/include/gui/BufferItemConsumer.h +++ b/include/gui/BufferItemConsumer.h @@ -29,6 +29,8 @@ namespace android { +class BufferQueue; + /** * BufferItemConsumer is a BufferQueue consumer endpoint that allows clients * access to the whole BufferItem entry from BufferQueue. Multiple buffers may @@ -49,7 +51,7 @@ class BufferItemConsumer: public ConsumerBase // the consumer usage flags passed to the graphics allocator. The // bufferCount parameter specifies how many buffers can be locked for user // access at the same time. - BufferItemConsumer(uint32_t consumerUsage, + BufferItemConsumer(const sp<BufferQueue>& bq, uint32_t consumerUsage, int bufferCount = BufferQueue::MIN_UNDEQUEUED_BUFFERS, bool synchronousMode = false); diff --git a/include/gui/CpuConsumer.h b/include/gui/CpuConsumer.h index 3c178ef..5f1e369 100644 --- a/include/gui/CpuConsumer.h +++ b/include/gui/CpuConsumer.h @@ -28,6 +28,8 @@ namespace android { +class BufferQueue; + /** * CpuConsumer is a BufferQueue consumer endpoint that allows direct CPU * access to the underlying gralloc buffers provided by BufferQueue. Multiple @@ -64,7 +66,8 @@ class CpuConsumer : public ConsumerBase // Create a new CPU consumer. The maxLockedBuffers parameter specifies // how many buffers can be locked for user access at the same time. - CpuConsumer(uint32_t maxLockedBuffers, bool synchronousMode = true); + CpuConsumer(const sp<BufferQueue>& bq, + uint32_t maxLockedBuffers, bool synchronousMode = true); virtual ~CpuConsumer(); diff --git a/include/gui/GLConsumer.h b/include/gui/GLConsumer.h index fbc8840..65544bd 100644 --- a/include/gui/GLConsumer.h +++ b/include/gui/GLConsumer.h @@ -85,9 +85,9 @@ public: // purely to allow a GLConsumer to be transferred from one consumer // context to another. If such a transfer is not needed there is no // requirement that either of these methods be called. - GLConsumer(GLuint tex, bool allowSynchronousMode = true, - GLenum texTarget = GL_TEXTURE_EXTERNAL_OES, bool useFenceSync = true, - const sp<BufferQueue> &bufferQueue = 0); + GLConsumer(const sp<BufferQueue>& bq, + GLuint tex, GLenum texTarget = GL_TEXTURE_EXTERNAL_OES, + bool useFenceSync = true); // updateTexImage acquires the most recently queued buffer, and sets the // image contents of the target texture to it. |