fortypercnt / stream-translator

MIT License
220 stars 44 forks source link

Allow ability to specify stream quality within stream translator #2

Closed FallenVibe closed 1 year ago

FallenVibe commented 1 year ago

With certain Streamlink websites/plugins, the quality needs to be specified else stream-translator just outputs "Stream ended"

Came across this using the afreeca Streamlink plugin specifically. An option to chose any stream quality or a default quality would be great!

fortypercnt commented 1 year ago

Thanks for reporting this, I only tested with twitch and youtube. The stream quality for afreecatv returns sd (worst), hd, original (best), so that is not the issue. afreecatv returns HTTP error 400 Bad Request when passing the HLS URL to ffmpeg, whereas twitch/youtube don't complain. I think it has to do with how request headers are set up. The sensible solution is to let streamlink handle the HLS streams and pipe the output into ffmpeg for audio reencoding, instead of passing the URL to ffmpeg directly. I am working on that.

P.S. I have added an option to select the stream quality anyways. Seem like a good idea e.g. for people who want to reduce bandwidth usage.

fortypercnt commented 1 year ago

With the new update all websites supported by streamlink should work.