Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I have been using WinFF tool to convert panasonic default .MTS videos into mpeg videos. However, I am not happy with the quality of the mpeg video output. Could some one tell me if there are any other tool for Ubuntu or the options that should I use in WinFF for getting high quality mpeg output.

share|improve this question

2 Answers 2

up vote 3 down vote accepted

This site has a great tutorial on how to do it, and includes a helpful bash script that joins the MTS files before starting, as apparently not doing so can cause problems.

If you want to experiment before jumping into his instructions, you can try the following command. This creates an x264 AVI, you can easily change the output format by changing the libx264 part below to mpeg4.

ffmpeg -i your_file.MTS -acodec copy -vcodec libx264 -crf 21 -r 30000/1001 -deinterlace -vpre lossless_medium -y -threads 0 output_file.avi
share|improve this answer
    
Getting the following error with the above command. –  samarasa May 27 '11 at 3:28
    
Getting the following error with the above command. please take a look. Error while opening encoder for output stream #0.0 - maybe incorrect parameters such as bit_rate, rate, width or height. –  samarasa May 27 '11 at 3:30
    
I'd try using the script in the site I linked to - the other thing is to make sure you have all of the codecs - perhaps you don't have libx264 installed? –  jozzas May 27 '11 at 3:50
    
I think you need to add -preset after -vcodec and also I think, depending on how you installed/compiled ffmpeg, the preset name is wrong. According to my compiled x264/ffmpeg the available presets are ultrafast,superfast,veryfast,faster,fast,medium,slow,slower,veryslow,placebo –  duffydack Oct 28 '11 at 17:22

I used jozzas' method explained above, and converted a 124MB test MTS file to a 55 MB MP4 file.

Then, I downloaded Handbrake using the PPA install method, and with a single pass high profile conversion, converted the test file in one pass to a 49 MB file with no loss of quality.

A two-pass conversion using Handbrake resulted in a 19 MB file, again, with no loss in quality.

So, which do you want, the command-line version which reduces file size by 55%, or the GUI version which reduces file size by 85% ?

share|improve this answer

Your Answer

 
discard

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.