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

Commit 929290fa authored by vivek mehta's avatar vivek mehta Committed by android-build-merger
Browse files

Merge "audio: allow standby for direct track" into nyc-dev

am: 1606b3f9

* commit '1606b3f9':
  audio: allow standby for direct track
parents cfc32935 1606b3f9
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -4996,6 +4996,10 @@ bool AudioFlinger::DirectOutputThread::shouldStandby_l()
    bool trackPaused = false;
    bool trackStopped = false;

    if ((mType == DIRECT) && audio_is_linear_pcm(mFormat) && !usesHwAvSync()) {
        return !mStandby;
    }

    // do not put the HAL in standby when paused. AwesomePlayer clear the offloaded AudioTrack
    // after a timeout and we will enter standby then.
    if (mTracks.size() > 0) {