Page 1 of 1

composite image from the center

Posted: 2008-05-24T01:39:49-07:00
by jnimo
hello again, i have another question (sorry for bugging)


i am trying to make a composite of 2 images and i always use this type of command

composite -dissolve 100% -geometry +24+5 file1.png file2.png file3.png

but there is sometimes when i want to put a image over other one but the corner of the first is out of the coordinates of the second image. so i put it from the bottom right cordinates.

composite -dissolve 100% -geometry -24-5 file1.png file2.png file3.png

but there is now a new problem, when i try to put a image over a second image and ALL the corners are outside of the coordinate system (like when i try to put a image with rotation in the corner of the second image and all the corners are out of the system). there is a way to make a composite with the coordinate of the center of the top image, i mean, i can have that coordinate but i don't know how i can make the composite. someone could help me?

Re: composite image from the center

Posted: 2008-05-24T04:55:48-07:00
by Bonzo
Replace -geometry with -gravity center

You can use both e.g. -gravity center -geometry +20+20 this will offset the image 20 x 20 from the center of the image.

Re: composite image from the center

Posted: 2008-05-24T05:07:23-07:00
by jnimo
yeah, but that put me in the center of the down image, i need to print with the center of the pot image, i don't know if i explain myself clear

Re: composite image from the center

Posted: 2008-05-24T05:14:57-07:00
by Bonzo
Have you tried to -trim your second image?

Otherwise a couple of example images would help.

Re: composite image from the center

Posted: 2008-05-26T09:47:26-07:00
by jnimo
thanks it works with that !!! :D