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

Commit 37e5e6a5 authored by Eric Laurent's avatar Eric Laurent Committed by Android Git Automerger
Browse files

am e33dee9e: am 14a849c2: am 1bf8a210: Merge "audio policy: add fallback for...

am e33dee9e: am 14a849c2: am 1bf8a210: Merge "audio policy: add fallback for output selection" into lmp-mr1-dev

* commit 'e33dee9e':
  audio policy: add fallback for output selection
parents 5c129eb3 e33dee9e
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -1113,6 +1113,10 @@ audio_io_handle_t AudioPolicyManager::getOutputForDevice(
            if (output != AUDIO_IO_HANDLE_NONE) {
                mpClientInterface->closeOutput(output);
            }
            // fall back to mixer output if possible when the direct output could not be open
            if (audio_is_linear_pcm(format) && samplingRate <= MAX_MIXER_SAMPLING_RATE) {
                goto non_direct_output;
            }
            return AUDIO_IO_HANDLE_NONE;
        }
        outputDesc->mSamplingRate = config.sample_rate;