set_focus

Renderer.set_focus(point)

Set focus to a point.

Parameters
pointsequence

Cartesian point to focus on in the form of [x, y, z].

Examples

>>> import pyvista
>>> mesh = pyvista.Cube()
>>> pl = pyvista.Plotter()
>>> _ = pl.add_mesh(mesh, show_edges=True)
>>> _ = pl.add_point_labels([mesh.points[1]], ["Focus"])
>>> _ = pl.camera  # this initializes the camera
>>> pl.set_focus(mesh.points[1])
>>> pl.show()
../../../_images/pyvista-Renderer-set_focus-1_00_00.png