Add support for additional music codecs using ffmpeg.
Is your feature request related to a problem?
There isn't any issue about this, but you can't play any .wav (DSD) or .ape ("Monkey's Audio") lossless files using Telegram, as it recognizes such files as regular files (like .tar.gz or .7z files), and not music (see image below).
Describe the solution you'd like
Since Telegram Desktop has ffmpeg as dependency and uses it with media_audio (here, possibly?), it might be used for DSD convert to PCM and then passed to OpenAL for playback? It indeed might be a bit of CPU intensive, but it is not that bad and is quite close to how much flac consumes on playback.
Describe alternatives you've considered
Using other media players, such as foobar2000 or cmus(with ffmpeg support) for playback. Also I could convert .wav to .flac with compressing and downsampling to make Telegram recognize such files. (as easy as ffmpeg -i in.wav -o out.flac)
Additional context
I might look more into how Telegram actually plays music and why it ever limits usage to specific codecs, but I'm not sure I'll be able to make support alone, xd
The reason for codec limit is binary size and consistency with other official clients (mainly mobile ones)
@ilya-fedin hello,If I want to improve hardware decoding, where should I start?
@FishOrBear I have no idea how hardware decoding could be improved. If you have concrete ideas how to improve it and which code you need, I could try to point to it.
The reason for codec limit is binary size
Use shared linking.
and consistency with other official clients (mainly mobile ones)
So this enhancement wish goes to all official Telegram clients in parallel.
Use shared linking.
That will make size only bigger since static linking strips unused parts.
So this enhancement wish goes to all official Telegram clients in parallel.
No, this issue tracker is only for tdesktop-specific issues, unofficial and is read only by tdesktop devs and community.
TDesktop isn't able to send .wav files as "audio type"; when you try to send it, it will be sent as a normal document type.
I don't think the issue is related to codec at all because when I send .wav files with other clients, tdesktop (and all other clients) can play it just fine but when I send a file with tdesktop itself, it just doesn't send it as audio message type