Texture Mapping from a skewed quadrilateral to a rectangle in OpenGL

Started by
-1 comments, last by atg2012 11 years, 7 months ago
I have a polygon with the texture mapped in perspective mode, but I am required to look at the polygon along its normal so that it appears to be in 2D plane and then map the texture back on to it.
To start with I have something like this:
[attachment=11244:checker.jpg]

and I want to see something like this after I position my camera to look along the normal of this polygon
[attachment=11245:checker2.gif]

But, the result is split into 2 triangles along the diagonal and the texture has an effect of Affine mapped texture.
My texture image is a 2D image but the rendering in OpenGL is in 3D World Co-ordinates.
Currently for texture mapping I am supplying the vertices of the polygon and corresponding 2D texture co-ordinates.
Could any one advice on what I am required to do in order to get correct texture mapping? Appreciate all your help.
Thanks,

This topic is closed to new replies.

Advertisement