From 976f494d53cb239307fd810ce592b5b5de1cbc41 Mon Sep 17 00:00:00 2001 From: Jamie Gennis Date: Tue, 19 Jul 2011 14:32:36 -0700 Subject: SurfaceTexture: remove getAllocator This change removes the SurfaceTexture::getAllocator method, as it's no longer needed. Proper refcounting of the Gralloc buffers is now handled by the IGraphicBufferAlloc binder marshalling code. Change-Id: I5cffa6ebfc1bc5828fb7ce0e0a5b2f55cd8479da --- include/gui/ISurfaceTexture.h | 6 ------ include/gui/SurfaceTextureClient.h | 4 ---- 2 files changed, 10 deletions(-) (limited to 'include') diff --git a/include/gui/ISurfaceTexture.h b/include/gui/ISurfaceTexture.h index bc630ae4ee..405a25a63a 100644 --- a/include/gui/ISurfaceTexture.h +++ b/include/gui/ISurfaceTexture.h @@ -94,12 +94,6 @@ protected: virtual status_t setTransform(uint32_t transform) = 0; virtual status_t setScalingMode(int mode) = 0; - // getAllocator retrieves the binder object that must be referenced as long - // as the GraphicBuffers dequeued from this ISurfaceTexture are referenced. - // Holding this binder reference prevents SurfaceFlinger from freeing the - // buffers before the client is done with them. - virtual sp getAllocator() = 0; - // query retrieves some information for this surface // 'what' tokens allowed are that of android_natives.h virtual int query(int what, int* value) = 0; diff --git a/include/gui/SurfaceTextureClient.h b/include/gui/SurfaceTextureClient.h index 829d8abf70..56f029f0c2 100644 --- a/include/gui/SurfaceTextureClient.h +++ b/include/gui/SurfaceTextureClient.h @@ -106,10 +106,6 @@ private: // interactions with the server using this interface. sp mSurfaceTexture; - // mAllocator is the binder object that is referenced to prevent the - // dequeued buffers from being freed prematurely. - sp mAllocator; - // mSlots stores the buffers that have been allocated for each buffer slot. // It is initialized to null pointers, and gets filled in with the result of // ISurfaceTexture::requestBuffer when the client dequeues a buffer from a -- cgit v1.2.3-59-g8ed1b From 29c870271e8d3f8c40c356283650ba54fe71a16b Mon Sep 17 00:00:00 2001 From: Jamie Gennis Date: Tue, 19 Jul 2011 12:11:52 -0700 Subject: SurfaceTexture: fix a comment Change-Id: I799532f77f8fbb6b8ee6888fdd8852b6f28e8c33 --- include/gui/SurfaceTexture.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'include') diff --git a/include/gui/SurfaceTexture.h b/include/gui/SurfaceTexture.h index 945f4bcd68..62ea943f53 100644 --- a/include/gui/SurfaceTexture.h +++ b/include/gui/SurfaceTexture.h @@ -343,8 +343,7 @@ private: // mCurrentTextureBuf is the graphic buffer of the current texture. It's // possible that this buffer is not associated with any buffer slot, so we - // must track it separately in order to properly use - // IGraphicBufferAlloc::freeAllGraphicBuffersExcept. + // must track it separately in order to support the getCurrentBuffer method. sp mCurrentTextureBuf; // mCurrentCrop is the crop rectangle that applies to the current texture. -- cgit v1.2.3-59-g8ed1b