mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2026-04-01 07:15:39 -04:00
bluez5: implement BAP ucast reconfiguration
Use SelectProperties() DBus API to reconfigure BAP unicast setup. Add support to spa_bt_ensure_codec() to select whether to configure as sink/source/duplex.
This commit is contained in:
parent
592a97a7b0
commit
8795298f69
3 changed files with 223 additions and 56 deletions
|
|
@ -1410,7 +1410,7 @@ static int set_profile(struct impl *this, uint32_t profile, enum spa_bluetooth_a
|
|||
|
||||
this->switching_codec = true;
|
||||
|
||||
ret = spa_bt_device_ensure_media_codec(this->bt_dev, codecs);
|
||||
ret = spa_bt_device_ensure_media_codec(this->bt_dev, codecs, 0);
|
||||
if (ret < 0) {
|
||||
if (ret != -ENOTSUP)
|
||||
spa_log_error(this->log, "failed to switch codec (%d), setting basic profile", ret);
|
||||
|
|
@ -1563,6 +1563,9 @@ static void device_set_changed(void *userdata)
|
|||
this->profile != DEVICE_PROFILE_ASHA)
|
||||
return;
|
||||
|
||||
if (this->switching_codec)
|
||||
return;
|
||||
|
||||
if (!device_set_needs_update(this)) {
|
||||
spa_log_debug(this->log, "%p: device set not changed", this);
|
||||
return;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue