the following ffmpeg
permits to save images in highest quality to generate a timelapse:
export RTSP_STREAM='rtsps://abcdeffhijklmnop:1234/asdlfkjasdlf'
ffmpeg -loglevel error -rtsp_transport tcp \
-i $RTSP_STREAM \
-vf fps=1/120 \
-q:v 1 -strftime 1 \
"%Y-%m-%d_%H-%M-%S.jpg"
- the
vf
(videofilter)fps=1/120
selects one image every 120 second, adjust as needed q:v 1
selects the highest video setting for the exported images-strftime 1
permits to have the timestamp in the file name, as described here