diff options
author | Pannag Sanketi <psanketi@google.com> | 2011-08-28 14:40:26 -0700 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2011-08-28 14:40:26 -0700 |
commit | c7de3f6bbaa6c1b8b334574fad34d583e3a67f5d (patch) | |
tree | 3dce6ee437fc2372ff1d1787d2bd7b6dbfd3bea9 | |
parent | 6004f2dc9af4088e34cc72b1ac3c4a3c5cd4ae14 (diff) | |
parent | f76e1672c674620cb056f338a25ee4826d55dfcb (diff) | |
download | frameworks_av-c7de3f6bbaa6c1b8b334574fad34d583e3a67f5d.zip frameworks_av-c7de3f6bbaa6c1b8b334574fad34d583e3a67f5d.tar.gz frameworks_av-c7de3f6bbaa6c1b8b334574fad34d583e3a67f5d.tar.bz2 |
Merge "Default W, H allowed in SurfaceMediaSource dequeue"
-rw-r--r-- | media/libstagefright/SurfaceMediaSource.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/media/libstagefright/SurfaceMediaSource.cpp b/media/libstagefright/SurfaceMediaSource.cpp index c2e6707..91b81c2 100644 --- a/media/libstagefright/SurfaceMediaSource.cpp +++ b/media/libstagefright/SurfaceMediaSource.cpp @@ -179,9 +179,11 @@ status_t SurfaceMediaSource::dequeueBuffer(int *outBuf, uint32_t w, uint32_t h, // TODO: Currently just uses mDefaultWidth/Height. In the future // we might declare mHeight and mWidth and check against those here. if ((w != 0) || (h != 0)) { - LOGE("dequeuebuffer: invalid buffer size! Req: %dx%d, Found: %dx%d", - mDefaultWidth, mDefaultHeight, w, h); - return BAD_VALUE; + if ((w != mDefaultWidth) || (h != mDefaultHeight)) { + LOGE("dequeuebuffer: invalid buffer size! Req: %dx%d, Found: %dx%d", + mDefaultWidth, mDefaultHeight, w, h); + return BAD_VALUE; + } } status_t returnFlags(OK); |