pyvista.Camera.model_transform_matrix#

property Camera.model_transform_matrix[source]#

Return or set the camera’s model transformation matrix.

Examples

>>> import pyvista
>>> import numpy as np
>>> pl = pyvista.Plotter()
>>> pl.camera.model_transform_matrix
array([[1., 0., 0., 0.],
       [0., 1., 0., 0.],
       [0., 0., 1., 0.],
       [0., 0., 0., 1.]])
>>> pl.camera.model_transform_matrix = np.array(
...     [
...         [1.0, 0.0, 0.0, 0.0],
...         [0.0, 1.0, 0.0, 0.0],
...         [0.0, 0.0, 1.0, 0.0],
...         [0.0, 0.0, 0.0, 0.5],
...     ]
... )
>>>
array([[1., 0., 0., 0.],
       [0., 1., 0., 0.],
       [0., 0., 1., 0.],
       [0., 0., 0., 0.5]])
https://d33wubrfki0l68.cloudfront.net/8d857d80b4aa52de3ad5db22f6e1210632178bb4/21a3c/_images/pyvista-camera-model_transform_matrix-1_00_00.png