Loading media/libaaudio/src/client/AAudioFlowGraph.cpp +22 −18 Original line number Diff line number Diff line Loading @@ -42,14 +42,15 @@ aaudio_result_t AAudioFlowGraph::configure(audio_format_t sourceFormat, audio_format_t sinkFormat, int32_t sinkChannelCount, bool useMonoBlend, float audioBalance) { float audioBalance, bool isExclusive) { FlowGraphPortFloatOutput *lastOutput = nullptr; // TODO change back to ALOGD ALOGI("%s() source format = 0x%08x, channels = %d, sink format = 0x%08x, channels = %d, " "useMonoBlend = %d, audioBalance = %f", "useMonoBlend = %d, audioBalance = %f, isExclusive %d", __func__, sourceFormat, sourceChannelCount, sinkFormat, sinkChannelCount, useMonoBlend, audioBalance); useMonoBlend, audioBalance, isExclusive); switch (sourceFormat) { case AUDIO_FORMAT_PCM_FLOAT: Loading Loading @@ -94,6 +95,8 @@ aaudio_result_t AAudioFlowGraph::configure(audio_format_t sourceFormat, return AAUDIO_ERROR_UNIMPLEMENTED; } // Apply volume ramps for only exclusive streams. if (isExclusive) { // Apply volume ramps to set the left/right audio balance and target volumes. // The signals will be decoupled, volume ramps will be applied, before the signals are // combined again. Loading @@ -110,6 +113,7 @@ aaudio_result_t AAudioFlowGraph::configure(audio_format_t sourceFormat, } lastOutput = &mManyToMultiConverter->output; setAudioBalance(audioBalance); } switch (sinkFormat) { case AUDIO_FORMAT_PCM_FLOAT: Loading media/libaaudio/src/client/AAudioFlowGraph.h +3 −1 Original line number Diff line number Diff line Loading @@ -43,6 +43,7 @@ public: * @param useMonoBlend * @param audioBalance * @param channelMask * @param isExclusive * @return */ aaudio_result_t configure(audio_format_t sourceFormat, Loading @@ -50,7 +51,8 @@ public: audio_format_t sinkFormat, int32_t sinkChannelCount, bool useMonoBlend, float audioBalance); float audioBalance, bool isExclusive); void process(const void *source, void *destination, int32_t numFrames); Loading media/libaaudio/src/client/AudioStreamInternalPlay.cpp +2 −1 Original line number Diff line number Diff line Loading @@ -54,7 +54,8 @@ aaudio_result_t AudioStreamInternalPlay::open(const AudioStreamBuilder &builder) getDeviceFormat(), getDeviceChannelCount(), getRequireMonoBlend(), getAudioBalance()); getAudioBalance(), (getSharingMode() == AAUDIO_SHARING_MODE_EXCLUSIVE)); if (result != AAUDIO_OK) { safeReleaseClose(); Loading Loading
media/libaaudio/src/client/AAudioFlowGraph.cpp +22 −18 Original line number Diff line number Diff line Loading @@ -42,14 +42,15 @@ aaudio_result_t AAudioFlowGraph::configure(audio_format_t sourceFormat, audio_format_t sinkFormat, int32_t sinkChannelCount, bool useMonoBlend, float audioBalance) { float audioBalance, bool isExclusive) { FlowGraphPortFloatOutput *lastOutput = nullptr; // TODO change back to ALOGD ALOGI("%s() source format = 0x%08x, channels = %d, sink format = 0x%08x, channels = %d, " "useMonoBlend = %d, audioBalance = %f", "useMonoBlend = %d, audioBalance = %f, isExclusive %d", __func__, sourceFormat, sourceChannelCount, sinkFormat, sinkChannelCount, useMonoBlend, audioBalance); useMonoBlend, audioBalance, isExclusive); switch (sourceFormat) { case AUDIO_FORMAT_PCM_FLOAT: Loading Loading @@ -94,6 +95,8 @@ aaudio_result_t AAudioFlowGraph::configure(audio_format_t sourceFormat, return AAUDIO_ERROR_UNIMPLEMENTED; } // Apply volume ramps for only exclusive streams. if (isExclusive) { // Apply volume ramps to set the left/right audio balance and target volumes. // The signals will be decoupled, volume ramps will be applied, before the signals are // combined again. Loading @@ -110,6 +113,7 @@ aaudio_result_t AAudioFlowGraph::configure(audio_format_t sourceFormat, } lastOutput = &mManyToMultiConverter->output; setAudioBalance(audioBalance); } switch (sinkFormat) { case AUDIO_FORMAT_PCM_FLOAT: Loading
media/libaaudio/src/client/AAudioFlowGraph.h +3 −1 Original line number Diff line number Diff line Loading @@ -43,6 +43,7 @@ public: * @param useMonoBlend * @param audioBalance * @param channelMask * @param isExclusive * @return */ aaudio_result_t configure(audio_format_t sourceFormat, Loading @@ -50,7 +51,8 @@ public: audio_format_t sinkFormat, int32_t sinkChannelCount, bool useMonoBlend, float audioBalance); float audioBalance, bool isExclusive); void process(const void *source, void *destination, int32_t numFrames); Loading
media/libaaudio/src/client/AudioStreamInternalPlay.cpp +2 −1 Original line number Diff line number Diff line Loading @@ -54,7 +54,8 @@ aaudio_result_t AudioStreamInternalPlay::open(const AudioStreamBuilder &builder) getDeviceFormat(), getDeviceChannelCount(), getRequireMonoBlend(), getAudioBalance()); getAudioBalance(), (getSharingMode() == AAUDIO_SHARING_MODE_EXCLUSIVE)); if (result != AAUDIO_OK) { safeReleaseClose(); Loading