Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a raw video that has the following properties:

  • 25 FPS
  • UYVY Codec
  • 876 MBit/s
  • AVI Container

I want to convert this raw file to another container using ffmpeg. Right now the problem is that the output video is being compressed. Any idea how to do this without compressing the output file. I have tried:

ffmpeg -i video.avi -r out.avi

and it did not help.

share|improve this question
up vote 4 down vote accepted

Note that ffmpeg is depricated in Ubuntu and other distros:

enter image description here

avconv is the one you want to use which is in in the libav-tools package and can be installed with the following line:

sudo apt-get install libav-tools

So here are some ways you can do it:

FFMPEG (Deprecated in 12.04+)

ffmpeg -i input.avi -vcodec copy -acodec copy output1.avi
ffmpeg -i input.avi -vcodec copy -acodec copy output1.mp4
ffmpeg -i input.avi -vcodec copy -acodec copy output1.mkv
ffmpeg -i input.avi -vcodec copy -acodec copy output1.mpg


avconv -i input.avi -vcodec copy -acodec copy output1.avi
avconv -i input.avi -vcodec copy -acodec copy output1.mp4
avconv -i input.avi -vcodec copy -acodec copy output1.mkv
avconv -i input.avi -vcodec copy -acodec copy output1.mpg

Am assuming that when you say "convert to anything else" and then you add that the output should not be compressed (And then I just so happen to see the bitrate) am thinking the original file, the input is RAW inside an avi container. If this is the case, the above options will work. They will just copy the content to another container, maintaining the 25fps, bitrate and overall quality.

If you do not want to copy the content, simply remove the part that says "-vcodec copy -acodec copy" and avconv/ffmpeg will take care of it.

NOTE - As mentioned by LordNeckBeard, the MP4 example will not work on Raw.

share|improve this answer
Just to clarify: Ubuntu switched to libav, and "deprecated" the libav version of the ffmpeg binary, but do not assume that the real ffmpeg from FFmpeg is not longer being developed. Quite the opposite! – LordNeckbeard Feb 22 '13 at 21:54
Also, rawvideo is not supported by the MP4 container (at least via ffmpeg). – LordNeckbeard Feb 22 '13 at 22:04
@LordNeckbeard thanks for the information about the MP4. Also in the answer I mention in bold that it was deprecated in Ubuntu. Same as OpenOffice was and others. They still continue but are not found by default on the system. The downvote was also not needed ;) – Luis Alvarado Feb 22 '13 at 23:09

Use ConvertMe!

enter image description here A fine media converter you have never used before...!?content=153277

share|improve this answer
The OP wants to use ffmpeg. – Seth Feb 20 '13 at 14:55
Well, that one is a "frontend based on ffmpeg". :) – carnendil Feb 20 '13 at 15:59


ffmpeg -i video.avi -sameq -r 25 out.avi

is your video really encoded with 800 MBit/s?

you can specifically set the video bit rate

ffmpeg -i video.avi -b:v 876104k -maxrate 1200000 -bufsize 876104k out.avi
share|improve this answer
try setting the bit rate manually, and/or force frame rate to 25 – phipsalabim Feb 20 '13 at 14:47
that didn't work neither ?? Either both buffer size and max rate or neither must be specified [mpeg4 @ 00000000020ec880] bitrate tolerance too small for bitrate – Engine Feb 20 '13 at 15:14
let's run it without the frame rate flag then. What happens. – phipsalabim Feb 20 '13 at 15:17
Do not use -sameq: it does not mean "same quality" and has been removed upstream. – LordNeckbeard Feb 22 '13 at 21:51

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.