Last active
December 11, 2018 13:00
-
-
Save baoilleach/5983218 to your computer and use it in GitHub Desktop.
Create an animated gif to morph between images using ImageMagick
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
convert CID10033747.png CID9919714.png CID10033747.png -loop 0 -morph 9 -gravity South -annotate 1x1 "%t" -set delay "%[fx:(t%10!=0 || t==n-1)?10:240]" morph.gif |
Hi Jack, sorry I missed your comment a while back. Looking at the expression, it seems to be setting a long delay (240ms) if it's every tenth frame and it's not the last frame. My guess is that the "morph 9" is related to the tenth frame business, and that as it's a loop there's no need to pause on the final frame as it will be pausing on the identical first frame.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
can you explain / comment on:
-set delay "%[fx:(t%10!=0 || t==n-1)?10:240]"
I morphed 3 images together.. it takes 3-4 seconds for the first 2 images to morph to completion,
The 2nd -> 3rd image seems to morph faster.. and then it only shows the 3rd image for about half a second and then it starts over again.
how can you do a constant transition time between images AND have the last one display for the same amount of time before starting over?
thanks - jack