Composite with resize & gravity center in one line
Posted: 2017-07-23T01:57:52-07:00
Hello
I'm trying to resize/crop images and composite them in a larger to make triple screens wallpaper.
So at first i use
for all my images and i composite them after with
But i'm wondering if i could do that in one command
i end up with this command
but my images are not verticaly centered.
If i add -gravity center it center my whole canvas so my first wallpaper is on the second screen, the second on the third screen and the third wallpaper is invisible because the canvas is moved 1920px to the right
Is this kind of job is possible in a single command ?
Thank you.
I'm trying to resize/crop images and composite them in a larger to make triple screens wallpaper.
So at first i use
Code: Select all
convert 1.jpg -resize 1920x1080^ -gravity center -extent 1920x1080 1-resize.jpg
Code: Select all
convert -size 5760x1080 xc:white 1-resize.jpg -geometry +0+0 -composite 2-resize.jpg -geometry +1920+0 -composite 3-resize.jpg -geometry +3840+0 -composite triple.jpg
i end up with this command
Code: Select all
convert -size 5760x1080 xc:white 1.jpg -geometry 1920x1080^+0+0 -composite 2.jpg -geometry 1920x1080^+1920+0 -composite 3.jpg -geometry 1920x1080^+3840+0 -composite triple.jpg
If i add -gravity center it center my whole canvas so my first wallpaper is on the second screen, the second on the third screen and the third wallpaper is invisible because the canvas is moved 1920px to the right
Is this kind of job is possible in a single command ?
Thank you.