Audio V4: propagate metadata to the HAL
This is needed for the earring aid use case.
Bug: 38184704
Bug: 69623109
Test: check that the correct metadata are propagate to the HALs.
Change-Id: I285aac9fbb5431cc32c6fbccebdbff4914e6ab92
Signed-off-by: Kevin Rocard <krocard@google.com>
diff --git a/media/libaudiohal/2.0/StreamHalLocal.h b/media/libaudiohal/2.0/StreamHalLocal.h
index ebebf4e..cda8d0c 100644
--- a/media/libaudiohal/2.0/StreamHalLocal.h
+++ b/media/libaudiohal/2.0/StreamHalLocal.h
@@ -149,6 +149,9 @@
// Get current read/write position in the mmap buffer
virtual status_t getMmapPosition(struct audio_mmap_position *position);
+ // Called when the metadata of the stream's source has been changed.
+ status_t updateSourceMetadata(const SourceMetadata& sourceMetadata) override;
+
private:
audio_stream_out_t *mStream;
wp<StreamOutHalInterfaceCallback> mCallback;
@@ -197,6 +200,9 @@
// Get active microphones
virtual status_t getActiveMicrophones(std::vector<media::MicrophoneInfo> *microphones);
+ // Called when the metadata of the stream's sink has been changed.
+ status_t updateSinkMetadata(const SinkMetadata& sinkMetadata) override;
+
private:
audio_stream_in_t *mStream;