diff options
author | Alexy Joseph <alexyj@codeaurora.org> | 2015-11-15 23:53:09 -0800 |
---|---|---|
committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2015-11-20 21:30:36 -0800 |
commit | 70756a1edc64278d1e45c527ae14c75a27e44e23 (patch) | |
tree | 13afbc2fca3fc132e66d9f5a1df4b4fc89d0e2fe | |
parent | c5f7608f2b41b933146a5a92312ae4826e74d601 (diff) | |
download | hardware_qcom_audio-70756a1edc64278d1e45c527ae14c75a27e44e23.tar.gz hardware_qcom_audio-70756a1edc64278d1e45c527ae14c75a27e44e23.tar.bz2 hardware_qcom_audio-70756a1edc64278d1e45c527ae14c75a27e44e23.zip |
HAL: Identify Track offload session
Support getparameter to retrieve if a
particular output is associated with a track
offloaded session
Change-Id: Ibcc986514f802e59c514fdaa8b2d7f53841047a2
CRs-Fixed: 933740
-rw-r--r-- | hal/audio_hw.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/hal/audio_hw.c b/hal/audio_hw.c index c78bc981..45b8095f 100644 --- a/hal/audio_hw.c +++ b/hal/audio_hw.c @@ -2027,6 +2027,21 @@ static char* out_get_parameters(const struct audio_stream *stream, const char *k } } + + ret = str_parms_get_str(query, "is_direct_pcm_track", value, sizeof(value)); + if (ret >= 0) { + value[0] = '\0'; + if (out->flags & AUDIO_OUTPUT_FLAG_DIRECT_PCM) { + ALOGV("in direct_pcm"); + strlcat(value, "true", strlen("true")); + } else { + ALOGV("not in direct_pcm"); + strlcat(value, "false", strlen("false")); + } + str_parms_add_str(reply, "is_direct_pcm_track", value); + str = str_parms_to_str(reply); + } + ret = str_parms_get_str(query, AUDIO_PARAMETER_STREAM_SUP_FORMATS, value, sizeof(value)); if (ret >= 0) { value[0] = '\0'; |