Create a 2D segment.
the segment
- x coordinate of point 1
- y coordinate of point 1
- x coordinate of point 2
- y coordinate of point 2