distance_line_segments [function]
distance_line_segments( vec3 a1, vec3 a2, vec3 b1, vec3 b2 )
returns distance between two line segments
This function may not return the expected result if either of the lines has zero length. In such cases, prefer using distance_point_line_segment