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

Commit 6bd3bdf0 authored by Aniket Kumar Lata's avatar Aniket Kumar Lata Committed by Marco Nelissen
Browse files

AACWriter: support all possible channel counts



Support 1-7 channels when writing raw AAC, since that's what the
file format supports.

authored-by: default avatarSachin Mohan Gadag <sgadag@codeaurora.org>

Bug: 123375289
Test: builds
Change-Id: Ibc44fb575ad2897f936ed7f73f99ce481cdadb7d
parent bb08e4d9
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -85,7 +85,7 @@ status_t AACWriter::addSource(const sp<MediaSource> &source) {
    CHECK(!strcasecmp(mime, MEDIA_MIMETYPE_AUDIO_AAC));
    CHECK(meta->findInt32(kKeyChannelCount, &mChannelCount));
    CHECK(meta->findInt32(kKeySampleRate, &mSampleRate));
    CHECK(mChannelCount >= 1 && mChannelCount <= 2);
    CHECK(mChannelCount >= 1 && mChannelCount <= 7);

    // Optionally, we want to check whether AACProfile is also set.
    if (meta->findInt32(kKeyAACProfile, &mAACProfile)) {