pulseaudio-dlna
pulseaudio-dlna copied to clipboard
FLAC 24/96 streaming
Using pulseaudio-dlna master.
Configured /etc/pulse/daemon.conf with: default-sample-format = s24le default-sample-rate = 192000
Starting pulseaudo-dlna with: pulseaudio-dlna --codec flac --bit-rate 96
Playing 24/96 media with audacious (on fedora 26), audacious set to output 24 bits
I can see in pulseaudio-dlna the following
pulseaudio_dlna.streamserver INFO Starting processes "parec --format=s16le -d kefls50wireless_dlna.monitor | flac - -c --channels 2 --bps 16 --sample-rate 44100 --endian little --sign signed -s"
The playback works, but clearly the flac codec is downsampling to 16/44.1 no matter what (tried removing --bit-rate 96 from pulseaudio-dlna option, to no avail).
Why is pulseaudio-dlna not streaming at 24/96 (or 24/192) - is this supported?
For reference - capabilities reported by pulseaudio for the wireless DLNA speakers are 24/192 pulseaudio-dlna seems to ignore this and still do 16/44.1
pacmd list-sinks ... index: 4 name: <kefls50wireless_dlna> driver: <module-null-sink.c> flags: DECIBEL_VOLUME LATENCY DYNAMIC_LATENCY state: RUNNING suspend cause: priority: 1000 volume: front-left: 65536 / 100% / 0.00 dB, front-right: 65536 / 100% / 0.00 dB balance 0.00 base volume: 65536 / 100% / 0.00 dB volume steps: 65537 muted: no current latency: 29.34 ms max request: 45 KiB max rewind: 45 KiB monitor source: 4 sample spec: s24le 2ch 192000Hz channel map: front-left,front-right Stereo used by: 1 linked by: 2 configured latency: 40.00 ms; range is 0.50 .. 2000.00 ms module: 32 properties: device.description = "KEF LS50 Wireless (DLNA)" device.class = "abstract" device.icon_name = "audio-card"
@arigit : Jep you are right, it is not supported currently. Most speakers do not support those. But it shouldn't be too hard to implement. I would be happy to accept a PR for this!
@masmu thanks - I think I can help out, I do have some python / pygtk experience - basic understanding to at least get started and give this a shot, hopefully ending in a PR. Actually I've already tried to play around with the code, I didn't get too far. I tried to tweak the ffmpeg backend but that probably wasn't the right start.
Can you give me some guidance on what you expect the PR to do and where to focus my effort/code study first. Where in the code would you expect sample_rate and bit_rate selection occur (for FLAC/WAV output)... any hint welcome
@arigit Could you please provide me a full debug.log?
pulseaudio-dlna --debug 2>&1 | tee -a debug.log
I would like to take a look into your devices media specifications.
Captured, please download it from here:
https://github.com/arigit/Misc-Temp/blob/master/debug-github.tar.xz
Please let me know once you download it so I can remove it from my repo.
Scenario: playing back a 96/24 FLAC with audacious, configured to use pulseaudio & 24 bit depth. Pulseaudio is configured with
default-sample-format = s24le default-sample-rate = 192000
Two devices should support HD Audio streaming: the KEF speakers (for sure) and also (I think) the raspberry running OSMC / Kodi (it plays back HD perfectly via NFS share, outputting to a DAC, the DAC reports HD)
Got it, thanks! Will take a look at it tonight.
Is there any plan to progress on higher bitrate support?
The Chromecast audio should support 24 bit / 192kHz also from what I read. Apparently mkchromecast can do it.