   Picking single-color textures
  I have a similar problem as this poster: http://www.gamedev.net/community/forums/topic.asp?topic_id=529039I'm trying to implementing picking using unique colors as discussed at http://www.opengl.org/resources/faq/technical/color.htm but the problem I have is that my textures have transparency that shouldn't be pickable.To give you an example: - I give every texture I load a unique color to identify it when picking - When picking, I turn off texturing so that the unique color shows through - I can then click on things, read the color back, and pick them. That all works. - But as soon as I turn off texturing, any transparent areas in my texture are no longer transparent because the texture is no longer used. - Therefore I can click anywhere on the polygon behind the texture and it gets picked. - I need a solution that retains the transparency of my texture without its color.So... my idea for a solution is not to disable texturing, but instead to use the unique color for the texture. The problem is that I can't find an option to do this. GL_TEXTURE_ENV_MODE lets me change the texturing mode to GL_DECAL or GL_REPLACE so that the color of the texture takes priority over the color of the quad, but really I want the opposite - I want the polygon behind the texture to control the color regardless of what color the texture has.Essentially what I want is to be able to make a silhouette of a texture in any color I want.Is this possible/easy?   
  Set the combiners to output the primary color in the RGB channel, and the texture in the A channel. This means you cannot use the pre-defined combiner modes, but have to use the more general combiner functions. Check glTexEnv and its parameters. Then you can control the output via the primary color, and sill perform transparency in the alpha test or blending stage.   ;  << Set the combiners to output the primary color in the RGB channel, and the texture in the A channel. >>That sounds exactly what I'm after, but I'm afraid I just don't know how to do it :/<< Check glTexEnv and its parameters. >>I read the OpenGL documentation for glTextEnv a dozen times, and it makes my head hurt. I know it's important to be specific, but whoever writes those documentations seems more interesting in flexing their LaTeX skills than actually giving practical examples.   ;  If you're reading the API specification, you're looking in the wrong place if you want to learn the combiners. The specification is to describe exact behavior for professionals to know exactly how the API is supposed to behave. If you want to learn something, you need a tutorial dedicated to learning beginners. The specification is doing a good job at doing what it is supposed to do; describing the behavior.But unless you're not talking about the API specification, I don't see much LaTeX flexing in there. Just the very basic \subsubsection, some floating tables, a bit of inline math typesetting, some cross-referencing and a \color{red} to mark the section as deprecate... Not much LaTeX skills to flex, really.So search for a tutorial instead. Although still a specification, maybe  ARB_texture_env_combine specification can present what you want a little better. I got my combiners working a long time ago from that document, so it's not impossible for beginners. But as I said, find a tutorial dedicated towards learning if it's too much.   