In this normal case, when we need to composite a image on another image, we use :
exec("convert 1.jpg 2.jpg -geometry +0+0 -compose DstOver -composite result.jpg);
and 0,0 points are the start line in left site of picture. I need to use my points from right side for example i have a jpg file with 500px height and 500px width and i need to composite image2 from 500,0 . its not good because if your image2 file has 100px in 100px height and width, your result hasn't any change in view.
my goal is compose from right side of image because my image2 has different width and height every time.
i mean i need compose from 3 and 4 point like picture. I try Imagemagick place image in bottom right corner but this solution compose with SouthEast , SouthWest and ... I need use my geometry size and points..
With image with fixed size i do not have any problem but i create text with imagemagick and it may with 1 charachter or more and in in this case my width of png text has different size.
Edit : In fact i get text from input and with different length then compose with background picture like:
ok, i need compose with right corner of "Sample Text 2" like picture, not left like "Text1" when i create text png file it may be created by different width and height . (sorry i can't explain better and sorry for my bad english)