View Full Version : RGGB color and window control.

10-17-2006, 09:42 AM
I have color RGGB camera data that I am trying to display. So far the best I have come up with is to get it into an array (ncol,nrow,3) throwing out one of the G channels, then use Image_Create to generate the Assoc. array neccessay to display using Image_Display. This would probably work OK except that I can't seem to control the Image_Display. I've tried using the window and wset keywords but no matter what I do it keeps popping up a new window for every image at the four corners of my display instead of just putting it in a window I want it in. Are there any better ways to display this data? How do I control the windows if I use Image_Display?

10-18-2006, 12:11 PM
Well, I never did figure out how to control the Image_Display windows but I did discover that the image can be displayed where I want it using the
command (Which according to the documentation only works on Unix and OpenVMS), but the truth is it appears to be working in Windoze XP fortunately for me!

10-27-2006, 09:44 AM
Hi phillipsqh,

The documentation is wrong with respect to TV's True keyword only working on Unix and VMS systems. As you have found, the behavior extends to Windows platforms.

For the most control over your image, do as you have done and use the TV command to display the image array directly. IMAGE_DISPLAY is merely a convenience routine to do just this, but as is often the case, having more direct control is desirable. Along these lines, you may want to read through the Whitepaper titled "8-bit and 24-bit Color Graphics in PV-WAVE". This can be found at http://www.vni.com/company/whitepapers/

In general, if you already have an image file then you could do something like

WAVE> img_asarr = IMAGE_READ('myimage.jpg')
WAVE> img = img_asarr('pixels')

and now the img variable will just be the "raw" data, unpacked from the image associative array.

Can you tell me what the extra G stands for in RGGB?


10-27-2006, 11:29 AM

The G indicates the extra Green pixel associated with a Bayer filter patten camera.


BTW A Bayer filter has 4 possible pixel orders: 'RGGB', 'BGGR', 'GBRG', 'GRBG'