Overlay a pixel range in one image with another image

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
merlino
Posts: 1
Joined: 2018-03-28T08:27:02-07:00
Authentication code: 1152

Overlay a pixel range in one image with another image

Post by merlino »

Does someone know how I could replace a certain pixel range in a picture with another image?

For example: if I want to change the color of the table in this picture, keeping in mind the square edges of the table and the shadows/lighting in the picture: http://www.stylemotivation.com/wp-conte ... 20x465.jpg

Maybe this is at all not possible with ImageMagick and should I be looking at other solutions. Any feedback would be greatly appriciated.
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Overlay a pixel range in one image with another image

Post by fmw42 »

The table colors are too similar to other colors in the image. The only way, would be to manually draw a mask image that would isolate only the table. Then you can modify the colors in the whole image to get the colors you want for the table. Then composite the two images using the mask to choose which part of each image to use in the output.
Post Reply