pysdic.Plotter3D.add_axes#
- Plotter3D.add_axes(*, size=0.2, line_width=2.0, x_color=None, y_color=None, z_color=None, label_color=None, x_label='X', y_label='Y', z_label='Z', show_labels=True, interactive=False)[source]#
Add an orientation widget showing the X, Y and Z axes in the bottom left corner of the plotter.
The widget follows the rotations of the camera, which helps to see the orientation of the displayed objects. It is not affected by the zoom or the translations of the camera.
- Parameters:
size (Real, optional (default:
0.2)) – The size of the widget as a fraction of the window size, in \((0, 1]\).line_width (Real, optional (default:
2.0)) – The width of the axis lines (strictly positive).x_color (Optional[Union[str, Tuple[Real, Real, Real]]], optional) – The colors of the X, Y and Z axes: a color name (e.g.
"red"), an RGB tuple or a hex string. PyVista defaults: red, green and blue.y_color (Optional[Union[str, Tuple[Real, Real, Real]]], optional) – The colors of the X, Y and Z axes: a color name (e.g.
"red"), an RGB tuple or a hex string. PyVista defaults: red, green and blue.z_color (Optional[Union[str, Tuple[Real, Real, Real]]], optional) – The colors of the X, Y and Z axes: a color name (e.g.
"red"), an RGB tuple or a hex string. PyVista defaults: red, green and blue.label_color (Optional[Union[str, Tuple[Real, Real, Real]]], optional) – The color of the axis labels. Default is set by PyVista.
x_label (str, optional (default:
"X","Y","Z")) – The labels of the axes.y_label (str, optional (default:
"X","Y","Z")) – The labels of the axes.z_label (str, optional (default:
"X","Y","Z")) – The labels of the axes.show_labels (bool, optional (default:
True)) – Whether to show the labels of the axes.interactive (bool, optional (default:
False)) – If True, the widget can be moved and resized with the mouse.
- Raises:
ValueError – If
sizeis not in \((0, 1]\) orline_widthis not strictly positive.- Return type:
None