11-10-2008 09:00 PM
Hi~
I'm using LabWindowsCVI8.5 and NI Vision to do the Image processing. When I read the "IMAQ Vision for LabWindowsCVI Reference Manual", I found that the imaqBCGTransform function only supports 8-bit Image, while I have to do the BCG tranform on 16-bit image. Is there any solutions to use BCGTransform function to process 16-Bit Image? Or Is there any other functions which could do the Brightness, Contrast and Gamma correction on 16-bit Image?
Thanks a lot!
Solved! Go to Solution.
11-14-2008 05:51 AM
given that imaqBCGTransform is implemented as a lookup table, we can understand why it is limited to 8-bit images.
now let's have a look at the definition of each of this terms (from the NI Vision Concepts documentation):
- brightness: A constant added to the red, green, and blue components of a color pixel during the color decoding process;
- contrast: A constant multiplication factor applied to the luma and chroma components of a color pixel in the color decoding process.
- gamma correction: Expand the high gray-level information in an image while suppressing low gray-level information. (the chapter on lookup tables gives some examples of gamma corrections)
now that you understand that this transform is a simple mathematical function, you only have to compute the correction for each pixel on your 16-bit image.
i don't know the exact formula used by the imaqBCGTransform function, but you should be able to approximate it by performing some test on 8 bit images with the original function... or you can roll your own formula... or find one on the net...or you can ask someone at NI to give you the formula...
10-26-2009 12:27 AM