pyrobopath.toolpath.visualization.visualizer.visualize_toolpath#
- pyrobopath.toolpath.visualization.visualizer.visualize_toolpath(toolpath: Toolpath, backend='pyqtgraph', **kwargs)[source]#
Visualizes a toolpath using the specified rendering backend.
This function delegates rendering to either the PyQtGraph or Matplotlib backend, based on the backend argument. Additional keyword arguments are passed directly to the selected backend’s visualize_toolpath function.
- Parameters:
toolpath (Toolpath) – A
Toolpathobject to be visualized. This object typically contains a series of contours or motion segments, each with spatial and metadata attributes.backend (str, optional) –
The visualization backend to use. Valid options are:
"pyqtgraph": Uses the PyQtGraph backend for interactive, real-time plotting."matplotlib": Uses the Matplotlib backend for static rendering.
**kwargs (dict, optional) – Additional keyword arguments forwarded to the chosen backend’s visualization function. These may include plotting options such as color schemes, figure size, or title strings depending on the backend.
- Raises:
ValueError – If an unsupported backend name is provided.
See also
pyrobopath.toolpath.visualization.pyqtgraph_backend.visualize_toolpath,pyrobopath.toolpath.visualization.matplotlib_backend.visualize_toolpath,pyrobopath.toolpath.visualization.colors.get_contour_colorsExamples
>>> visualize_toolpath(toolpath, backend="matplotlib", color_method="tool") >>> visualize_toolpath(toolpath, backend="pyqtgraph", color_method="tool")