Jump to content

  • Log In with Google      Sign In   
  • Create Account


#ActualVexal

Posted 07 March 2013 - 11:44 AM

I am having trouble properly connecting the texture coordinates (example: cylinder with 16 segments) at index 0 and index 15.  I just give each face the texture coordinate corresponding to the segment number, so the first face has texture coordinates (0, 0), (1, 0), (0, 1), (1, 1), the second face has (1, 0), (2, 0), (1, 1), (2, 1), etc.  The last face has (15, 0), (0, 0), (15, 1), (0, 1).

 

I am fairly certain the problem is that the last face has to connect to the 0th coordinate, but I can't figure out a way around this without duplicating the vertices.

 

I also tried to give all even-numbered segments the texture x-coordinate 0, and odd-numbered segments with texture x-coordinate 1, but that still didn't seem to fix it.

 

EDIT:  Nevermind.  It was an unrelated bug.  Sorry.  Alternating 1 and 0 does work, the other method does not.


#1Vexal

Posted 07 March 2013 - 11:27 AM

I am having trouble properly connecting the texture coordinates (example: cylinder with 16 segments) at index 0 and index 15.  I just give each face the texture coordinate corresponding to the segment number, so the first face has texture coordinates (0, 0), (1, 0), (0, 1), (1, 1), the second face has (1, 0), (2, 0), (1, 1), (2, 1), etc.  The last face has (15, 0), (0, 0), (15, 1), (0, 1).

 

I am fairly certain the problem is that the last face has to connect to the 0th coordinate, but I can't figure out a way around this without duplicating the vertices.

 

I also tried to give all even-numbered segments the texture x-coordinate 0, and odd-numbered segments with texture x-coordinate 1, but that still didn't seem to fix it.


PARTNERS