Convert a 16-element column-major array to a 4x4 matrix.
(arr: list[float])
| 89 | |
| 90 | |
| 91 | def matrix_from_array(arr: list[float]) -> np.ndarray: |
| 92 | """Convert a 16-element column-major array to a 4x4 matrix.""" |
| 93 | return np.array(arr, dtype=np.float32).reshape(4, 4, order='F') |
| 94 | |
| 95 | |
| 96 | def get_position(matrix: np.ndarray) -> np.ndarray: |
no test coverage detected