But OpenGL doesn't actually work that way.
Let's look at the documentation so that we know what's going on (novel concept, that )
http://www.opengl.org/sdk/docs/man/xhtm ... mage2D.xml
andEach element is an RGB triple. The GL converts it to floating point and assembles it into an RGBA element by attaching 1 for alpha.
And glDrawPixels says: http://www.opengl.org/sdk/docs/man/xhtm ... quote]Each pixel is a three-component group: red first, followed by green, followed by blue; for GL_BGR, the first component is blue, followed by green and then red. Each component is converted to the internal floating-point format in the same way the red, green, and blue components of an RGBA pixel are. The color triple is converted to an RGBA pixel with alpha set to 1. After this conversion, the pixel is treated as if it had been read as an RGBA pixel.[/quote]The last three arguments describe how the image is represented in memory; they are identical to the pixel formats used for glDrawPixels.
So the end result of the noble attempt to save memory not only doesn't save memory at all, but actually slows the program down by forcing OpenGL to expand 3 component textures to 4 components before it can use them.
In other words, GL_RGB (or any other 3 component format, for that matter) is evil. Don't do it.