Loading media/libaaudio/src/client/AAudioFlowGraph.cpp +2 −2 Original line number Diff line number Diff line Loading @@ -89,9 +89,9 @@ aaudio_result_t AAudioFlowGraph::configure(audio_format_t sourceFormat, } if (sourceSampleRate != sinkSampleRate) { mResampler.reset(aaudio::resampler::MultiChannelResampler::make(sinkChannelCount, mResampler.reset(aaudio::resampler::MultiChannelResampler::make(sourceChannelCount, sourceSampleRate, sinkSampleRate, resamplerQuality)); mRateConverter = std::make_unique<SampleRateConverter>(sinkChannelCount, mRateConverter = std::make_unique<SampleRateConverter>(sourceChannelCount, *mResampler); lastOutput->connect(&mRateConverter->input); lastOutput = &mRateConverter->output; Loading media/libaaudio/src/client/AudioStreamInternal.cpp +1 −4 Original line number Diff line number Diff line Loading @@ -134,8 +134,6 @@ aaudio_result_t AudioStreamInternal::open(const AudioStreamBuilder &builder) { request.getConfiguration().setBufferCapacity(builder.getBufferCapacity()); mDeviceChannelCount = getSamplesPerFrame(); // Assume it will be the same. Update if not. mServiceStreamHandleInfo = mServiceInterface.openStream(request, configurationOutput); if (getServiceHandle() < 0 && (request.getConfiguration().getSamplesPerFrame() == 1 Loading Loading @@ -179,8 +177,6 @@ aaudio_result_t AudioStreamInternal::open(const AudioStreamBuilder &builder) { setChannelMask(configurationOutput.getChannelMask()); } mDeviceChannelCount = configurationOutput.getSamplesPerFrame(); setDeviceId(configurationOutput.getDeviceId()); setSessionId(configurationOutput.getSessionId()); setSharingMode(configurationOutput.getSharingMode()); Loading @@ -205,6 +201,7 @@ aaudio_result_t AudioStreamInternal::open(const AudioStreamBuilder &builder) { // Save device format so we can do format conversion and volume scaling together. setDeviceFormat(configurationOutput.getFormat()); setDeviceSamplesPerFrame(configurationOutput.getSamplesPerFrame()); setHardwareSamplesPerFrame(configurationOutput.getHardwareSamplesPerFrame()); setHardwareSampleRate(configurationOutput.getHardwareSampleRate()); Loading media/libaaudio/src/client/AudioStreamInternal.h +0 −6 Original line number Diff line number Diff line Loading @@ -138,8 +138,6 @@ protected: // Calculate timeout for an operation involving framesPerOperation. int64_t calculateReasonableTimeout(int32_t framesPerOperation); int32_t getDeviceChannelCount() const { return mDeviceChannelCount; } /** * @return true if running in audio service, versus in app process */ Loading Loading @@ -213,10 +211,6 @@ private: int64_t mServiceLatencyNanos = 0; // Sometimes the hardware is operating with a different channel count from the app. // Then we require conversion in AAudio. int32_t mDeviceChannelCount = 0; int32_t mBufferSizeInFrames = 0; // local threshold to control latency int32_t mDeviceBufferSizeInFrames = 0; int32_t mBufferCapacityInFrames = 0; Loading media/libaaudio/src/client/AudioStreamInternalCapture.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -51,7 +51,7 @@ aaudio_result_t AudioStreamInternalCapture::open(const AudioStreamBuilder &build aaudio_result_t result = AudioStreamInternal::open(builder); if (result == AAUDIO_OK) { result = mFlowGraph.configure(getDeviceFormat(), getDeviceChannelCount(), getDeviceSamplesPerFrame(), getDeviceSampleRate(), getFormat(), getSamplesPerFrame(), Loading media/libaaudio/src/client/AudioStreamInternalPlay.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -54,7 +54,7 @@ aaudio_result_t AudioStreamInternalPlay::open(const AudioStreamBuilder &builder) getSamplesPerFrame(), getSampleRate(), getDeviceFormat(), getDeviceChannelCount(), getDeviceSamplesPerFrame(), getDeviceSampleRate(), getRequireMonoBlend(), useVolumeRamps, Loading Loading
media/libaaudio/src/client/AAudioFlowGraph.cpp +2 −2 Original line number Diff line number Diff line Loading @@ -89,9 +89,9 @@ aaudio_result_t AAudioFlowGraph::configure(audio_format_t sourceFormat, } if (sourceSampleRate != sinkSampleRate) { mResampler.reset(aaudio::resampler::MultiChannelResampler::make(sinkChannelCount, mResampler.reset(aaudio::resampler::MultiChannelResampler::make(sourceChannelCount, sourceSampleRate, sinkSampleRate, resamplerQuality)); mRateConverter = std::make_unique<SampleRateConverter>(sinkChannelCount, mRateConverter = std::make_unique<SampleRateConverter>(sourceChannelCount, *mResampler); lastOutput->connect(&mRateConverter->input); lastOutput = &mRateConverter->output; Loading
media/libaaudio/src/client/AudioStreamInternal.cpp +1 −4 Original line number Diff line number Diff line Loading @@ -134,8 +134,6 @@ aaudio_result_t AudioStreamInternal::open(const AudioStreamBuilder &builder) { request.getConfiguration().setBufferCapacity(builder.getBufferCapacity()); mDeviceChannelCount = getSamplesPerFrame(); // Assume it will be the same. Update if not. mServiceStreamHandleInfo = mServiceInterface.openStream(request, configurationOutput); if (getServiceHandle() < 0 && (request.getConfiguration().getSamplesPerFrame() == 1 Loading Loading @@ -179,8 +177,6 @@ aaudio_result_t AudioStreamInternal::open(const AudioStreamBuilder &builder) { setChannelMask(configurationOutput.getChannelMask()); } mDeviceChannelCount = configurationOutput.getSamplesPerFrame(); setDeviceId(configurationOutput.getDeviceId()); setSessionId(configurationOutput.getSessionId()); setSharingMode(configurationOutput.getSharingMode()); Loading @@ -205,6 +201,7 @@ aaudio_result_t AudioStreamInternal::open(const AudioStreamBuilder &builder) { // Save device format so we can do format conversion and volume scaling together. setDeviceFormat(configurationOutput.getFormat()); setDeviceSamplesPerFrame(configurationOutput.getSamplesPerFrame()); setHardwareSamplesPerFrame(configurationOutput.getHardwareSamplesPerFrame()); setHardwareSampleRate(configurationOutput.getHardwareSampleRate()); Loading
media/libaaudio/src/client/AudioStreamInternal.h +0 −6 Original line number Diff line number Diff line Loading @@ -138,8 +138,6 @@ protected: // Calculate timeout for an operation involving framesPerOperation. int64_t calculateReasonableTimeout(int32_t framesPerOperation); int32_t getDeviceChannelCount() const { return mDeviceChannelCount; } /** * @return true if running in audio service, versus in app process */ Loading Loading @@ -213,10 +211,6 @@ private: int64_t mServiceLatencyNanos = 0; // Sometimes the hardware is operating with a different channel count from the app. // Then we require conversion in AAudio. int32_t mDeviceChannelCount = 0; int32_t mBufferSizeInFrames = 0; // local threshold to control latency int32_t mDeviceBufferSizeInFrames = 0; int32_t mBufferCapacityInFrames = 0; Loading
media/libaaudio/src/client/AudioStreamInternalCapture.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -51,7 +51,7 @@ aaudio_result_t AudioStreamInternalCapture::open(const AudioStreamBuilder &build aaudio_result_t result = AudioStreamInternal::open(builder); if (result == AAUDIO_OK) { result = mFlowGraph.configure(getDeviceFormat(), getDeviceChannelCount(), getDeviceSamplesPerFrame(), getDeviceSampleRate(), getFormat(), getSamplesPerFrame(), Loading
media/libaaudio/src/client/AudioStreamInternalPlay.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -54,7 +54,7 @@ aaudio_result_t AudioStreamInternalPlay::open(const AudioStreamBuilder &builder) getSamplesPerFrame(), getSampleRate(), getDeviceFormat(), getDeviceChannelCount(), getDeviceSamplesPerFrame(), getDeviceSampleRate(), getRequireMonoBlend(), useVolumeRamps, Loading