Determine whether point P is above or below a vector through points P1,P2

Possible values for z:

0 = On the vector

< 0 = Above the vector

> 0 = Below the vector

The function above is the ‘2D cross product’, therefore z is the surface of vector and