[FFmpeg-user] Problem creating video segment from still image
John G. Heim
jheim at math.wisc.edu
Tue Dec 3 19:22:16 EET 2024
I am blind but I'm trying to create a promotional video for my disabled
rock climbing group. I would like to insert a still image into the
video. The video has resolution 1280:720 so I resized the image to be
less than 1280x720. ffprobe seems to indicate this worked:
$ ffprobe -v error -select_streams v:0 -show_entries stream=width,height
snapshot.jpg
[STREAM]
width=960
height=720
[/STREAM]
When I use ffmpeg to create a 2 second video from the image, it seems to
flip the XY dimensions:
$ ffmpeg -loop 1 -i snapshot.jpg -c:v libx264 -t 2 -pix_fmt yuv420p -y
snapshot.mp4
$ffprobe -v error -select_streams v:0 -show_entries stream=width,height
snapshot.mp4
[STREAM]
width=720
height=960
[/STREAM]
Am I doing something wrong? I can't just look at it to see if it looks
right because I'm blind. Here are links to the still image and the video
I created:
https://people.math.wisc.edu/~jheim/Climbing/snapshot.jpg
https://people.math.wisc.edu/~jheim/Climbing/snapshot.mp4
More information about the ffmpeg-user
mailing list