On Sat, 26 Jan 2019, at 2:15 PM, Pali Rohár wrote: > On Saturday 26 January 2019 07:39:54 Arun Raghavan wrote: > > On Fri, 25 Jan 2019, at 3:19 PM, Tanu Kaskinen wrote: > > > On Sat, 2019-01-19 at 18:11 +0100, Pali Rohár wrote: > > > > This is 5th version of my patch series for modular A2DP codec API and > > > > aptX support. The only change for v5 is support for switching codecs. > > > > > > > > This patch series provides new modular API for Bluetooth A2DP codecs, > > > > clean up module-bluez5-device and bluez5-util to be codec independent > > > > and convert SBC codec into this new API for A2DP codecs. Also it adds > > > > support for aptX, aptX HD and FastStream A2DP codecs. > > > > > > > > New codec API is designed in way, that for adding new codec is not > > > > needed to touch bluez5-util nor module-bluez5-device files. Whole > > > > codec registration is done in a2dp-codec-util.c file, without need > > > > to update any header file. > > > > > > > > Some A2DP codecs are bidirectional and support backchannel for > > > > microphone voice. This new A2DP codec API fully supports this feature > > > > and module-bluez5-device was extended to support microphone voice source > > > > for codecs which declares such support. FastStream is such codec. > > > > > > > > For every A2DP codec is created card profile. When using bluez patches > > > > from https://marc.info/?l=linux-bluetooth&m=154696260401673&w=2 then > > > > only those profiles codec profiles are created which are supported > > > > by remote headset/endpoint. > > > > > > As discussed before, I don't think the codec configuration should be > > > exposed via card profiles. There is need for being able to say "switch > > > to A2DP" without specifying the codec. > > > > I strongly agree with this. Separate profiles for each codec is simply not the way to go -- it's horrible for usability. > > Why it is horrible? > > I think horrible is when you need to introduce a new API into pulseaudio > core for adding ability for switching to codec which supports > microphone. > > Same for having hardcoded priority list of codecs somewhere in config > file or in module argument. > > It would mean that switching to codec with microphone support cannot be > done in existing GUI tools and it is needed to edit config file or > re-load bluetooth module. This is horrible. Perhaps my phrasing was a bit harsh, apologies if you found it so. Having users to through a drop-down list for codec selection is unfriendly from a UX perspective was what I was getting at. For me this is a non-starter. For most people, this is configuration they don't and shouldn't care about. We should have sensible defaults and they should just work. For people who do care, you're right, this is a gap in what PulseAudio currently supports. While we discuss a solution, a modarg allows us to take the existing work forward, especially since that configuration is only one independent part of whole. I do not follow what you mean about codec with a microphone. If you mean A2DP source+sink at the same time with one of these codecs, I think this is not common enough to make everything else user unfriendly and we can still try to find a way to enable it that doesn't require codec selection via profiles. -- Arun _______________________________________________ pulseaudio-discuss mailing list pulseaudio-discuss@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/pulseaudio-discuss