_BaseDataSetMapper#

class _BaseDataSetMapper(*args, **kwargs)[source]#

Base wrapper for vtkDataSetMapper.

Parameters:
datasetpyvista.DataSet, optional

Dataset to assign to this mapper.

themepyvista.plotting.themes.Theme, optional

Plot-specific theme.

Notes#

Auto scalar-range state machine. The private attribute _use_default_scalar_range tracks whether the scalar range is still derived from the mapped array (True) or has been pinned by the caller (False). It starts True. Setting scalar_range directly, or calling set_scalars() with an explicit clim, flips it to False via _set_scalar_range. While True, the range auto-refreshes from the mapped array in _maybe_set_default_scalar_range, which is called from set_active_scalars() and the dataset setter. Once False, auto-refresh is suppressed so user-supplied clim values are preserved.

Attributes#

_BaseDataSetMapper.array_name

Return or set the array name or number and component to color by.

_BaseDataSetMapper.cmap

Colormap assigned to this mapper.

_BaseDataSetMapper.dataset

Return or set the dataset assigned to this mapper.

_BaseDataSetMapper.resolve

Set or return the global flag to avoid z-buffer resolution.

_BaseDataSetMapper.scalar_range

Return or set the scalar range.

Inherited Attributes#

_BaseMapper.bounds

Return the bounds of this mapper.

_BoundsSizeMixin.bounds_size

Return the size of each axis of the object’s bounding box.

_BaseMapper.center

Return the center of mapper.

_BaseMapper.color_mode

Return or set the color mode.

_BaseMapper.interpolate_before_map

Return or set the interpolation of scalars before mapping.

_BaseMapper.lookup_table

Return or set the lookup table.

_BaseMapper.scalar_map_mode

Return or set the scalar map mode.

_BaseMapper.scalar_visibility

Return or set the scalar visibility.

_BaseMapper.static

Return or set whether the mapper treats its input as static.

Methods#

_BaseDataSetMapper.as_rgba()

Convert the active scalars to RGBA.

_BaseDataSetMapper.clear_active_scalars()

Detach the active scalars algorithm, if any.

_BaseDataSetMapper.copy()

Create a copy of this mapper.

_BaseDataSetMapper.set_active_scalars(name)

Set the active scalars for this mapper without mutating its dataset.

_BaseDataSetMapper.set_custom_opacity(...[, ...])

Set custom opacity.

_BaseDataSetMapper.set_scalars(scalars, ...)

Set the scalars on this mapper.

Inherited Methods#

_BaseMapper.update

Update this mapper.