summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorEric Laurent <elaurent@google.com>2012-03-05 17:06:40 -0800
committerEric Laurent <elaurent@google.com>2012-03-05 17:18:36 -0800
commitd8d6185c978c9b27ca69e7791785e0983ed9e8b8 (patch)
treecda49b71e787cf1bcf68671e237389f70706cff3 /include
parent985ed9a1a22ec7e6e245d3fb8e93d3a23bdc539b (diff)
downloadframeworks_av-d8d6185c978c9b27ca69e7791785e0983ed9e8b8.zip
frameworks_av-d8d6185c978c9b27ca69e7791785e0983ed9e8b8.tar.gz
frameworks_av-d8d6185c978c9b27ca69e7791785e0983ed9e8b8.tar.bz2
AudioTrack: relax check on minimum buffer size
Current AudioTrack implementation enforces that the requested audio buffer size is at least corresponding the audio latency. This requirement is too strong and leads to problems with current stagefright and AudioSink implementations when playing over output streams with long latency. Ultimately, the AudioSink design should be changed to specify a minimum buffer size in time or frames units but not in buffer count units. Change-Id: I8ba603956f92ac49143a8249572665aa548f2f0f
Diffstat (limited to 'include')
-rw-r--r--include/media/AudioTrack.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/include/media/AudioTrack.h b/include/media/AudioTrack.h
index 9f2bd3a..95b9d86 100644
--- a/include/media/AudioTrack.h
+++ b/include/media/AudioTrack.h
@@ -135,8 +135,10 @@ public:
* format: Audio format (e.g AUDIO_FORMAT_PCM_16_BIT for signed
* 16 bits per sample).
* channelMask: Channel mask: see audio_channels_t.
- * frameCount: Total size of track PCM buffer in frames. This defines the
- * latency of the track.
+ * frameCount: Minimum size of track PCM buffer in frames. This defines the
+ * latency of the track. The actual size selected by the AudioTrack could be
+ * larger if the requested size is not compatible with current audio HAL
+ * latency.
* flags: Reserved for future use.
* cbf: Callback function. If not null, this function is called periodically
* to request new PCM data.