what is imadd function for?

Hi all
I want to union images. May I know what does imadd function on 2 images does actually?
Thanks Marcus

 Accepted Answer

Image Analyst
Image Analyst on 31 Dec 2012

0 votes

It's just a speedier way to do normal arithmetic addition on images - it uses special functions on the Intel CPU to make it go faster.
What do you mean by union? Do you want to add them? Stitch them together like you're making a panoramic picture? Find pixels that are identical in both images? Or something else?

5 Comments

what do u mean by stitch?
i am trying to find pixels that are identical in both images
mapOfMatchingPixels = image1 == image2;
OK, then what?
Stitch means to overlap and join together. Let's say you took a photo of the left half of your room and the right half, and there is, say, a third of the room that overlaps - it's in both photos. You can't just add those (assuming they've been aligned first) or else that would make that middle third twice as bright as it should be. So you have to be clever in which pixels you take and how you blend them together to make one larger "seamless" image. That's stitching. You could also stitch simply by doing [image1 image2] though that doesn't overlap any and would probably leave a visible seam.
I actually wanna blend 2 images together can u suggest a code for that?
sumImage = (single(image1) + single(image2)) / 2;

Sign in to comment.

More Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!