I have a lot of mp4 full hd videos made with a smartphone that looks rotated 90°.
These files have proper rotation metadata and they plays correctly on VLC or other desktop mediaplayers, but I want to display them on my dvd player that does not handles mp4 metadata.
So I tried to transpose with ffmpeg but I obtain 1080x1920 files, resolution obviously not recognized by tv/dvd-player.
How can I transpose, resize and add black side (left/right) bars of the correct dimensions to get "correct" 1920x1080 videos?
Use
ffmpeg -noautorotate -i input.mp4 -vf "transpose=1,scale=-1:1080,pad=1920:1080:(ow-iw)/2:(oh-ih)/2" -c:a copy -metadata:s:v rotate=0 rotated.mp4
Depending on rotation, transpose may need value 2
.