I have a 1080p video that i'm trying to resize for an iOS app upload. So i tried scaling it to the iPhone 6 resolution of 1334x750:
ffmpeg -i WrathTrailer.mp4 -strict -2 -vf scale=1334:750 WrathTrailer1334x750.mp4
The output file comes to 1333x750. iTunes connect won't accept it. Any ideas?
Here's a way to do it without the black padding. Note the force to aspect 1.779:
ffmpeg -i input.mp4 -strict -2 -vf scale=1334x750 -aspect 1.779 output.mp4
Not entirely what i wanted to achieve, but managed to do it by adding black padding:
ffmpeg -i WrathTrailer.mp4 -strict -2 -filter:v "scale=iw*min($width/iw\,$height/ih):ih*min($width/iw\,$height/ih), pad=$width:$height:($width-iw*min($width/iw\,$height/ih))/2:($height-ih*min($width/iw\,$height/ih))/2" WrathTrailer1334x750.mp4
Command sourced from: https://superuser.com/questions/547296/resizing-videos-with-ffmpeg-avconv-to-fit-into-static-sized-player
I used the command:
ffmpeg -i iPhonePreview.mp4 -strict -2 -vf scale=750:1334 -aspect 0.56271889 iPhone4.7.mp4
The real aspect is 0.56221889.
Experimentally, I find correct aspect: 0.56271889 (changed 2 to 7).