mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-29 05:40:27 -04:00
bluez5: update supported codec list when profiles changed
When A2DP is connected and new device profiles appear, update also supported codec list. Fixes missing codec profiles when A2DP is connected late.
This commit is contained in:
parent
5c91f23c18
commit
c7ad443e03
1 changed files with 6 additions and 0 deletions
|
|
@ -387,6 +387,12 @@ static void profiles_changed(void *userdata, uint32_t prev_profiles, uint32_t pr
|
|||
this->params[IDX_EnumRoute].flags ^= SPA_PARAM_INFO_SERIAL;
|
||||
}
|
||||
|
||||
if (connected_change & SPA_BT_PROFILE_A2DP_SINK) {
|
||||
free(this->supported_codecs);
|
||||
this->supported_codecs = spa_bt_device_get_supported_a2dp_codecs(
|
||||
this->bt_dev, &this->supported_codec_count);
|
||||
}
|
||||
|
||||
this->info.change_mask |= SPA_DEVICE_CHANGE_MASK_PARAMS;
|
||||
this->params[IDX_Profile].flags ^= SPA_PARAM_INFO_SERIAL;
|
||||
this->params[IDX_EnumProfile].flags ^= SPA_PARAM_INFO_SERIAL;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue