Why are the corners of my generated Mesh going dark/light like this?
Hi,
I am generating a mesh as shown in the images below. I am unsure of how to fix my issue where the corners of the mesh have funny lighting/shadows. Can someone help me?
Am happy to provide more information if needed. Screenshot includes most mesh settings.
It's because your upper mesh is tessellated differently than side polygons and the only vertices that connect those regions are these 6.
Thanks, do you have any advice on how to fix it?
In general, this is not Unity-specific question. You lack some poly-modeling technique skills (and that's ok) but you should ask this question on any blender or 3d modelling forum.
Answer by andrew-lukasik · Jul 06, 2021 at 09:42 AM
Tessellation like this is not a sustainable one ie. won't pass even semi-professional review, i can tell you that.
It's ok to add triangles to create better shading (not true for low-spec), but it needs to be done in an efficient manner.
Your cylinder is 144 triangles. Just look at what 140 triangles can give you:
The whole concept of the triangular mesh is to be able to procedurally generate terrain. I need evenly spaced vertices to do so. I understand that for an individual shape/model it is wildly inefficient.
Oh ok, I see why all this tessellation now. I hope you're using GPU Instancing too as it looks like a good use case.
While we're at it I think that these meshes don't need to be extruded like that. You can use tessellated hexagons with custom normals. Easy way to do that would be:
enable
Auto Smooth
then bake this normals by clickingAdd Custom Split Normals Data
:
delete all cylinder vertices but the top layer:
and now you have a hexagon shaded like it's a top of a cylinder mesh: