A polyline drawn between vertices.
This adds functionality beyond [page:Line], like arbitrary line width and changing width to be in world units. It extends [page:LineSegments2], simplifying constructing segments from a chain of points.
[name] is an add-on, and therefore must be imported explicitly. See [link:#manual/introduction/Installation Installation / Addons].
import { Line2 } from 'three/addons/lines/Line2.js';
[example:webgl_lines_fat WebGL / lines / fat ]
[example:webgl_lines_fat_raycasting WebGL / lines / fat / raycasting ]
[example:webgpu_lines_fat WebGPU / lines / fat / raycasting ]
[page:LineGeometry geometry] — (optional) Pair(s) of vertices representing each line segment.
[page:Material material] — (optional) Material for the line. Default is a [page:LineMaterial] with random color.
See the base [page:LineSegments2] class for common properties.
Read-only flag to check if a given object is of type [name].
See the base [page:LineSegments2] class for common methods.
[link:https://github.com/mrdoob/three.js/blob/master/examples/jsm/lines/Line2.js examples/jsm/lines/Line2.js]