-1

http://smotr.im/9KwB

There are some pictures: 1)a texture I have 2)a line I have already drawed with triangle strip 3)the result I need to achieve

The question is how to draw a texture inside these segments which are usually not regular quads?

1 Answers1

0

What do you mean, "usually not regular quads"? Are they quads or not?

If they are quads, just assign texture coordinates normally. The hardware will interpolate correctly.

If they are not quads, why don't you make them quads?

Minthos
  • 900
  • 4
  • 13
  • 1)"regular quad" means 4 angles in this figure and all these angles are equal. 2)"quad" means simply a figure with 4 angles. I want to know how to use mapping with the second type of figures. If you don't know math then I can downvote your answer too – user1826689 Dec 06 '12 at 06:23
  • I wasn't the one who downvoted your question. You don't need any math for this, the hardware will do the math. Just assign texture coordinates to the corners and the texture will be stretched correctly. – Minthos Dec 06 '12 at 09:17
  • I have found one of errors and texture is drawn more correctly now. But it looks like it divide a current texture into 2 parts and swap them around. And there are thin vertical white lines – user1826689 Dec 07 '12 at 14:07