You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix jolt_physics soft body vertex normal calculation
The code previously iterated through each face and set all vertices to
that face's normal. This resulted in each vertex getting the normal
from just one face that it belonged to (whichever face was last in this
array). This caused weird shading artifacts.
This fixes the code so that the vertex normal is now the average normal
of all faces that it belongs to. This results in "smooth shading"
behavior for soft body meshes. This is still somewhat undesirable if
the input mesh was using flat shading, but it looks less bad than the
previous behavior of picking a normal at random from one attached face.
This matches the behavior of GodotPhysicsServer3D.
Fixes#107831.
0 commit comments