Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to properly set UV for extruded spline texture
#1
Hi,
I am trying to setup a simple extruded mesh with custom material and texture in Curvy 6.
I did some textture baking in Blender 2.80 (image included) and edited U values in every spline point.

The problem is: I can't find how to set up the V coordinates of the extruded vertices. Generator is using all texture area resulting in black unwanted holes in my object.

How to fix this?

   

The texture is square. Should I make the UV's to cover all the texture area and do not try to limit mapping?
But then I will loose the object aspect ratio.
Or maybe I miss some settings?

Regards,
Piotr
Reply
#2
Hi,

The mesh extrusion will use the whole texture's V coordinates. The Volume Mesh CG module has UV Offset and UV Scale parameters, but I fear that this is not enough for your need (I a guessing that you want tiling to work with your sub-texture)

This being said, you can modify the code of existing module, or create a new module, to define a subset of the V values to be used.
If you want to modify the existing code, the code that defines the UV of the extruded mesh is in BuildVolumeMesh.createMaterialGroupUV method. Take a look at this line:
float v = mat.UVOffset.y + vol.F[sample] * mat.UVScale.y * grpAspectCorrection;
You can introduce a new parameter to the Volume Mesh module defining the valid values of V, and use that parameter in the v coordinate computation above.

If you need more help please let me know
Have a nice day
Please consider leaving a review for Curvy. This will help a lot keeping Curvy relevant in the eyes of the Asset Store algorithm.
Reply
#3
Thank You for explanation. I just made the new texture covering all the Vertical area and it works fine.
Reply
#4
You are welcome
Please consider leaving a review for Curvy. This will help a lot keeping Curvy relevant in the eyes of the Asset Store algorithm.
Reply


Possibly Related Threads...
Thread Author Replies Views Last Post
  Refresh spline doesn't seem to be working dazz777 2 41 11-08-2019, 09:01 PM
Last Post: dazz777
  Same Spline Extrusion with variable width MarioBag 5 631 11-04-2019, 01:56 PM
Last Post: _Aka_
  Change curvy gizmos to show direction of spline Horibe 1 39 11-01-2019, 07:02 PM
Last Post: _Aka_
  Deform mesh on the spline Nico_CL 3 160 10-09-2019, 04:10 PM
Last Post: _Aka_

Forum Jump: