diff options
Diffstat (limited to 'src/modules')
-rw-r--r-- | src/modules/module-bt-device.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/modules/module-bt-device.c b/src/modules/module-bt-device.c index 87d6ea60..4fb4fd79 100644 --- a/src/modules/module-bt-device.c +++ b/src/modules/module-bt-device.c @@ -445,17 +445,16 @@ static int bt_setconf(struct userdata *u) { u->transport = setconf_rsp->transport; u->link_mtu = setconf_rsp->link_mtu; - if (u->transport == BT_CAPABILITIES_TRANSPORT_A2DP) - /* TODO: Check the max possible size */ u->block_size = u->link_mtu / 2; - else - u->block_size = u->link_mtu; /* setup SBC encoder now we agree on parameters */ if (u->transport == BT_CAPABILITIES_TRANSPORT_A2DP) { bt_a2dp_setup(&u->a2dp); + u->block_size = u->a2dp.codesize; pa_log/*debug*/("\tallocation=%u\n\tsubbands=%u\n\tblocks=%u\n\tbitpool=%u\n", u->a2dp.sbc.allocation, u->a2dp.sbc.subbands, u->a2dp.sbc.blocks, u->a2dp.sbc.bitpool); } + else + u->block_size = u->link_mtu; return 0; } |