Dear forum members,
I’m new to OpenGL…
I try to develop an application which renders images to a window. Nothing complicated so far, this works with RGB data without problems.
But: The data I would like to render comes from a CMOS sensor and is 10 bit grayscale (my second sensor deliveres 12 bit raw data).
Is there a way to let glDrawPixels draw these pixel data and let opengl do the conversion from 10/12 bit to the 8 bit of the screen? Or do I have to convert it by myself, either by downscale it from 10/12 to 8 or to cut off the bits?
If I cut off the lower bits, the resulting 8 bit grayscale image is okay - opening in photoshop for example. And: how may I render a 8 bit grayscale image?
Any comments welcome!
Best Regards,
Johann