From c3385fc598be35e7db57265283ba867cac07d19c Mon Sep 17 00:00:00 2001 From: Phil Burk Date: Tue, 19 Jan 2016 12:21:55 -0800 Subject: [PATCH] Audio passthrough: call audio_has_proportional_frames() for IEC61937 Bug: 24541671 Bug: 20891646 Bug: 26373761 Change-Id: I44351cfb7cfae16e6b3500add727a2c41b0f4e81 Signed-off-by: Phil Burk --- include/hardware/audio.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/hardware/audio.h b/include/hardware/audio.h index 49cc0fe0..36bfa862 100644 --- a/include/hardware/audio.h +++ b/include/hardware/audio.h @@ -462,7 +462,7 @@ static inline size_t audio_stream_frame_size(const struct audio_stream *s) size_t chan_samp_sz; audio_format_t format = s->get_format(s); - if (audio_is_linear_pcm(format)) { + if (audio_has_proportional_frames(format)) { chan_samp_sz = audio_bytes_per_sample(format); return popcount(s->get_channels(s)) * chan_samp_sz; } @@ -478,7 +478,7 @@ static inline size_t audio_stream_out_frame_size(const struct audio_stream_out * size_t chan_samp_sz; audio_format_t format = s->common.get_format(&s->common); - if (audio_is_linear_pcm(format)) { + if (audio_has_proportional_frames(format)) { chan_samp_sz = audio_bytes_per_sample(format); return audio_channel_count_from_out_mask(s->common.get_channels(&s->common)) * chan_samp_sz; } @@ -494,7 +494,7 @@ static inline size_t audio_stream_in_frame_size(const struct audio_stream_in *s) size_t chan_samp_sz; audio_format_t format = s->common.get_format(&s->common); - if (audio_is_linear_pcm(format)) { + if (audio_has_proportional_frames(format)) { chan_samp_sz = audio_bytes_per_sample(format); return audio_channel_count_from_in_mask(s->common.get_channels(&s->common)) * chan_samp_sz; }