The first endpoint of segment AB
The second endpoint of segment AB
The first endpoint of segment CD
The second endpoint of segment CD
Optional
epsilon: number = 1e-8A small epsilon which defines a tolerance for near-equality
An intersection point, or null if no intersection occurred
An internal helper method for computing the intersection between two finite line segments. Adapted from http://paulbourke.net/geometry/pointlineplane/