mesh_transform_numpy

compas.datastructures.mesh_transform_numpy(mesh, transformation)[source]

Transform a mesh.

Parameters:
meshcompas.datastructures.Mesh

The mesh.

transformationcompas.geometry.Transformation

The transformation.

Returns:
None

The mesh is modified in-place.

Examples

>>> from compas.datastructures import Mesh
>>> from compas.geometry import matrix_from_axis_and_angle
>>> mesh = Mesh.from_polyhedron(6)
>>> T = matrix_from_axis_and_angle([0, 0, 1], math.pi / 4)
>>> tmesh = mesh.copy()
>>> mesh_transform_numpy(tmesh, T)