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

Commit 6b344f77 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "aacenc: fix timestamp calculation"

parents 58b9bd5b 84889cbf
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -468,7 +468,8 @@ void C2SoftAacEnc::process(

            if (outargs.numOutBytes > 0) {
                mInputSize = 0;
                int consumed = ((capacity / sizeof(int16_t)) - inargs.numInSamples);
                int consumed = (capacity / sizeof(int16_t)) - inargs.numInSamples
                        + outargs.numInSamples;
                mInputTimeUs = work->input.ordinal.timestamp
                        + (consumed * 1000000ll / channelCount / sampleRate);
                buffer = createLinearBuffer(block, 0, outargs.numOutBytes);