Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1c608ab3 authored by Chong Zhang's avatar Chong Zhang
Browse files

save mGraphicBuffer pointer even when we're suspended

Bug: 12609966
Change-Id: Ifd41fd973876da69039113fcaeacdccf39472b37
(cherry picked from commit 49270665)
parent bc69c8ba
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -609,6 +609,12 @@ void GraphicBufferSource::onFrameAvailable() {
        BufferQueue::BufferItem item;
        status_t err = mBufferQueue->acquireBuffer(&item, 0);
        if (err == OK) {
            // If this is the first time we're seeing this buffer, add it to our
            // slot table.
            if (item.mGraphicBuffer != NULL) {
                ALOGV("fillCodecBuffer_l: setting mBufferSlot %d", item.mBuf);
                mBufferSlot[item.mBuf] = item.mGraphicBuffer;
            }
            mBufferQueue->releaseBuffer(item.mBuf, item.mFrameNumber,
                    EGL_NO_DISPLAY, EGL_NO_SYNC_KHR, item.mFence);
        }