I blend two cubes (with seperate alpha values) using OpenGL, the alpha value of the upper cube is 128(translucent), the bottom one is 256(opaque). They display correctly on the screen. Then I wanna read opengl buffer using the following code segment:
glReadPixels(…, GL_RGBA, …,buf);
But I found that the alpha value of the pixels are not correct. I mean, the alpha value of the blending position is a value between 0 and 255, but not 255(the value I expected).
What’s the problem? (I using WinNT,VC6,and let OpenGL draw to window.)
Thanks in advance for any help.