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

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

Merge "Select the highest sampling rate if the requested is higher than default" into tm-qpr-dev

parents cdcb8776 d1785f7c
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -1868,7 +1868,8 @@ audio_io_handle_t AudioPolicyManager::selectOutput(const SortedVector<audio_io_h
    //    (see b/200293124, the incorrect selection of AUDIO_OUTPUT_FLAG_VOIP_RX).
    // 3: the output supporting the exact channel mask
    // 4: the output with a higher channel count than requested
    // 5: the output with a higher sampling rate than requested
    // 5: the output with the highest sampling rate if the requested sample rate is
    //    greater than default sampling rate
    // 6: the output with the highest number of requested performance flags
    // 7: the output with the bit depth the closest to the requested one
    // 8: the primary output
@@ -1928,8 +1929,7 @@ audio_io_handle_t AudioPolicyManager::selectOutput(const SortedVector<audio_io_h
        }

        // sampling rate match
        if (samplingRate > SAMPLE_RATE_HZ_DEFAULT &&
                samplingRate <= outputDesc->getSamplingRate()) {
        if (samplingRate > SAMPLE_RATE_HZ_DEFAULT) {
            currentMatchCriteria[4] = outputDesc->getSamplingRate();
        }