Ask Your Question
0

how to make two images only different from the brightness become the same

asked 2013-11-03 07:55:45 -0600

qinling123 gravatar image

updated 2013-11-03 22:50:58 -0600

I take out two images only different from the brightness. I want to make them subtract with the function absdiff of OpenCV. But fail, how can I make them become the same. Thanks!

edit retag flag offensive close merge delete

Comments

Don't know what is your problem, if you want to make them same, just assign a to b, why do you want to subtract them?

stereomatching gravatar imagestereomatching ( 2013-11-03 08:16:26 -0600 )edit

I have made a program about the instrument detection. And I take out two images about the instrument pointer. I use perspective transformation to correct one of the images. Finally, I achieve two images different from the location of the pointer. I only need to compare the location of the pointer. So I use the OpenCV function absdiff to subtract them. But the result includes other information. I find two images have been different from the brightness. I need a good method to solve the problem so that the two images have the same brightness and are different from the pointer location. Thanks!!

qinling123 gravatar imageqinling123 ( 2013-11-03 20:45:13 -0600 )edit

Try to convert images to HSV color model and subtract only H channel

tenta4 gravatar imagetenta4 ( 2013-11-04 07:02:44 -0600 )edit

1 answer

Sort by » oldest newest most voted
0

answered 2013-11-03 23:10:58 -0600

In the first,you have to change the color space of image from BGR to HSI then specify the mask image form the region of original object.

In the next stage ,you compute homography matrix then transform the input image to the original state.

In the finial stage,the two images are normalized then compute the difference of Intensity channel according to the mask image.

edit flag offensive delete link more

Question Tools

Stats

Asked: 2013-11-03 07:55:45 -0600

Seen: 1,162 times

Last updated: Nov 03 '13