Circular Mesh UV interpolation for tileable texture

Hi,


I have a circular ring mesh which I have generated procedurally. I also have a tileable texture which I want to place onto it. I have assigned UV coordinates to each vertex. This works for the most part but where the circle “closes” I get my whole texture squashed and mirrored between the last and first column of vertices:



I have set the indices so that the last and first triangle share the same column of vertices (0 u coordinate). I was hoping that the triangle’s UVs would be interpolated forwards from 0.95 → 1.0/0.0 without interpolating all the way backwards. Is this actually not possible?


The only solution I can come up with is to duplicate the first column of vertices and set their u coordinate to 1.0. In order to retain the smooth appearance I guess I would then have to manually set the vertex normals too, which currently I am not doing as the Mesh.RecalculateNormals() function works fine.


Many thanks,
Simon.

Like you say, you have to duplicate the vertices, since it’s kinda in the nature of how UVs work! And yes, set the normals manually too if you want the seam to share normals

You could also map the texture using math in the shader instead of UV coordinates, in case it’s circularly distributed, though it gets a little tricky if you want to deal with mipping properly at the seam :slight_smile: