Here's a more detailed breakdown of the second part of the setup, since I rushed a bit: 1. Create a connectivity on the prims, using uv connectivity; 2. Add a relbbox y mask to later orient the uv shells "up"; 3. Swap uv's to P(promoting to point attr in between) 4. Now we can measure the gradient of the mask y attr, which will create a vector attr along the "orientation" of the shell. 5. In the wrangle we calculate the angle between the x and y components of the gradient. Get the centroid of the uv island. Create a quaternion(could do it with matrices also), passing the angle we just calculated, around the z axis(uv space). Subract the pivot from the uv, qrotate, and finally apply the rotation to the uvs. Hope this helps. Cheers
@frigbychilwetherАй бұрын
Hi, really useful info. UV mapping objects from VBDs is always a pain - I usually just use labs auto uv but the orientation is often off. The technique you showed will be very handy. Thanks.
@hExZincАй бұрын
This was all kinds of helpful, thank you!
@imansamir3380Ай бұрын
Thank you! 👍
@JacKsCaveАй бұрын
Good tutorial !! Thanks!!
@ahmedaborady7883Ай бұрын
Amazing tip thank you 😍 Can you elaborate more on the calculating angle vex? it seems very interesting I'm not aware of this technique
@cgsideАй бұрын
Hey, check the pinned comment. Cheers
@k_johnyimАй бұрын
Great tutorial! One challenge I often encounter is orienting UVs for timber planks, especially when working on interior scenes like a room built from wooden boards. Timber grains typically run parallel to the longest side of a surface, and I’ve struggled with procedurally creating UVs that align correctly-particularly when the planks are placed at angles, such as along a pitched roof. Is there a way to procedurally texture timber to address this? It would be great to know if a solution exists!
@cgsideАй бұрын
Hey, it shouldn't be too hard as it's basically a rectangular geo. It would be easy to guess the angle with vex, similar to what I have done here. If you want, send me an example file on patreon, and I'll have a look. Cheers
@ognjean1Ай бұрын
You could try running a sort by proximity on the prims from the centroid distance. In theory prims 4 and 5 will be the furthest polys , so it should give you the plank cuts, which you could then use to map the gradient.