songbird
songbird copied to clipboard
Why the need to re-encode?
https://docs.rs/songbird/latest/src/songbird/input/ytdl_src.rs.html#44
According to this (you're using old style ffmpeg switches, -acodec
-> -c:a
) ffmpeg reencodes the input stream, even though afaik YouTube can give us Opus and Discord takes Opus as the input stream. I may be mistaken on this, though. I'm just looking for ways to optimize songbird as it hammers my server quite hard.
This is harder than it looks. Youtube gives you WebM which contains Opus; if you want to pass that through, you need a full MKV parser/demuxer. Most standalone *.opus
files are Ogg containers -- again, another demuxer that needs implemented. I'm working towards this via #89, which does this by making use of the symphonia library (and does it very well from early perf testing), but I have no free time right now to deal with all the other user-facing API changes that the rewrite needs.
Does it already work? Id be happy to beta test
If you need the performance ASAP you're welcome to try it, just be aware that things will break (and may be broken atm) as it's still in flux.
Closing as v0.4.x achieve passthrough as required.