diff options
| author | 2025-03-07 16:22:43 -0800 | |
|---|---|---|
| committer | 2025-03-10 16:05:24 +0000 | |
| commit | 01e30e104f5bbc1abdac68e3bd24638fc6c883e9 (patch) | |
| tree | bdbdbe599b67f576d14d8d3b3f96a03292fa4359 /system | |
| parent | f7aab89647a35eef1a15391a0b9264e700a8b286 (diff) | |
a2dp/aidl: Configure the preferred user codec as hint in get_a2dp_configuration
Bug: 401190727
Test: QC validation
Test: m com.android.bt
Flag: EXEMPT, minor bug fix
Change-Id: I779f3ef306ea5fbbe03048c44d775432858f01db
Diffstat (limited to 'system')
| -rw-r--r-- | system/audio_hal_interface/aidl/a2dp/a2dp_encoding_aidl.cc | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/system/audio_hal_interface/aidl/a2dp/a2dp_encoding_aidl.cc b/system/audio_hal_interface/aidl/a2dp/a2dp_encoding_aidl.cc index cfb0d020d4..01924e2e17 100644 --- a/system/audio_hal_interface/aidl/a2dp/a2dp_encoding_aidl.cc +++ b/system/audio_hal_interface/aidl/a2dp/a2dp_encoding_aidl.cc @@ -832,6 +832,11 @@ provider::get_a2dp_configuration( break; } + auto codec = provider_info->GetCodec(user_preferences.codec_type); + if (codec.has_value()) { + hint.codecId = codec.value()->id; + } + log::info("remote capabilities:"); for (auto const& sep : a2dp_remote_capabilities) { log::info("- {}", sep.toString()); |