Original Post
Hi, i have 2 2D textures on a quad, a big texture set as a background, and a small texture to put on top of the first texture, so the small texture has a color value green, which i dont want it to be shown. How can i do this? //this is my render function, where i am rendering the 2 textures Render() { glClear(GL_COLOR_BUFFER_BIT); glEnable(GL_TEXTURE_2D);//(NEW) Enable 2D texturing //big texture glBindTexture(GL_TEXTURE_2D, textures[0]); glPushMatrix(); glBegin(GL_QUADS); glTexCoord2f(0,1);//This is the upper left corner of the square glVertex2f(-3.5f,2.1); glTexCoord2f(1,1);//This is the upper right corner of the bitmap glVertex2f(3.5f,2.1); glTexCoord2f(1,0);//This is the lower right corner of the bitmap glVertex2f(3.5f,-3.5); glTexCoord2f(0,0);//The lower left corner glVertex2f(-3.5f,-3.5); glEnd(); glPopMatrix(); //smaller texture glBindTexture(GL_TEXTURE_2D, textures[1]); glPushMatrix(); glBegin(GL_QUADS); glTexCoord2f(0,1);//This is the upper left corner of the square glVertex2f(-1.5f,1.1); glTexCoord2f(1,1);//This is the upper right corner of the bitmap glVertex2f(1.5f,1.1); glTexCoord2f(1,0);//This is the lower right corner of the bitmap glVertex2f(1.5f,-0.5); glTexCoord2f(0,0);//The lower left corner glVertex2f(-1.5f,-0.5); glEnd(); glPopMatrix(); glDisable(GL_TEXTURE_2D); glutSwapBuffers(); }