Bezier curve's UV stretching

Hi everyone!

Is there a way to avoid the UV stretching over a bezier curve? I’m using the option “Use UV for mapping” under Texture Space menu and the UV option in the Texture Coordinate node. I’m trying to make a street and as you see the UV stretches depending on the distance between vertices, which in may case is specially problematic for the curves (I’m trying to make a road for a game).

Does anyone have any clue what could I do to make the UV mapping independent of the distance between vertices but that continues to follow the curve’s form?

Thank you :wink:

You can correct the texture mapping in the node editor by multiplying the X (or Y) component of the UVs.

Yes, but if I increase (or decrease) the values, the UV deforms still because is mapping on proportion of the distance between vertices. In the image you can see, over the closest curve the uv is too compact and in the straight lines too stretched.
Right now I’m looking to an alternative, which is to use the array modifier to generate the geometry over the curve. I’ll try and post the news if it does work.

Thanks for your answer :v:

  • Convert the curve to mesh (alt + c -> mesh from curve)
  • select one face, move the for verts to different corners of the 0-1 uv space
  • unwrap this face
  • select the whole mesh, the previous face is now the active face
  • unwrap with ‘Follow Active Quad’
2 Likes

Issue is that curve resolution is inherently between curve control handles and isn’t uniform. If you turn on view wires with a curve object, you can see what the U (resolution) setting does to the generated mesh. (Same mesh you will be getting when converting from curve to mesh object.)

A generic plop tile isn’t going to work nicely, as each quad generated is going to be distorted somewhat differently. The follow active quads will make a simple straightened out UV island set (and perhaps better use of available UV coordinate space), but the inherent stretching means it will still have to be texture painted to account for this.

Alternately if you turn on wires when editing the curve, you can see the curve density in relation to the set resolution and place new handles to account for this. Not automatically uniform, but it will allow you to approach it in a way that may work better with a tiling texture. (No guarantees, will take adjusting and some figuring out.)

Sorry for taking so long to answer, I was really busy these days.

I made some test today. Indeed, using the ‘follow active quads’ option works pretty well, but there are still some deformations. I’ve tried to subdivide the space between some handles, to make the space between them more uniform, but I it was too much work to achieve a good result.

The best solution I’ve found is, like saying before, to create a little part of the road and then use the curve to generate the geometry along it using the array modifier, as explained in this tutorial. It allows way more flexibility to make adjustments and the uv is always correct.

Thanks for your support guys :+1: