View Full Version : Drawing a line on top of a texture image

06-09-2008, 09:10 AM
I have created a texture image that is loaded onto a polygon. What I would like to do next is draw a rectangle on top of the texture image and make the rectangle translucent. What would be the best way to go about doing this?

06-09-2008, 09:20 AM
Draw textured polygon as usual.
Enable blending, set colors to RGBA with Alpha around 0.5, (disable depth test or move the rectangle toward the camera), and draw the rectangle.
Don't forget to re-enable depth test and disable blending before drawing the textured polygon again.

For reference, read this :

and this :

06-10-2008, 05:01 AM
Thank you for your help, I was able to get it to work :)