OSDN Git Service

Reduce the audio A2DP HAL output audio stream buffer size
authorPavlin Radoslavov <pavlin@google.com>
Wed, 5 Apr 2017 23:38:42 +0000 (16:38 -0700)
committerPavlin Radoslavov <pavlin@google.com>
Tue, 11 Apr 2017 21:46:36 +0000 (21:46 +0000)
Reduce the audio A2DP HAL output audio stream buffer size
(per constant AUDIO_STREAM_OUTPUT_BUFFER_PERIODS) from 4 to 2.
After the change, the output buffer size is double the buffer period.

Bug: 35849921
Test: A2DP streaming with various codec settings. Testplans/83305.
Change-Id: I2a15d468e748a03b481bf2117903ab06cddd02a3

audio_a2dp_hw/include/audio_a2dp_hw.h

index 62dac66..d6c69e1 100644 (file)
@@ -71,7 +71,7 @@
 //
 // to avoid introducing the FastMixer in AudioFlinger. Using the FastMixer
 // results in unnecessary latency and CPU overhead for Bluetooth.
-#define AUDIO_STREAM_OUTPUT_BUFFER_PERIODS 4
+#define AUDIO_STREAM_OUTPUT_BUFFER_PERIODS 2
 
 #define AUDIO_SKT_DISCONNECTED (-1)