sdynpy.core.sdynpy_geometry.GeometryPlotter

class GeometryPlotter(*args, **kwargs)[source]

Bases: BackgroundPlotter

Class used to plot geometry

This class is essentially identical to PyVista’s BackgroundPlotter; however a small amount of additional functionality is added.

__init__(*args, **kwargs)[source]

Initialize the qt plotter.

Methods

__init__(*args, **kwargs)

Initialize the qt plotter.

hide_origin_marker()

save_rotation_animation([filename, frames, ...])

Saves an animation of the rotating geometry to a file

show_origin_marker([arrow_scale])

Attributes

hide_origin_marker()[source]
save_rotation_animation(filename=None, frames=20, frame_rate=20, individual_images=False)[source]

Saves an animation of the rotating geometry to a file

Parameters
  • filename (str, optional) – Path to the file being saved. The default is None, which returns the images as an array rather than saves them to a file

  • frames (int, optional) – Number of frames in the animation. The default is 20.

  • frame_rate (float, optional) – Number of frames per second if the animation is saved to a GIF. The default is 20.

  • individual_images (bool, optional) – Boolean to specify whether the images are saved as individual PNG files or a single GIF. The default is False.

Returns

imgs – Returns array of images if filename is None, otherwise returns None

Return type

np.ndarray or None

show_origin_marker(arrow_scale=0.05)[source]