[FFmpeg-user] Detect Frozen video
Michael Shaffer
mikeshaffer at gmail.com
Fri Nov 30 20:31:10 EET 2018
Hi Mustafa, here's a link to a zip file containing the restart program I
made.
https://github.com/mcshaf01/ffmpeg-stream-restart-tool/blob/master/ffmpeg-restart-tool-v030.zip
Setup instructions:
Make a directory called c:\ffmpeg\bin\
rename and copy ffmpeg.exe to several different ffmpeg's in the
c:\ffmpeg\bin\ folder
c:\ffmpeg\bin\ffmpeg1.exe
c:\ffmpeg\bin\ ffmpeg2.exe
c:\ffmpeg\bin\ ffmpeg3.exe
c:\ffmpeg\bin\ ffmpeg4.exe
c:\ffmpeg\bin\ ffmpeg5.exe
c:\ffmpeg\bin\ ffmpeg6.exe
In the c:\ffmpeg\bin directory, put a batch file called
c:\ffmpeg\bin\stream1.bat
c:\ffmpeg\bin\stream2.bat
c:\ffmpeg\bin\stream3.bat
c:\ffmpeg\bin\stream4.bat
c:\ffmpeg\bin\stream5.bat
c:\ffmpeg\bin\stream6.bat
Put the ffmpeg command for each stream in each batch file
For instance my stream1.bat looks like this
c:\ffmpeg\bin\ffmpeg1.exe -re -rtsp_transport tcp -i "rtsp://
admin:password at 201.58.112.10:554/VideoInput/1/h264/1" -f lavfi -f dshow
-rtbufsize 2000M -thread_queue_size 5096 -i audio="virtual-audio-capturer"
-c:a libmp3lame -ab 128k -ar 44100 -c:v copy -threads 0 -bufsize 512k -f
flv "rtmp://a.rtmp.youtube.com/live2/bfbp-3e10-sdh2-3hgj"
If you only have one stream you can just create the ffmpeg1.exe and
stream1.bat. It will give an error though if you try to start one of the
other streams and you didn't make the ffmpeg and batch file for it.
Here's a picture with some instructions.
https://github.com/mcshaf01/ffmpeg-stream-restart-tool/blob/master/instructions.jpg
On Wed, Nov 28, 2018 at 7:19 AM Mustafa Al Ani <mustafalani at gmail.com>
wrote:
> Hi Michael,
>
> I'm interested in your way of monitoring the bandwidth, can you share more
> info please?
>
> Regards,
> Mustafa
>
> On Wed, Nov 28, 2018 at 1:16 PM Michael Shaffer <mikeshaffer at gmail.com>
> wrote:
>
> > I don't know if there is a way to use ffmpeg to do it. I use a little
> > program I made to monitor the bandwidth and if it drops off it restarts
> the
> > stream. I'm using Ubuntu Linux and Python with the sysdig command to get
> > the bandwidth of each individual ffmpeg process. I have 5 ffmpeg's going
> at
> > once so this way I can restart only the one that crashes. With Windows
> you
> > can only get the bandwidth of the entire network card.
> >
> > On Wed, Nov 28, 2018 at 6:46 AM José María Infanzón <jocheinfa at gmail.com
> >
> > wrote:
> >
> > > Hi All, I'm streaming a live channel and I want to use ffmpeg to
> monitor
> > > the stream, what I need to check is when the image is frozen. Is there
> a
> > > way yo achieve this? I've read that I can use blend function, but not
> > sure
> > > how.
> > >
> > > Thanks!
> > > _______________________________________________
> > > ffmpeg-user mailing list
> > > ffmpeg-user at ffmpeg.org
> > > http://ffmpeg.org/mailman/listinfo/ffmpeg-user
> > >
> > > To unsubscribe, visit link above, or email
> > > ffmpeg-user-request at ffmpeg.org with subject "unsubscribe".
> > _______________________________________________
> > ffmpeg-user mailing list
> > ffmpeg-user at ffmpeg.org
> > http://ffmpeg.org/mailman/listinfo/ffmpeg-user
> >
> > To unsubscribe, visit link above, or email
> > ffmpeg-user-request at ffmpeg.org with subject "unsubscribe".
> _______________________________________________
> ffmpeg-user mailing list
> ffmpeg-user at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-user
>
> To unsubscribe, visit link above, or email
> ffmpeg-user-request at ffmpeg.org with subject "unsubscribe".
More information about the ffmpeg-user
mailing list