I'd like to know how to combine.

Questions and postings pertaining to the development of ImageMagick, feature enhancements, and ImageMagick internals. ImageMagick source code and algorithms are discussed here. Usage questions which are too arcane for the normal user list should also be posted here.
Post Reply
lojesus75
Posts: 9
Joined: 2017-02-01T19:50:50-07:00
Authentication code: 1151

I'd like to know how to combine.

Post by lojesus75 »

https://drive.google.com/open?id=1PYH0v ... 1_rgVYxuMm

Hello, Nice to meet you. Many times imageMagick users will help you with your questions.

The image shown above is a simple picture of what we are going to do.

Pattern + Shape -> Combined Pattern and Shape

The Shape contains a Pattern and the outside of the Shape is transparent.

ImageMagick seems to be able to do this. If you have experience or have ideas about these tasks, please reply.

Thank you for your active support.
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: I'd like to know how to combine.

Post by fmw42 »

Is there a question here? What did you try? What does not work?

Please, always provide your IM version and platform when asking questions, since syntax may differ. Also provide your exact command line and if possible your images.

See the top-most post in this forum "IMPORTANT: Please Read This FIRST Before Posting" at http://www.imagemagick.org/discourse-se ... f=1&t=9620

For novices, see

http://www.imagemagick.org/discourse-se ... f=1&t=9620
http://www.imagemagick.org/script/comma ... essing.php
http://www.imagemagick.org/Usage/reference.html
http://www.imagemagick.org/Usage/
https://github.com/ImageMagick/usage-markdown
lojesus75
Posts: 9
Joined: 2017-02-01T19:50:50-07:00
Authentication code: 1151

Re: I'd like to know how to combine.

Post by lojesus75 »

Using sample file

1. image.jpg
https://drive.google.com/open?id=1xmT8B ... z5UZbhzy8D

2. Pattern_1.jpg<
https://drive.google.com/open?id=1-PQtY ... qLvth1yq4z

My Snippet Code
convert image.jpg Patern_1.jpg -compose ChangeMask -composite overlay_removed.jpg

Test Environment
OS : Windows10
Version : ImageMagick-7.0.7-Q16

Reference Page
http://www.imagemagick.org/Usage/compose/#tile

First of all, I'm sorry I did not give you the detail information.
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: I'd like to know how to combine.

Post by fmw42 »

You did not say whether you wanted the black or white textured. So try one of these two.

Code: Select all

magick Pattern_1.jpg[1536x864+0+0] image.jpg -alpha off -compose copy_opacity -composite result1.png

Code: Select all

magick Pattern_1.jpg[1536x864+0+0] ( image.jpg -negate )  -alpha off -compose copy_opacity -composite result2.png

see -compose copy_opacity

http://www.imagemagick.org/Usage/compose/#copyopacity
Post Reply