diff options
| author | 2014-05-09 22:00:04 +0000 | |
|---|---|---|
| committer | 2014-05-09 22:00:04 +0000 | |
| commit | 2f3dca149a2bcae96f18e38f7ba99a95c3e1b08c (patch) | |
| tree | c42170cdac8e30c84813a2723fbb89689b7d2463 /libs/ui/GraphicBuffer.cpp | |
| parent | 02528cf6aaedbbfec55be57d33389e1c57d88245 (diff) | |
| parent | 9493d4924a59f14b698389386337a9c07a7ea3c4 (diff) | |
am 9493d492: am 9eb142e3: am a9d49f99: Merge "Revert "Use asynchronous lock/unlock API""
* commit '9493d4924a59f14b698389386337a9c07a7ea3c4':
Revert "Use asynchronous lock/unlock API"
Diffstat (limited to 'libs/ui/GraphicBuffer.cpp')
| -rw-r--r-- | libs/ui/GraphicBuffer.cpp | 46 |
1 files changed, 0 insertions, 46 deletions
diff --git a/libs/ui/GraphicBuffer.cpp b/libs/ui/GraphicBuffer.cpp index e21dc53ca5..99601edc70 100644 --- a/libs/ui/GraphicBuffer.cpp +++ b/libs/ui/GraphicBuffer.cpp @@ -208,52 +208,6 @@ status_t GraphicBuffer::unlock() return res; } -status_t GraphicBuffer::lockAsync(uint32_t usage, void** vaddr, int fenceFd) -{ - const Rect lockBounds(width, height); - status_t res = lockAsync(usage, lockBounds, vaddr, fenceFd); - return res; -} - -status_t GraphicBuffer::lockAsync(uint32_t usage, const Rect& rect, void** vaddr, int fenceFd) -{ - if (rect.left < 0 || rect.right > this->width || - rect.top < 0 || rect.bottom > this->height) { - ALOGE("locking pixels (%d,%d,%d,%d) outside of buffer (w=%d, h=%d)", - rect.left, rect.top, rect.right, rect.bottom, - this->width, this->height); - return BAD_VALUE; - } - status_t res = getBufferMapper().lockAsync(handle, usage, rect, vaddr, fenceFd); - return res; -} - -status_t GraphicBuffer::lockAsyncYCbCr(uint32_t usage, android_ycbcr *ycbcr, int fenceFd) -{ - const Rect lockBounds(width, height); - status_t res = lockAsyncYCbCr(usage, lockBounds, ycbcr, fenceFd); - return res; -} - -status_t GraphicBuffer::lockAsyncYCbCr(uint32_t usage, const Rect& rect, android_ycbcr *ycbcr, int fenceFd) -{ - if (rect.left < 0 || rect.right > this->width || - rect.top < 0 || rect.bottom > this->height) { - ALOGE("locking pixels (%d,%d,%d,%d) outside of buffer (w=%d, h=%d)", - rect.left, rect.top, rect.right, rect.bottom, - this->width, this->height); - return BAD_VALUE; - } - status_t res = getBufferMapper().lockAsyncYCbCr(handle, usage, rect, ycbcr, fenceFd); - return res; -} - -status_t GraphicBuffer::unlockAsync(int *fenceFd) -{ - status_t res = getBufferMapper().unlockAsync(handle, fenceFd); - return res; -} - size_t GraphicBuffer::getFlattenedSize() const { return (10 + (handle ? handle->numInts : 0))*sizeof(int); } |