38 lines
1.8 KiB
Diff
38 lines
1.8 KiB
Diff
From 624cfc90b8bedb024f289772960f3cd7072fa940 Mon Sep 17 00:00:00 2001
|
|
From: Pierre-Hugues Husson <phh@phh.me>
|
|
Date: Sat, 6 Mar 2021 19:15:24 -0500
|
|
Subject: [PATCH 32/32] Fix AAC decoder failing to instantiate
|
|
|
|
This has been caused by I50fcc5ef35cb7e96592c2267652228b5fa074ba9
|
|
Non-Android 11 vendors won't provide those calls, and will thus fail.
|
|
---
|
|
media/libstagefright/ACodec.cpp | 5 ++---
|
|
1 file changed, 2 insertions(+), 3 deletions(-)
|
|
|
|
diff --git a/media/libstagefright/ACodec.cpp b/media/libstagefright/ACodec.cpp
|
|
index 0f8cd39edb..35cdf86319 100644
|
|
--- a/media/libstagefright/ACodec.cpp
|
|
+++ b/media/libstagefright/ACodec.cpp
|
|
@@ -5340,9 +5340,7 @@ status_t ACodec::getPortFormat(OMX_U32 portIndex, sp<AMessage> ¬ify) {
|
|
err = mOMXNode->getParameter(
|
|
(OMX_INDEXTYPE)OMX_IndexParamAudioAndroidAacDrcPresentation,
|
|
&presentation, sizeof(presentation));
|
|
- if (err != OK) {
|
|
- return err;
|
|
- }
|
|
+ if (err == OK) {
|
|
notify->setInt32("aac-encoded-target-level",
|
|
presentation.nEncodedTargetLevel);
|
|
notify->setInt32("aac-drc-cut-level", presentation.nDrcCut);
|
|
@@ -5355,6 +5353,7 @@ status_t ACodec::getPortFormat(OMX_U32 portIndex, sp<AMessage> ¬ify) {
|
|
notify->setInt32("aac-drc-album-mode", presentation.nDrcAlbumMode);
|
|
notify->setInt32("aac-drc-output-loudness",
|
|
presentation.nDrcOutputLoudness);
|
|
+ }
|
|
}
|
|
}
|
|
break;
|
|
--
|
|
2.25.1
|
|
|