View Single Post
  #80  
Old 08-02-2017, 02:36 PM
j_cool j_cool is offline
Senior Member
 
Join Date: Feb 2016
Posts: 515
j_cool is on a distinguished road
Default

Re: streamlink: an up to date fork of livestreamer


Here is one solution to Stramlink's file formats problem but at a price.


Using ffmpeg to get flv format returns a file with audio an video in sync, but during ffmeg converting CPU usage spikes in short moments to 30% !

This spikes don't appear while ffmpeg is just copying but resulting file is next to unplayable.


Here is one example for example's sake only, my script is involved:

youtube-dl.exe --get-url -f 94 --no-check-certificate https://www.youtube.com/watch?v=y60wDzZt8yg | clip
for /f %%a in ('clb.exe') do set url=%%a
ffmpeg -user-agent Mozilla/5.0 -i %url% -c:v h264 -c:a aac c:\SKY_%d%.flv

I get youtube url sent to clipboard and from there url passed to ffmpeg.

This returns perfect file but at a price of 30% CPU usage in spikes every few seconds or so.

This matters to me because my PC is 100% passively cooled without any rotating parts inside and increasing CPU usage rises the temperature.


here is one example of bad file resulting no matter how I name filename extension, mkv, mp4, flv, etc.:


streamlink.exe https://www.youtube.com/watch?v=y60wDzZt8yg 480p -o c:\SKY_%d%.mkv


Does anyone know if there is any default file extension for youtube live videos or streamlink's output to that type of stream?

How to figure out what file extension would be the most suitable to streamlink to return decent file in case of youtube live videos?

This would benefit us in a way that streamlink or ffmpeg would just copy and save the stream without much processing in the background.
Reply With Quote