assembly

Submodule extending the vtkAssembly object functionality.

Assembly

class vtkplotter.assembly.Assembly(meshs)[source]

Bases: vtkRenderingCorePython.vtkAssembly, vtkplotter.base.ActorBase

Group many meshes as a single new mesh as a vtkAssembly.

gyroscope1.py gyroscope1.py

diagonalSize()[source]

Return the maximum diagonal size of the Mesh objects in Assembly.

getActors()[source]

Obsolete, use getMeshes() instead.

getMesh(i)[source]

Get i-th Mesh object from a Assembly.

getMeshes()[source]

Unpack the list of Mesh objects from a Assembly.

lighting(style='', ambient=None, diffuse=None, specular=None, specularPower=None, specularColor=None, enabled=True)[source]

Set the lighting type to all Mesh in the Assembly object.

Parameters
  • style (str) – preset style, can be [metallic, plastic, shiny, glossy]

  • ambient (float) – ambient fraction of emission [0-1]

  • diffuse (float) – emission of diffused light in fraction [0-1]

  • specular (float) – fraction of reflected light [0-1]

  • specularPower (float) – precision of reflection [1-100]

  • specularColor (color) – color that is being reflected by the surface

  • enabled (bool) – enable/disable all surface light emission