MultipleLines#
- MultipleLines(points: MatrixLike[float] | None = None) PolyData[source]#
Create multiple lines.
- Parameters:
- pointsarray_like[
float], default: [[-0.5, 0.0, 0.0], [0.5, 0.0, 0.0]] List of points defining a broken line.
- pointsarray_like[
- Returns:
pyvista.PolyDataLine mesh.
Examples#
Download Python source code | Download Jupyter notebook
Create a multiple lines between (0, 0, 0), (1, 1, 1) and (0, 0, 1).
>>> import pyvista as pv
>>> mesh = pv.MultipleLines(points=[[0, 0, 0], [1, 1, 1], [0, 0, 1]])
>>> pl = pv.Plotter()
>>> actor = pl.add_mesh(mesh, color='k', line_width=10)
>>> pl.camera.azimuth = 45
>>> pl.camera.zoom(0.8)
>>> pl.show()
See Create Connected Lines from Points and Color Several Lines for more examples.