Compose images

Magick.NET is an object-oriented C# interface to ImageMagick. Use this forum to discuss, make suggestions about, or report bugs concerning Magick.NET
Post Reply
pablobhz
Posts: 72
Joined: 2016-05-07T06:47:14-07:00
Authentication code: 1151

Compose images

Post by pablobhz » 2018-11-26T11:56:40-07:00

Hello Everyone.
I'm trying to do some image composition here but i'm having some trouble.
I've did this before but now it seems that i forgot what i did (shame on me).

Well, lets go to the business.

I'm tryng to place this imag (Image A)
https://drive.google.com/file/d/16lUKOZ ... sp=sharing
Over this image(Image B)
https://drive.google.com/file/d/1miN3Iq ... sp=sharing

However, it isn't working. I've tried some Composite operators but i'm always getting weird results. The final image is completely black, or it only shows the A image with some details but not the perfect picture.

I've uploaded the images to google drive to preserve their channels and transparecy.

My current code is:

Code: Select all

baseImage.Composite(overImage, Gravity.Center);                    
Where baseimage is image B, and overimage is image A. I've tried the opposite and it didn't worked too.

Any input is appreciated.

Thanks in advance !

pablobhz
Posts: 72
Joined: 2016-05-07T06:47:14-07:00
Authentication code: 1151

Re: Compose images

Post by pablobhz » 2018-11-26T12:40:50-07:00

After analyzing the code calmly and think about things...i figured it out.

Code: Select all

FinalPreview.Composite(CurrentImage, Gravity.West, CompositeOperator.Overlay);
This does the job =) !
Thanks in advance for the awesome Library.

Post Reply