diff options
Diffstat (limited to 'include/hardware/audio.h')
-rw-r--r-- | include/hardware/audio.h | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/include/hardware/audio.h b/include/hardware/audio.h index 2389c09..22e7419 100644 --- a/include/hardware/audio.h +++ b/include/hardware/audio.h @@ -28,6 +28,9 @@ #include <hardware/hardware.h> #include <system/audio.h> #include <hardware/audio_effect.h> +#ifdef AUDIO_LISTEN_ENABLED +#include <listen_types.h> +#endif __BEGIN_DECLS @@ -117,6 +120,9 @@ __BEGIN_DECLS * or no HW sync is available. */ #define AUDIO_PARAMETER_HW_AV_SYNC "hw_av_sync" +/* Device state*/ +#define AUDIO_PARAMETER_KEY_DEV_SHUTDOWN "dev_shutdown" + /** * audio stream parameters */ @@ -649,6 +655,28 @@ struct audio_hw_device { int (*set_audio_port_config)(struct audio_hw_device *dev, const struct audio_port_config *config); +#ifdef AUDIO_LISTEN_ENABLED + /** This method creates the listen session and returns handle */ + int (*open_listen_session)(struct audio_hw_device *dev, + listen_open_params_t *params, + struct listen_session** handle); + + /** This method closes the listen session */ + int (*close_listen_session)(struct audio_hw_device *dev, + struct listen_session* handle); + + /** This method sets the mad observer callback */ + int (*set_mad_observer)(struct audio_hw_device *dev, + listen_callback_t cb_func); + + /** + * This method is used for setting listen hal specfic parameters. + * If multiple paramets are set in one call and setting any one of them + * fails it will return failure. + */ + int (*listen_set_parameters)(struct audio_hw_device *dev, + const char *kv_pairs); +#endif }; typedef struct audio_hw_device audio_hw_device_t; |