Shader circles deformed on non-plane meshes

I’m new to shader technique, so i’m wondering how to make perfect circlrs on non-plane meshes.
NME PG: Babylon.js Node Material Editor

Want it keep this perfect shape on sphere:
image

but get this:

I think it’s the uv cordinates problem, but how can i draw circles in world cordinates?

PS: I just want to make an attack wave effect which shows the perfect circle shape well on the surface of a sphere, like the github homepage do:

Hello! Yeah, its related to the UVs, the sphere’s UV mapping isn’t perfectly flat on the ground like the plane, you can see this by drawing the UVs:
https://nme.babylonjs.com/#25IQXH

You can use the distance from the sphere’s vertices to any point, since these distances form a circle:
https://nme.babylonjs.com/#MDZWDW

2 Likes

Wow!
I really need this!
Many thanks!

You’re welcome, that was fun to code :rofl: