tesselation and triplanar mapping issues

Hello!
I am facing some serious tesselation artifacts while using a triplanar setup.
The problem is that while the diffuse textures etc are projected in planar mapping setup, the tesselation is displaced along the normals.
On cubes this looks ok, but on spheres e.g. this causes that the texture are not lining up the displacement. This looks like the textures are ‘swimming’ across the displaced mesh.
This is a common problem. One solution is to store the heightdata in vertex color and recreate planar mapping using vertexcolor.
I was wondering however, if someone has a better solution to this problem. On landscapes, I cannot store heightdata into a mesh. (i don’t know how)

Makes sense all this?
Best regards!
Tom

Never mind, I figured it out. The material function contains option to switch between inclusive / exclusive offset. That makes the difference.

Can you please elaborate on how you fixed the problem? I am having the same issue, thanks.

heey, oh this one was a long time ago! If you take a dive into the material function, there is a red node called ‘world position’ or something like that. And it contains 4 options but you have to switch to either ‘incl material offset’ or ‘excl. material offset’. That will make the texture really stick on the vertexes, no matter how you distort them.

@Millionviews: thanks for getting back to this old thread! Ok I see, this is the Absolute World Position node, it has options for including and excluding material shader offsets. I played around with those but this didn’t solve my problem, so mine must be different than yours.

hm…that I don’t know. Perhaps you can share a screenshot of what goes wrong and your shader setup. Would just be guessing otherwise. :wink:

a screenshot won’t do because swimming is only visible when moving, not on still images. Well to reproduce the problem that’s simple, just set up a mesh (like a rock) with a material using tesselation, then modulate the tesselation multiplier with the distance from camera, and there goes the swimming effect. Use the same technique on landscape, no swimming…

hm, haven’t tried tess a lot with regular meshes. Have you tried turning off the camera based multiplier? The landscape mesh is far more advanced. It contains some dynamic ‘fading’ between the indiv. tiles. Perhaps the swimming is still visible but just so tiny that you won’t notice. A screenshot of your shader graph would still be helpful. If you want to control the tess amount with distances, perhaps it is better to setup a LOD system of your meshes. So you keep the amount of tess for all meshes the same, but because on larger distances the LOD system kicks in you get the same amount of tess on low poly meshes. (hope this makes sense)

Yes, this is what I am doing currently to prevent the swimming issue, I use constant tesselation on LODs 0 and 1, the others have no tesselation. The drawback of this solution is the LOD transition is more visible.

I may post my graph later as I need to simplify it first.