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

Commit 0eed5ac1 authored by Glenn Kasten's avatar Glenn Kasten
Browse files

Merge commit 'adf3f9b9' into manualmerge

Change-Id: Icdef7d075b160eb2a5ced7c57f90c6a6a4b4c64a
parents de373601 adf3f9b9
Loading
Loading
Loading
Loading
+7 −5
Original line number Diff line number Diff line
@@ -1100,11 +1100,6 @@ void AudioMixer::process__genericNoResampling(state_t* state, int64_t pts)
        t.bufferProvider->getNextBuffer(&t.buffer, pts);
        t.frameCount = t.buffer.frameCount;
        t.in = t.buffer.raw;
        // t.in == NULL can happen if the track was flushed just after having
        // been enabled for mixing.
        if (t.in == NULL) {
            enabledTracks &= ~(1<<i);
        }
    }

    e0 = enabledTracks;
@@ -1140,6 +1135,13 @@ void AudioMixer::process__genericNoResampling(state_t* state, int64_t pts)
                    aux = t.auxBuffer + numFrames;
                }
                while (outFrames) {
                    // t.in == NULL can happen if the track was flushed just after having
                    // been enabled for mixing.
                   if (t.in == NULL) {
                        enabledTracks &= ~(1<<i);
                        e1 &= ~(1<<i);
                        break;
                    }
                    size_t inFrames = (t.frameCount > outFrames)?outFrames:t.frameCount;
                    if (inFrames > 0) {
                        t.hook(&t, outTemp + (BLOCKSIZE-outFrames)*MAX_NUM_CHANNELS, inFrames,