Texture Rounded Box

Does someone know how to recalculate the UV’s properly for this sphere that’s been stretched into a rounded box?

Thanks in advance for having a look.

I’ve been fiddling with this:

but i can’t get it to work for the rounded cube.

I would create three objects: one top, one middle and one bottom and then merge them. So I would bypass the stretching and the UV’s would not have to be recalculated.

I have tried to construct it from separate meshes indeed here:

but i can see the seams and when you add a scaling in 1 direction it doesn’t look clean anymore.
I guess i am looking for a Box or Cube projection UV algorithm like in Blender.
Furthermore i though that the stretching idea was kinda neat.

Adding @PatrickRyan

@WillemCramer, I can’t help much with the cube projection algorithm for UVs since I do most of my mesh creation in a DCC tool rather than in code. However, another approach to your issue if you are truly looking for a seamless texture is to forego the UVs all together and use Tri-Planar Projection in either the in box Tri-Planar Mapping Material or in the node material TriPlanarBlock. I had done a stand alone manual tri-planar node material example before we introduced the material and node material block if you want to see the process exploded into individual nodes. The left mesh is a standard UV projection from Maya to a sphere and the middle and right meshes are using tri-planar projection for the textures.

Not quite the answer you were looking for, but possibly a different take on the problem.

2 Likes

Patrick :slight_smile: This seems to be what i am looking for indeed i just hope i am coder enough to implement it. The elephants look impressive so i am hopeful. THANKS!
@sebavan too :+1:

1 Like

AH - i now see it doesn’t solve the UV problem, but it is a great method i will certainly use!

1 Like

Progress,
In case you’re still interested @PatrickRyan , @sebavan and @CodingCrusader

3 Likes

Here is another method btw constructed by someone obviously more knowledgable than i am :wink:

2 Likes