

Once, you have installed ffmpeg, you can resize: a mp4 video. It works fine, but if anyone has an answer to this I'd be curious to know where I was going wrong. ffmpeg permits to set the dimension of a video to -1 in order to preserve aspect ratio. ffmpeg -i input-file.mp4 -vf scale300:200 output-file.mp4 Resize to given width or height Here we specify either width or height. Using FFMPEG with Python tutorialThis video will teach how you can pre-process your video by trimming, resizing or changing FPS using FFMPEG, which can be al. Resize to given width and height This may not preserve the aspect ratio. I would recommend saving the file, loading it with the image adapter of your choice(gd or imagick) and resize it using this. Command line utility ffmpeg can be used to scale a video to a specific widht and height. Same works for images too: ffmpeg -i input.jpg -vf scale320:240 output320x240.png.

UPDATE: I've simply resized the image and used that as input rather than resizing during the encode. That's not possible with the current code. If you need to simply resize your video to a specific size (e.g 320×240), you can use the scale filter in its most basic form: ffmpeg -i input.avi -vf scale320:240 output.avi. I need to resize input 3 (logo.gif) to 360x360, but using scale=360:360 just made my video quality really bad.
