Is there a way to play a video with, for instance, 5.1 PCM 24-bits audio over a opticle cable with ffplay?
The cable I use only supports AC3 audio (640kbps).
And how do I select the audio output device?
I'm programming a video player in python using ffplay, so it's easies for me to play video's on my own hardware, and control the playback on a different screen than the one where the video is played, I'm open to advice!
+ Reply to Thread
Results 1 to 6 of 6
Optical cable = spdif toslink. Specs for that show a max capability of 24bit x 2ch x 48kHz LPCM. 5.1 etc is too much data for it to handle in time.
The reason compressed formats work is because they reduce the bitrate to within the max bandwidth and then masquerade the signal as a type of LPCM.
You want better, either use 6ch analog or use HDMI/MHL/DP.
Same as Cornucopia - S/PDIF was designed to be Stereo PCM and at some point his capabilities was extended beyond that scope - in theory you can wrap your audio as IEC 61937 over S/PDIF and there are some TOS Link solutions capable to go over 9Mbps but every device in chain must be capable to do that which is highly doubtful in real life...
Go for HDMI where support for multichannel PCM is not a problem.
Compressed bitstreams such as ac3 and dts need to be padded & packetized to enable them to be sent in realtime down a spdif pipe. Remember the signal has to masquerade as a standard LPCM signal, which includes bitrate and sample chunk sizes and pacing.