I have a little problem calculating the normals for my DEM. This is a weird behavior. The normals are good at the top and bottom points, but in the middle they seem to be wrong. They are spotlighted.
REMOTE SOURCE
EDIT: Tried 2 new approaches:
This is normal. It looks great, but you see individuals.
Position normal = crossP(vectorize(pOL, pUR), vectorize(pOR, pUL));
I also tried to do this per-vertex this way, but also with a weird way out.

This is a proposal made by Nico:
He also looks rather strange. Maybe there is a mistake in how I calculate the help points.
REMOTE SOURCE

EDIT 2: Defining my points: OL, OR, UL, UR - the angular vertices of the plane that should be drawn.
postVertPosZ1 postVertPosZ2
preVertPosX1 pOL pOR postVertPosX1
preVertPosX2 pUL pUR postVertPosX2
preVertPosZ1 preVertPosZ2
EDIT3:
. :
y .
.
