Save video recorded from Raspivid as .mov instead of .h264

1.1k views Asked by At

I am using a Raspberry Pi camera module to record a small 10 second video. I want to send that video to an iPhone application, through the cloud. So, I want to convert the .h264 to .mov to be able to play it in iOS.

I am using raspivid like this:

raspivid -w 640 -h 480 -fps 24 -t 10000 -o output.h264

I am getting the video, and am able to open it in VLC player after transferring it to my Mac, but I am not able to convert it to .mov or .mo4 or any other format using avconv or ffmpeg reliably.

avconv -i output.h264 -c copy output.mov 

gives me a fps of 240 and the video is of zero seconds.

ffmpeg gives frame mismatch errors, and setting it using -r option doesn't work, and again I get a fps 240 video.

Any suggestions? I am open to options that will let me record .mov directly from RPi, convert my .h264 to .mov, or to be able to play the .h264 in iOS directly.

Thanks a ton!

1

There are 1 answers

0
tansix On

I ended up using MP4Box to convert the file format. Works for me! I hope someone else can benefit from this.