I'm trying to perform a masking operation. I'd like to layer image A, which is a jpg, over image B, also a jpg, applying first an opacity mask in the form of a greyscale tif file to image A. I'm also rotating and scaling the mask as I load it. I'm able to create a png with transparency using this code:
Code: Select all
convert \( images/010-Scan-005.jpg \( mask.tif[5002x6238] -rotate 180 \) -alpha Off -compose CopyOpacity -composite images_depaper/010-Scan-005.jpg.png
but when i tie this together with the other image, the transparency does not seem to work:
Code: Select all
convert \( images/014-Scan-007.jpg \( mask.tif[4982x6230] -rotate 180 \) -alpha Off -compose CopyOpacity -composite \) test.jpg -composite images_depaper/014-Scan-007.jpg
Help! Thanks!