[FFmpeg-user] RTSP input source
Andriy Gelman
andriy.gelman at gmail.com
Thu Dec 17 17:34:37 EET 2020
Hi,
On Thu, 17. Dec 15:08, Sandeshwar Sharma wrote:
> Hi All,
>
> I'm creating an output video file continuously from an input RTSP source
> (cctv camera).
>
> But when the camera is disconnected (for any reason) from the network,
> ffmpeg takes a while (more than 1 minute) to throw an error.
>
> I would like to know which ffmpeg args needs to be passed to change this
> behaviour and detect the camera's disconnection as early as possible.
>
> Command I'm using:
> ffmpeg -stimeout 5000000 -i rtsp://192.168.0.200/stream0 -s 320x200 -f
> mpegts -codec:v mpeg1video -stats: -r: 30 -an output.mp4
If you apply these 4 patches to master:
https://patchwork.ffmpeg.org/project/ffmpeg/list/?series=2759
Then stimeout option will also apply while you are streaming.
--
Andriy
PS
you can quickly apply the patches with the following command:
$ curl https://patchwork.ffmpeg.org/series/2759/mbox/ | git am
More information about the ffmpeg-user
mailing list