Texture coordinates help

So I have a image which is basically a straight line going from left to right. I’m using that as the texture and trying to get corners using that. So far I have been able to get it going straight in all directions (up, down, left and right). I have been able to get it to make 2 corners but I cannot figure out how to make the other 2.
For a corner where the line goes up and left the coordinates are:
(1,1),(0,0),(0,1),(1,1)
For down and right:
(1,1),(0,1),(0,0),(1,1)

I cannot get it to go Up & Right or Left & Down however…

Fairly new to texture coordinates (and to be honest I figured out some of these by accident) so thanks for the help in advance.

The ideal way of doing this is not altering the texture coords, but rotating the image internal to the shader. I have code for this laying around some place… though, I’ll have to track it down. I’ll post it as soon as I find it.

I don’t know enough about your mesh and your image but I suspect you are running into a problem related to how quads are divided into triangles. Along one diagonal things work that don’t work along the other diagonal.

@pspeed said: I don't know enough about your mesh and your image but I suspect you are running into a problem related to how quads are divided into triangles. Along one diagonal things work that don't work along the other diagonal.
My mesh makes a quad. And I completely understand what you are saying, it works along the diagonal where the triangles split but not the other way.