   Drawing textures with masking
  How can I draw a texture on a quad with masking? Is there a way that I can tell OpenGL not to draw any pixels in my texture that have a color value of 0, 255, 0?   
  Use alpha testing. Just mask those pixels you don't want to render.   ;  Create an alpha channel for your texture. Create a new buffer with 4 bytes per pixel and copy your texture data to it. For each pixel, copy over the color data from the old texture in the first 3 bytes and set the 4th (alpha) byte to 0 or 255. Use 0 for pixels that match the mask color, 255 otherwise. Load the new texture data into your ogl texture using an rgba texture format. Then set up the alpha test to discard pixels with an alpha value less than 255.   