startA.x + uA * (endA.x - startA.x),
startA.y + uA * (endA.y - startA.y));
Vector2f dist = new Vector2f(position);
dist.sub(startA);
float distFromVertA = dist.lengthSquared();
dist = new Vector2f(position);
dist.sub(startB);
float distFromVertB = dist.lengthSquared();
// z axis of 3d cross product