How do I calculate normals?

normals must indeed at a 90 ° angle to the surface are … how do I calculate that at a mesh?

I cant use RecalculateNormals becase this smooths my mesh

How do I calculate normals?

normals must indeed at a 90 ° angle to the surface are … how do I calculate that at a mesh?

I cant use RecalculateNormals becase this smooths my mesh

you need to set the normal for each vertex. Just use an array for your normals.

Like so:

*normals [yourVertices] = Vector3.up;*

Vector3.up should mean a 90° angle. (correct me if I’m wrong) After you’ve set your normals in the array just use:

*mesh.normals = normals;*

(sry my english isn’t the best but I hope it helps. ^^’ )

Hi, meshes have the same amount of normals than vertices so if you want to have different normals for 2 faces that share 1 or more vertices: you have to duplicate vertices (and then normals).

When it’s done, I guess that Unity’s RecalculateNormals will compute a normal for the face and not an average of all the faces that share the same vertex.

If not: you can use the cross product of 2 vectors from each triangle to compute the normal. If the triangle is ABC, a cross product between AB and AC will give you a vector to normalize to create a normal (maybe you’ll need to negate the normal to point “outside” or “inside” the mesh, as you need)