Am I Doing It Right?
Posted: 2016-06-03T16:55:04-07:00
Hi,
I have recently started looking into ImageMagick to generate a series of frames to be later combined into a movie using ffmpeg. The frames need to simulate a ken burns style pan and zoom where each image will pan and zoom at 30fps for up to 20 seconds (600 frames). Doing this at 1920x1080 is quite processor intensive but i have found a fair bit of optimizations already by running convert concurrently with 20 shell commands and bulk writing out 40 images using mpr.
This is my current code
Is there a better way of doing this?
Cheers
Graham
I have recently started looking into ImageMagick to generate a series of frames to be later combined into a movie using ffmpeg. The frames need to simulate a ken burns style pan and zoom where each image will pan and zoom at 30fps for up to 20 seconds (600 frames). Doing this at 1920x1080 is quite processor intensive but i have found a fair bit of optimizations already by running convert concurrently with 20 shell commands and bulk writing out 40 images using mpr.
This is my current code
Code: Select all
./convert source.jpg -interpolate Blend -set option:distort:viewport 1920x1080-0-0 -write mpr:tmp +delete \
mpr:tmp -distort SRT "0.1,0.0 1.1 0 0,0" -write "out_1.jpg" +delete \
mpr:tmp -distort SRT "0.2,0.0 1.1 0 0,0" -write "out_2.jpg" +delete \
....
mpr:tmp -distort SRT "4.6,0.0 1.1 0 0,0" "out_X.jpg"
Cheers
Graham