normal

open fun normal(vertexData: IVertexData): Vector3(source)

Computes the normal vector of the polygon based on the given vertex data.

The method calculates the cross product of two edges of the polygon and normalizes the resulting vector to obtain the normal.

Return

A normalized 3D vector representing the normal of the polygon.

Parameters

vertexData

The vertex data that contains the positions of the polygon's vertices.