Loading media/libaaudio/src/client/AudioStreamInternal.cpp +0 −10 Original line number Diff line number Diff line Loading @@ -42,7 +42,6 @@ #include "fifo/FifoBuffer.h" #include "utility/AudioClock.h" #include <media/AidlConversion.h> #include <com_android_media_aaudio.h> #include "AudioStreamInternal.h" Loading Loading @@ -197,15 +196,6 @@ aaudio_result_t AudioStreamInternal::open(const AudioStreamBuilder &builder) { setSampleRate(configurationOutput.getSampleRate()); } if (!com::android::media::aaudio::sample_rate_conversion()) { if (getSampleRate() != getDeviceSampleRate()) { ALOGD("%s - skipping sample rate converter. SR = %d, Device SR = %d", __func__, getSampleRate(), getDeviceSampleRate()); result = AAUDIO_ERROR_INVALID_RATE; goto error; } } // Save device format so we can do format conversion and volume scaling together. setDeviceFormat(configurationOutput.getFormat()); setDeviceSamplesPerFrame(configurationOutput.getSamplesPerFrame()); Loading services/oboeservice/AAudioServiceEndpointMMAP.cpp +3 −9 Original line number Diff line number Diff line Loading @@ -150,15 +150,9 @@ aaudio_result_t AAudioServiceEndpointMMAP::open(const aaudio::AAudioStreamReques // Try other formats if the config from APM is the same as our current config. // Some HALs may report its format support incorrectly. if (previousConfig.format == config.format) { if (previousConfig.sample_rate == config.sample_rate) { if ((previousConfig.format == config.format) && (previousConfig.sample_rate == config.sample_rate)) { config.format = getNextFormatToTry(config.format); } else if (!com::android::media::aaudio::sample_rate_conversion()) { ALOGI("%s() - AAudio SRC feature not enabled, different rates! %d != %d", __func__, previousConfig.sample_rate, config.sample_rate); result = AAUDIO_ERROR_INVALID_RATE; break; } } ALOGD("%s() %#x %d failed, perhaps due to format or sample rate. Try again with %#x %d", Loading Loading
media/libaaudio/src/client/AudioStreamInternal.cpp +0 −10 Original line number Diff line number Diff line Loading @@ -42,7 +42,6 @@ #include "fifo/FifoBuffer.h" #include "utility/AudioClock.h" #include <media/AidlConversion.h> #include <com_android_media_aaudio.h> #include "AudioStreamInternal.h" Loading Loading @@ -197,15 +196,6 @@ aaudio_result_t AudioStreamInternal::open(const AudioStreamBuilder &builder) { setSampleRate(configurationOutput.getSampleRate()); } if (!com::android::media::aaudio::sample_rate_conversion()) { if (getSampleRate() != getDeviceSampleRate()) { ALOGD("%s - skipping sample rate converter. SR = %d, Device SR = %d", __func__, getSampleRate(), getDeviceSampleRate()); result = AAUDIO_ERROR_INVALID_RATE; goto error; } } // Save device format so we can do format conversion and volume scaling together. setDeviceFormat(configurationOutput.getFormat()); setDeviceSamplesPerFrame(configurationOutput.getSamplesPerFrame()); Loading
services/oboeservice/AAudioServiceEndpointMMAP.cpp +3 −9 Original line number Diff line number Diff line Loading @@ -150,15 +150,9 @@ aaudio_result_t AAudioServiceEndpointMMAP::open(const aaudio::AAudioStreamReques // Try other formats if the config from APM is the same as our current config. // Some HALs may report its format support incorrectly. if (previousConfig.format == config.format) { if (previousConfig.sample_rate == config.sample_rate) { if ((previousConfig.format == config.format) && (previousConfig.sample_rate == config.sample_rate)) { config.format = getNextFormatToTry(config.format); } else if (!com::android::media::aaudio::sample_rate_conversion()) { ALOGI("%s() - AAudio SRC feature not enabled, different rates! %d != %d", __func__, previousConfig.sample_rate, config.sample_rate); result = AAUDIO_ERROR_INVALID_RATE; break; } } ALOGD("%s() %#x %d failed, perhaps due to format or sample rate. Try again with %#x %d", Loading