OSDN Git Service

Fix miracast source code to ignore the encoder output format change
authorAndreas Huber <andih@google.com>
Wed, 1 May 2013 23:03:28 +0000 (16:03 -0700)
committerAndreas Huber <andih@google.com>
Wed, 1 May 2013 23:03:28 +0000 (16:03 -0700)
it doesn't care about.

Change-Id: Iec1594775a98b0c1aba662cc9f08652d2f8d4805
related-to-bug: 8616651

media/libstagefright/wifi-display/source/Converter.cpp

index 0a8462c..5344623 100644 (file)
@@ -649,6 +649,13 @@ status_t Converter::doMoreWork() {
                 &bufferIndex, &offset, &size, &timeUs, &flags);
 
         if (err != OK) {
+            if (err == INFO_FORMAT_CHANGED) {
+                continue;
+            } else if (err == INFO_OUTPUT_BUFFERS_CHANGED) {
+                mEncoder->getOutputBuffers(&mEncoderOutputBuffers);
+                continue;
+            }
+
             if (err == -EAGAIN) {
                 err = OK;
             }