pyvista.AxesGeometrySource

pyvista.AxesGeometrySource#

class AxesGeometrySource(
*,
shaft_type: GeometryTypes | DataSet = 'cylinder',
shaft_radius: float = 0.025,
shaft_length: float | VectorLike[float] = 0.8,
tip_type: GeometryTypes | DataSet = 'cone',
tip_radius: float = 0.1,
tip_length: float | VectorLike[float] = 0.2,
symmetric: bool = False,
symmetric_bounds: bool = False,
)[source]#

Create axes geometry source.

Source for generating fully 3-dimensional axes shaft and tip geometry.

By default, the shafts are cylinders and the tips are cones, though other geometries such as spheres and cubes are also supported. The use of an arbitrary dataset for the shafts and/or tips is also supported.

Unlike pyvista.AxesActor, the output from this source is a pyvista.MultiBlock, not an actor, and does not support colors or labels. The generated axes are “true-to-scale” by default, i.e. a shaft with a radius of 0.1 will truly have a radius of 0.1, and the axes may be oriented arbitrarily in space (this is not the case for pyvista.AxesActor).

Parameters:
shaft_typestr | pyvista.DataSet, default: ‘cylinder’

Shaft type for all axes. Can be any of the following:

  • 'cylinder'

  • 'sphere'

  • 'hemisphere'

  • 'cone'

  • 'pyramid'

  • 'cube'

  • 'octahedron'

Alternatively, any arbitrary 3-dimensional pyvista.DataSet may be specified. In this case, the dataset must be oriented such that it “points” in the positive z direction.

shaft_radiusfloat, default: 0.025

Radius of the axes shafts.

shaft_lengthfloat | VectorLike[float], default: 0.8

Length of the shaft for each axis.

tip_typestr | pyvista.DataSet, default: ‘cone’

Tip type for all axes. Can be any of the following:

  • 'cylinder'

  • 'sphere'

  • 'hemisphere'

  • 'cone'

  • 'pyramid'

  • 'cube'

  • 'octahedron'

Alternatively, any arbitrary 3-dimensional pyvista.DataSet may be specified. In this case, the dataset must be oriented such that it “points” in the positive z direction.

tip_radiusfloat, default: 0.1

Radius of the axes tips.

tip_lengthfloat | VectorLike[float], default: 0.2

Length of the tip for each axis.

symmetricbool, default: False

Mirror the axes such that they extend to negative values.

symmetric_boundsbool, default: False

Make the bounds of the axes symmetric. This option is similar to symmetric, except only the bounds are made to be symmetric, not the actual geometry. Has no effect if symmetric is True.

Methods

AxesGeometrySource.update()

Update the output of the source.

Attributes

AxesGeometrySource.output

Get the output of the source.

AxesGeometrySource.shaft_length

Length of the shaft for each axis.

AxesGeometrySource.shaft_radius

Radius of the axes shafts.

AxesGeometrySource.shaft_type

Shaft type for all axes.

AxesGeometrySource.symmetric

Mirror the axes such that they extend to negative values.

AxesGeometrySource.symmetric_bounds

Enable or disable symmetry in the axes bounds.

AxesGeometrySource.tip_length

Length of the tip for each axis.

AxesGeometrySource.tip_radius

Radius of the axes tips.

AxesGeometrySource.tip_type

Tip type for all axes.