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

Commit 01771a9f authored by Glenn Kasten's avatar Glenn Kasten Committed by Android (Google) Code Review
Browse files

Merge "Revert "soundpool: update sample rate when reusing audiotrack""

parents d1eca77c b801f733
Loading
Loading
Loading
Loading
+0 −2
Original line number Diff line number Diff line
@@ -745,10 +745,8 @@ void SoundChannel::play(const sp<Sample>& sample, int nextChannelID, float leftV
            // From now on, AudioTrack callbacks received with previous toggle value will be ignored.
            mToggle = toggle;
            mAudioTrack = newTrack;
            ALOGV("using new track %p for sample %d", newTrack.get(), sample->sampleID());
        } else {
            newTrack = mAudioTrack;
            newTrack->setSampleRate(sampleRate);
            ALOGV("reusing track %p for sample %d", mAudioTrack.get(), sample->sampleID());
        }
        newTrack->setVolume(leftVolume, rightVolume);