Capture video from vlc command line with a stop time

后端 未结 3 1751
轻奢々
轻奢々 2021-01-14 11:45

I\'m trying to capture a video from an RPT stream to my pc (Ubuntu 12-04 LTS). I\'m using vlc from command line as below:

cvlc -vvv rtp://address:port --start

相关标签:
3条回答
  • 2021-01-14 12:36

    If you know the start-time and the end-time you can compute the record time. You can afterward use the --run-time option to get what you want, like this: cvlc --run-time 60 --start-time 1260 /Path/to/your/file.ts vlc://quit

    0 讨论(0)
  • 2021-01-14 12:36

    Yes, this is a limitation of the stop-time option. It only works with streams with a known length. As captured video doesn't have this information as it is live (or more precisely, the capture access module don't even try to add said information), the option won't work.

    Patches are certainly welcome and sorry for the limitation.

    0 讨论(0)
  • 2021-01-14 12:37

    I tried vlc to record a webcam for a specific period. I ended up using the timeout command:

    timeout <seconds>s vlc v4l2:///dev/video1
    

    In Ubuntu it's available without any installation

    0 讨论(0)
提交回复
热议问题