I am trying to white balance my acquired image, but instead get a green image, has anyone encountered such a problem?

Similar to Vision's white balancing utility, my VI allows the user to draw an ROI around a region and ideally reset the red, green, blue gains to make the area white. When I make red, green, and blue values equal one another, instead of white, I get a green region. Has anyone else had this problem or know if I am doing something completely wrong?
Or has anyone tried doing this already and knows of a white balancing algorithm that works?
Thanks in advance.
- josh

Hi Chris,
I'm using IMAQ ColorImageToArray and I've checked with IMAQ IntegerToColorValue that I'm getting the correct RGB values. I can post my code, however, I am using a QImaging camera which only uses their own VIs to do functions similar to IMAQ functions such as grab setup, grab acquire, initialize, close. The VIs can be downloaded here: http://www.qimaging.com/support/downloads/.
Thanks again for the help.
Attachments:
whitebalance.vi ‏113 KB

Similar Messages

Maybe you are looking for