pub fn nearest_on_segment<S: Real, const N: usize>( p: [S; N], a: [S; N], b: [S; N], ) -> [S; N]
The point of the segment from a to b nearest p; a for a segment with no length.
a
b
p