3

I'm trying to save the live feed from an IP camera to a file but the resulting file always plays much faster than the original speed.

I have tried with the following commands:

ffmpeg -i http://171.22.3.47/image -vcodec copy -an -t 900 c:\output.mp4

ffmpeg -i http://171.22.3.47/image -c:v libx264 -an c:\output.mp4

Does anybody know what I'm missing? Both commands create the file and I can use Windows Media Player to play them, but they run much faster.

LEM
  • 825
  • 6
  • 16
  • 31
  • To the person who downvoted me, could you give me a reason why my question is not appropiate? – LEM Aug 12 '15 at 19:40
  • My guess for the downvotes is that: 1) SO is for programming questions only so yours is offtopic (see [su]). 2) You provided no console outputs from your commands. – llogan Aug 15 '15 at 19:08
  • Thanks for your reply. It's weird because before posting my question I researched a lot about ffmpeg and what parameters to use to save a stream to a file, and most of what I found was on stackoverflow. See this one for example: http://stackoverflow.com/questions/16259588/how-to-dump-raw-rtsp-stream-to-file – LEM Aug 16 '15 at 21:23
  • That's also offtopic. It's a common occurrence. – llogan Aug 17 '15 at 19:38
  • 1
    full command line and uncut console output please? – rogerdpack Aug 20 '15 at 21:51
  • Did you try to set framerate manually with `-r 25` option? – EugZol Aug 20 '15 at 23:13

1 Answers1

0

Try forcing output framerate by adding -r key

ffmpeg -i http://171.22.3.47/image -c:v libx264 -an -r 30 c:\output.mp4

You can also try to slow down the resulting video as an option. This will make output.mp4 2 times slower:

ffmpeg -i output.mp4 -filter:v "setpts=2.0*PTS" -c:v libx264 -an output-slow.mp4
installero
  • 9,096
  • 3
  • 39
  • 43
  • I can't force the frame rate because on a live feed it's variable, it's not fixed. Slowing down it won't work either. I lost my reputation points for nothing with your answer... – LEM Aug 22 '15 at 00:40
  • 1
    Why slowing video down won't work? The command from my reply doesn't work you it's not an option for you? If the former is correct, please, add this information to your question (console output for my command). – installero Aug 23 '15 at 05:52