If you want AptX and other high(er) quality codec support...
SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
If you want AptX and other high(er) quality codec support...
Give this a try: https://github.com/EHfive/pulseaudio-modules-bt. I'm currently using with some AptX compatible headphones, and I can tell the difference. You will have to upgrade ffmpeg to 4.x.
Give this a try: https://github.com/EHfive/pulseaudio-modules-bt. I'm currently using with some AptX compatible headphones, and I can tell the difference. You will have to upgrade ffmpeg to 4.x.
I've got a Denon AVR-S510BT with 2 front and 2 rear speakers, and I've already had great sound come out of it, and honestly, I can't tell a whole lot of difference. Maybe it makes a bigger difference with headphones than with a stereo system. But I'm of the opinion that it's better to have such options available. Thanks for letting us know about this, alex.
I've got a Denon AVR-S510BT with 2 front and 2 rear speakers, and I've already had great sound come out of it, and honestly, I can't tell a whole lot of difference. Maybe it makes a bigger difference with headphones than with a stereo system. But I'm of the opinion that it's better to have such options available. Thanks for letting us know about this, alex.
As suggested by the project's Wiki page, I ran the following command:
Is there a way to get pulseaudio to accept a different codec, or does it just use what it detects the bluetooth device can support?
Per the docs, the modules will automatically choose the best supported codec for the device. My headphones actually show 'AptX' when I ran the same command.
Per the docs, the modules will automatically choose the best supported codec for the device. My headphones actually show 'AptX' when I ran the same command.
After going through the instructions outlined in the docs, it looks like AAC is the only codec supported by my receiver.
EDIT: Since the AAC codec was stated as having been added as part of those modules, it looks like it was not effort wasted.
Last edited by 1337_powerslacker; 03-08-2019 at 04:00 PM.
ffmpeg4 should be installable alongside ffmpeg 3.x without conflict.
By default it will not build the ffmpeg binaries or man-pages, in order
not to conflict with an ffmpeg 3.x package.
To link to this version of the ffmpeg libraries, you'll need to set
the PKG_CONFIG_PATH to "/usr/lib${LIBDIRSUFFIX}/ffmpeg4/pkgconfig"
where ${LIBDIRSUFFIX} is either 64 or an empty string, depending on
your architecture.
Following the instructions, I was able to install support for AptX & other codecs supported in ffmpeg 4.x without touching the installed 3.x. I rebuilt the pulseaudio-modules-bt package, and it detected the libraries and installed support for the codecs. So I don't disrupt support for packages that require (and depend upon) 3.x to operate. I could re-compile packages for 4.x support, but on balance, it's much easier to install a sister package for 4.x support.
Last edited by 1337_powerslacker; 03-08-2019 at 09:23 PM.
Note: In order for multiple versions of ffmpeg to coexist, you must do either
1) Add the directory containing the ffmpeg 4 libs to /etc/ld.so.conf
2) Set the LDFLAGS environment variable to '-Wl,-rpath=/usr/lib64/ffmpeg4' before configuring the ffmpeg4 and bluetooth modules for building. Replace /usr/lib64/ffmpeg4 with the directory containing your ffmpeg 4 libs.
I did 2) to ensure no conflict with existing applications.
To determine whether the modules support all codecs, look for the following in /var/log/messages:
Code:
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSource/VENDOR/LDAC
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSource/VENDOR/APTXHD
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSource/VENDOR/APTX
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSource/AAC
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSource/SBC
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSink/VENDOR/APTXHD
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSink/VENDOR/APTX
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSink/AAC
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSink/SBC
These are the codecs the modules support, not what a particular device supports. Note the presence of APTX and APTXHD codecs
If the module can't load the correct ffmpeg libraries, you will see the following:
Code:
Mar 10 23:15:03 boss4 bluetoothd[1053]: Endpoint unregistered: sender=:1.88 path=/MediaEndpoint/A2DPSource/VENDOR/LDAC
Mar 10 23:15:03 boss4 bluetoothd[1053]: Endpoint unregistered: sender=:1.88 path=/MediaEndpoint/A2DPSource/AAC
Mar 10 23:15:03 boss4 bluetoothd[1053]: Endpoint unregistered: sender=:1.88 path=/MediaEndpoint/A2DPSource/SBC
Mar 10 23:15:03 boss4 bluetoothd[1053]: Endpoint unregistered: sender=:1.88 path=/MediaEndpoint/A2DPSink/AAC
Mar 10 23:15:03 boss4 bluetoothd[1053]: Endpoint unregistered: sender=:1.88 path=/MediaEndpoint/A2DPSink/SBC
You cannot verify that the modules link to the correct ffmpeg version by looking at the output of ldd, as the modules load the ffmpeg libraries via dlopen.
Note: In order for multiple versions of ffmpeg to coexist, you must do either
1) Add the directory containing the ffmpeg 4 libs to /etc/ld.so.conf
2) Set the LDFLAGS environment variable to '-Wl,-rpath=/usr/lib64/ffmpeg4' before configuring the ffmpeg4 and bluetooth modules for building. Replace /usr/lib64/ffmpeg4 with the directory containing your ffmpeg 4 libs.
I did 2) to ensure no conflict with existing applications.
To determine whether the modules support all codecs, look for the following in /var/log/messages:
Code:
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSource/VENDOR/LDAC
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSource/VENDOR/APTXHD
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSource/VENDOR/APTX
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSource/AAC
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSource/SBC
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSink/VENDOR/APTXHD
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSink/VENDOR/APTX
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSink/AAC
Mar 11 18:01:26 boss4 bluetoothd[11960]: Endpoint registered: sender=:1.171 path=/MediaEndpoint/A2DPSink/SBC
These are the codecs the modules support, not what a particular device supports. Note the presence of APTX and APTXHD codecs
If the module can't load the correct ffmpeg libraries, you will see the following:
Code:
Mar 10 23:15:03 boss4 bluetoothd[1053]: Endpoint unregistered: sender=:1.88 path=/MediaEndpoint/A2DPSource/VENDOR/LDAC
Mar 10 23:15:03 boss4 bluetoothd[1053]: Endpoint unregistered: sender=:1.88 path=/MediaEndpoint/A2DPSource/AAC
Mar 10 23:15:03 boss4 bluetoothd[1053]: Endpoint unregistered: sender=:1.88 path=/MediaEndpoint/A2DPSource/SBC
Mar 10 23:15:03 boss4 bluetoothd[1053]: Endpoint unregistered: sender=:1.88 path=/MediaEndpoint/A2DPSink/AAC
Mar 10 23:15:03 boss4 bluetoothd[1053]: Endpoint unregistered: sender=:1.88 path=/MediaEndpoint/A2DPSink/SBC
You cannot verify that the modules link to the correct ffmpeg version by looking at the output of ldd, as the modules load the ffmpeg libraries via dlopen.
Thanks for the info, alex! Something to keep in mind. My configuration works to my satisfaction.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.