10

I'm trying to convert an mp4 file to avi. I've tried this basic ffmpeg script:

ffmpeg -i inputFile.mp4 outputFile.avi

It works, but:

  • the encoded avi file is very pixelated
  • does not work with Quicktime Player.

I've also tried using these settings (as described here: https://askubuntu.com/questions/83161/use-ffmpeg-to-transform-mp4-to-same-high-quality-avi-file)

ffmpeg -i filename.mp4 -vcodec copy -acodec copy filename.avi

But the problem there is that the MP4 codec is just copied into an AVI wrapper, and so the resulting video won't play in Quicktime Player nor Windows Media Player.

Can anyone suggest how to encode MP4 as AVI while still maintaining the quality and aspect ratio of the original while maintaining QuickTime compatibility?

4

1 Answer 1

4

An AVI file is just a container and can contain any codec, so if you want to encode to QuickTime and Media player, you need to:

ffmpeg -i input.mp4 -c:v libx264 -c:a libmp3lame -b:a 384K output.avi

and above means:

  • Use the h264 Codec which both QT and WPlayer can display nowadays
  • use 384 Kbps MP3 encoding for audio

don't touch anything else like frame rate, resolution, ... and copy these as is.

0

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