Function de_controller::hud::minimap::fill::endpoints_to_line
source · fn endpoints_to_line(
start: Option<Vec2>,
end: Option<Vec2>
) -> Option<(Vec2, Vec2)>
Expand description
Converts optional line endpoints to a minimap compatible line segment.
The returned line segment is the longest line segment which a) is fully contained by rectangle (0, 0) -> (1, 1), b) is fully contained by the original line segment.