audiopolicy: add Volume for attribute and callback native APIs
Change-Id: I259de42452d2802aa8dbd553f56040dea6995a93
Signed-off-by: François Gaffie <francois.gaffie@renault.com>
Bug: 124767636
Test: make
diff --git a/services/audiopolicy/AudioPolicyInterface.h b/services/audiopolicy/AudioPolicyInterface.h
index 9b00a4d..d61188f 100644
--- a/services/audiopolicy/AudioPolicyInterface.h
+++ b/services/audiopolicy/AudioPolicyInterface.h
@@ -159,6 +159,19 @@
int *index,
audio_devices_t device) = 0;
+ virtual status_t setVolumeIndexForAttributes(const audio_attributes_t &attr,
+ int index,
+ audio_devices_t device) = 0;
+ virtual status_t getVolumeIndexForAttributes(const audio_attributes_t &attr,
+ int &index,
+ audio_devices_t device) = 0;
+
+ virtual status_t getMaxVolumeIndexForAttributes(const audio_attributes_t &attr,
+ int &index) = 0;
+
+ virtual status_t getMinVolumeIndexForAttributes(const audio_attributes_t &attr,
+ int &index) = 0;
+
// return the strategy corresponding to a given stream type
virtual uint32_t getStrategyForStream(audio_stream_type_t stream) = 0;
@@ -347,6 +360,8 @@
virtual void onAudioPatchListUpdate() = 0;
+ virtual void onAudioVolumeGroupChanged(volume_group_t group, int flags) = 0;
+
virtual audio_unique_id_t newAudioUniqueId(audio_unique_id_use_t use) = 0;
virtual void onDynamicPolicyMixStateUpdate(String8 regId, int32_t state) = 0;