am 9da22d2c: am 2ba13186: Merge "SurfaceTexture: fix a bug with buffer reallocation" into ics-mr1
* commit '9da22d2cc31069d86a92021d8540bb5a77c9591b': SurfaceTexture: fix a bug with buffer reallocation
This commit is contained in:
commit
b963e22ca2
@ -437,6 +437,11 @@ status_t SurfaceTexture::dequeueBuffer(int *outBuf, uint32_t w, uint32_t h,
|
|||||||
mSlots[buf].mEglImage = EGL_NO_IMAGE_KHR;
|
mSlots[buf].mEglImage = EGL_NO_IMAGE_KHR;
|
||||||
mSlots[buf].mEglDisplay = EGL_NO_DISPLAY;
|
mSlots[buf].mEglDisplay = EGL_NO_DISPLAY;
|
||||||
}
|
}
|
||||||
|
if (mCurrentTexture == buf) {
|
||||||
|
// The current texture no longer references the buffer in this slot
|
||||||
|
// since we just allocated a new buffer.
|
||||||
|
mCurrentTexture = INVALID_BUFFER_SLOT;
|
||||||
|
}
|
||||||
returnFlags |= ISurfaceTexture::BUFFER_NEEDS_REALLOCATION;
|
returnFlags |= ISurfaceTexture::BUFFER_NEEDS_REALLOCATION;
|
||||||
}
|
}
|
||||||
ST_LOGV("dequeueBuffer: returning slot=%d buf=%p flags=%#x", buf,
|
ST_LOGV("dequeueBuffer: returning slot=%d buf=%p flags=%#x", buf,
|
||||||
|
Loading…
Reference in New Issue
Block a user