pyvista.Plotter.add_cursor#
- Plotter.add_cursor(
- bounds: Sequence[float] = (-1.0, 1.0, -1.0, 1.0, -1.0, 1.0),
- focal_point: Sequence[float] = (0.0, 0.0, 0.0),
- color: ColorLike | None = None,
- Add a cursor of a PyVista or VTK dataset to the scene. - Parameters:
- boundssequence[float], default: (-1.0, 1.0, -1.0, 1.0, -1.0, 1.0)
- Specify the bounds in the format of: - (x_min, x_max, y_min, y_max, z_min, z_max)
 
- focal_pointsequence[float], default: (0.0, 0.0, 0.0)
- The focal point of the cursor. 
- colorColorLike,optional
- Either a string, RGB sequence, or hex color string. For one of the following. - color='white'
- color='w'
- color=[1.0, 1.0, 1.0]
- color='#FFFFFF'
 
 
- boundssequence[
- Returns:
- vtkActor
- VTK actor of the 2D cursor. 
 
 - Examples - >>> import pyvista as pv >>> sphere = pv.Sphere() >>> plotter = pv.Plotter() >>> _ = plotter.add_mesh(sphere) >>> _ = plotter.add_cursor() >>> plotter.show() 