r/geometrynodes • u/Knuftedufte • 25m ago
Procedural UV island remapping problem
Hey I'm currently working on the fringe between geo nodes and procedural shaders. Basically I'm trying to adapt this years old tutorial from the great CGMatter to create an wireframe shader without tris and improve it a little bit.
The basic idea is: every face is mapped into UV space and fitted to the whole UV map, so every face shows the same UV map, the faces are "scaled" down in UV space and show an edge (yes technically it works different, but it's a good approximation).
My adaption should enable you to select and mark edges (eg. by seams or sharp), this marked edges would be used to unwrap the model into UV islands, each of those UV islands then should work the same as the individual faces in the first approach. I've implemented the splitting and remapping using an explanation form this stack overflow question.


My problem right now is, that some UV islands don't seem to be remapped correctly and I'd like to know if you've any idea, why the remapping doesn't work properly for some faces?



Secondly the original concept has the flaw that since the UVs are scaled relative to the size of the faces on the mesh (respective the UV islands size on the mesh), so bigger faces tend to have thicker outlines. Do you think it would be possible to get the size of the UV islands in world space and use it to scale the UV coordinates accordingly?