vispy.visuals.cube module#

class vispy.visuals.cube.CubeVisual(size=1.0, vertex_colors=None, face_colors=None, color=(0.5, 0.5, 1, 1), edge_color=None, **kwargs)#

Bases: BoxVisual

Visual that displays a cube or cuboid

Parameters:
sizefloat or tuple

The size of the cuboid. A float gives a cube, whereas tuples may specify the size of each axis (x, y, z) independently.

vertex_colorsndarray

Same as for MeshVisual class. See create_cube for vertex ordering.

face_colorsndarray

Same as for MeshVisual class. See create_cube for vertex ordering.

colorColor

The Color to use when drawing the cube faces.

edge_colortuple or Color

The Color to use when drawing the cube edges. If None, then no cube edges are drawn.