AudioSystem::getSamplingRate and getFrameCount now work for input
Also fix whitespace and comment in AudioIoDescriptor.
Bug: 25641253
Bug: 21019153
Change-Id: I6a1e2262f44f87ec3ebce6e5274f45ed0f47eb13
diff --git a/include/media/AudioSystem.h b/include/media/AudioSystem.h
index 901a0fd..91e2bbd 100644
--- a/include/media/AudioSystem.h
+++ b/include/media/AudioSystem.h
@@ -114,11 +114,12 @@
// FIXME This API assumes a route, and so should be deprecated.
static status_t getOutputLatency(uint32_t* latency,
audio_stream_type_t stream);
- static status_t getSamplingRate(audio_io_handle_t output,
+ // returns the audio HAL sample rate
+ static status_t getSamplingRate(audio_io_handle_t ioHandle,
uint32_t* samplingRate);
- // returns the number of frames per audio HAL write buffer. Corresponds to
- // audio_stream->get_buffer_size()/audio_stream_out_frame_size()
- static status_t getFrameCount(audio_io_handle_t output,
+ // returns the number of frames per audio HAL buffer. Corresponds to
+ // audio_stream->get_buffer_size()/audio_stream_out/in_frame_size()
+ static status_t getFrameCount(audio_io_handle_t ioHandle,
size_t* frameCount);
// returns the audio output latency in ms. Corresponds to
// audio_stream_out->get_latency()