Improvement to start and end of 3D lines.