Audio V4: Add metadata update to legacy API
am: 0360e255f1
Change-Id: I175e5ad8c7f913d8b810f064dc223c3a478ea949
This commit is contained in:
commit
c77f799ff1
1 changed files with 26 additions and 1 deletions
|
@ -212,13 +212,24 @@ typedef enum {
|
|||
give time for gapless track switch */
|
||||
} audio_drain_type_t;
|
||||
|
||||
typedef struct source_metadata {
|
||||
size_t track_count;
|
||||
/** Array of metadata of each track connected to this source. */
|
||||
struct playback_track_metadata* tracks;
|
||||
} source_metadata_t;
|
||||
|
||||
typedef struct sink_metadata {
|
||||
size_t track_count;
|
||||
/** Array of metadata of each track connected to this sink. */
|
||||
struct record_track_metadata* tracks;
|
||||
} sink_metadata_t;
|
||||
|
||||
/**
|
||||
* audio_stream_out is the abstraction interface for the audio output hardware.
|
||||
*
|
||||
* It provides information about various properties of the audio output
|
||||
* hardware driver.
|
||||
*/
|
||||
|
||||
struct audio_stream_out {
|
||||
/**
|
||||
* Common methods of the audio stream out. This *must* be the first member of audio_stream_out
|
||||
|
@ -403,6 +414,13 @@ struct audio_stream_out {
|
|||
*/
|
||||
int (*get_mmap_position)(const struct audio_stream_out *stream,
|
||||
struct audio_mmap_position *position);
|
||||
|
||||
/**
|
||||
* Called when the metadata of the stream's source has been changed.
|
||||
* @param source_metadata Description of the audio that is played by the clients.
|
||||
*/
|
||||
void (*update_source_metadata)(struct audio_stream_out *stream,
|
||||
const struct source_metadata* source_metadata);
|
||||
};
|
||||
typedef struct audio_stream_out audio_stream_out_t;
|
||||
|
||||
|
@ -530,6 +548,13 @@ struct audio_stream_in {
|
|||
int (*get_active_microphones)(const struct audio_stream_in *stream,
|
||||
struct audio_microphone_characteristic_t *mic_array,
|
||||
size_t *mic_count);
|
||||
|
||||
/**
|
||||
* Called when the metadata of the stream's sink has been changed.
|
||||
* @param sink_metadata Description of the audio that is recorded by the clients.
|
||||
*/
|
||||
void (*update_sink_metadata)(struct audio_stream_in *stream,
|
||||
const struct sink_metadata* sink_metadata);
|
||||
};
|
||||
typedef struct audio_stream_in audio_stream_in_t;
|
||||
|
||||
|
|
Loading…
Reference in a new issue