Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ea2199d3 authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "MediaCodec: manage resources for hardware audio codecs"

parents af9abc4f 1d94733b
Loading
Loading
Loading
Loading
+5 −2
Original line number Diff line number Diff line
@@ -2506,8 +2506,11 @@ void MediaCodec::onMessageReceived(const sp<AMessage> &msg) {
                        mediametrics_setInt32(mMetricsHandle, kCodecSecure, 0);
                    }

                    if (mIsVideo) {
                        // audio codec is currently ignored.
                    MediaCodecInfo::Attributes attr = mCodecInfo
                            ? mCodecInfo->getAttributes()
                            : MediaCodecInfo::Attributes(0);
                    if (!(attr & MediaCodecInfo::kFlagIsSoftwareOnly)) {
                        // software codec is currently ignored.
                        mResourceManagerProxy->addResource(
                                MediaResource::CodecResource(mFlags & kFlagIsSecure, mIsVideo));
                    }