fromLineSegment
Constructs a Line2D object from a given LineSegment.
Return
A line represented by the origin set to the start of the segment and a direction vector from the start to the end of the segment.
Parameters
segment
The line segment to create the line from, defined by start and end points.