pyvista.Octahedron#
- Octahedron(radius: float = 1.0, center: VectorLike[float] = (0.0, 0.0, 0.0)) PolyData [source]#
Create an octahedron of a given size.
An octahedron is composed of eight congruent equilateral triangles.
- Parameters:
- Returns:
pyvista.PolyData
Mesh for the octahedron. Cell scalars are defined that assign integer labels to each face (with array name
"FaceIndex"
).
Examples
Create and plot an octahedron.
>>> import pyvista as pv >>> tetra = pv.Octahedron() >>> tetra.plot(categories=True)
See Platonic Solids for more examples using this filter.