Distortion Free Curve Uv-Map Generated In Geometry Nodes
This setup provides a quick and simple solution to a problem with Materials and Uv Mapping, which arises, when we create, generate, bevel and modify curves in Geometry Nodes.
Video demo here.
In principle, nothing could be simpler. We have a base curve and we bevel it by utilising the "Curve to mesh" node and a Curve circle. Logic dictates, that if we save the base curve along its length as X coordinate, and we save the "bevel circle" as the Y coordinate, we would get a nice, clean curve UV Map to use in the Shader Editor. HOWEVER, when we do this, distortions appear (due to issues with cyclicity).
This setup provides a simple, easy to dissect node to generate the UV for us (with reusability in mind). If we get our base curve and bevel circle, it generates the nice and neat curve uv map for us to use in the Shader Editor, by storing it in an accessible Named Attribute. In the shader editor, then, by using a Mapping node, we can finetune it to our liking.
The setup includes multiple examples, from the most basic curve to cyclic curves with materials based on checker texture or a seamless pattern image for illustration. Examine their GN node trees and their materials one by one ! (They are hidden in the Viewport by default) To see the materials, turn on textured mode in the viewport.
Thats all, enjoy !
----------------------------------------------------------------------
NOTE
-(Since it is a concept demonstration, it is kept as simple as possible.) The GeoNodes trees are kept clean for easier readability and have detailed explanations. Everything is built from the base. The point of these setups is to provide a base core of the concept, node from node, instead of contracting all into node groups with exposed settings, which makes everything harder to read and dissect.
You can embellish, refine as you wish based on the core or realize your own ideas.
- Read the text description, it has a lot of useful info !
Discover more products like this
uv map spring24 curve curve uv procedural uv mapping geometry nodes