what GL_LUMINANCE does?

hi,
working on some code i came across the commands:

glTexImage3D(GL_TEXTURE_3D,0,GL_LUMINANCE8,width,height,horizon,0,GL_LUMINANCE,GL_UNSIGNED_BYTE,data);

and

glTexImage2D(GL_TEXTURE_CUBE_MAP_POSITIVE_X + i,0,GL_LUMINANCE8_ALPHA8,size,size,0,GL_LUMINANCE_ALPHA,GL_UNSIGNED_BYTE,data);

just what is the GL_LUMINACE format? I tried to man it, but i couldn’ understand the explanation… Can someone put it in plain english pls???

Thx the Gunslinger

It’s single channel format where the single channel is copied into R, G and B, and alpha is set to 1. Basically, a greyscale format.

From MSDN:
GL_LUMINANCE: Each element is a single luminance value. It is converted to floating point, and then assembled into an RGBA element by replicating the luminance value three times for red, green, and blue, and attaching 1.0 for alpha. Each component is then multiplied by the signed scale factor GL_c_SCALE, added to the signed bias GL_c_BIAS, and clamped to the range [0,1] (see glPixelTransfer).

[This message has been edited by gvm (edited 02-18-2004).]

well it makes sense,
since I am passing a greyscal texture to compute the horizon mapping

thank you
the G.