Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

How to compare two images and display the difference on Front Panel

HI..

 

I have attached two images.

I want to compare these two images and subtract the differenc from these two images and display the difference(the mouse) on the front panel

Anyone can help me?

Really thanks

Download All
0 Kudos
Message 1 of 4
(3,378 Views)

In theory you could use "IMAQ Substract.vi". But this won't work with your images because almost every sinlge pixel is different from one image to the other one.

 

 

Christian

0 Kudos
Message 2 of 4
(3,364 Views)

Yes, I have tried already, the only thing i got is the differences of two images display in the front panel. In my program what i want is only the missing thing display in front panel. Is there anyone can help me please?

0 Kudos
Message 3 of 4
(3,351 Views)

The missing thing. You have to keep in mind that what you see is not the same as the camera sees.

 

So when using IMAQ Substract it gives you the difference of the value of every single pixel!

In order to find the mouse as only difference you have to manage that every other pixel value stays the same, e.g. with a proper lightening.

At the other hand you can combine different filters or alogorithms to get the object, e.g. if the object is darker or brighter then everything else in the image you could use a threshold and then use morphologic operations to get the objects size and position.

 

 

Christian

 

0 Kudos
Message 4 of 4
(3,349 Views)