closest_points_line_line_parameters_eps

Function closest_points_line_line_parameters_eps 

Source
pub fn closest_points_line_line_parameters_eps(
    orig1: Vector,
    dir1: Vector,
    orig2: Vector,
    dir2: Vector,
    eps: f32,
) -> (f32, f32, bool)
Expand description

Closest points between two lines with a custom tolerance epsilon.

The result, say res, is such that the closest points between both lines are orig1 + dir1 * res.0 and orig2 + dir2 * res.1. If the lines are parallel then res.2 is set to true and the returned closest points are orig1 and its projection on the second line.