Translate + compose two images

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
dkrikun0
Posts: 5
Joined: 2019-06-24T03:19:56-07:00
Authentication code: 1152

Translate + compose two images

Post by dkrikun0 »

I have 2 images, a small and a big one. I would like to perform an SRT distortion (including translation) on the small image, and then compose it with the big one. The point is, I would like to translate the small one by an amount in the bigger image coordinates, so that the small image is not cut whatsoever.

I can do it with first extending the small one (using -extent) to the bigger image dimensions, but is there a more straightforward way to do it?
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Translate + compose two images

Post by snibgo »

Perhaps the "+" form, "+distort SRT" does what you want. See http://www.imagemagick.org/script/comma ... hp#distort
snibgo's IM pages: im.snibgo.com
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Translate + compose two images

Post by fmw42 »

Please show your command line code. It is hard for us to suggest solutions when we do not know what you did. Note that distort SRT allows translation. Also please always provide your IM version and platform when asking questions since syntax may vary.
Post Reply