OSDN Git Service

Allow kPortModeDynamicANWBuffer for kBufferTypeANWBuffer in useBuffer
authorToshikazu Saito <toshikazu.x.saito@sony.com>
Tue, 10 Jul 2018 06:38:38 +0000 (15:38 +0900)
committerandroid-build-team Robot <android-build-team-robot@google.com>
Fri, 10 Aug 2018 20:26:41 +0000 (20:26 +0000)
Test: play contents
Bug: 77486542
Change-Id: I422d49a137889c417d855ebef954f882f67821ed
(cherry picked from commit d8cbab144398d0e9b3cdc2f8c42b4ea0c921e355)

media/libstagefright/omx/OMXNodeInstance.cpp

index a9fbd71..0c2203a 100644 (file)
@@ -1085,7 +1085,8 @@ status_t OMXNodeInstance::useBuffer(
         }
 
         case OMXBuffer::kBufferTypeANWBuffer: {
-            if (mPortMode[portIndex] != IOMX::kPortModePresetANWBuffer) {
+            if (mPortMode[portIndex] != IOMX::kPortModePresetANWBuffer
+                    && mPortMode[portIndex] != IOMX::kPortModeDynamicANWBuffer) {
                 break;
             }
             return useGraphicBuffer_l(portIndex, omxBuffer.mGraphicBuffer, buffer);