0
$\begingroup$

I try to transform the camera by changing its "matrix_world", however, as shown in the figure, when I assign a matrix to it, the rotation part is transposed and the translation part is changed to zero.

enter image description here

$\endgroup$
3
  • 1
    $\begingroup$ could you cut and paste as text the python statements you entered in the console? They don't appear in your blend file. $\endgroup$ Apr 2, 2022 at 16:54
  • 1
    $\begingroup$ FWIW, I think you need to use mathutils.Matrix in your assignment rather than np.array. When I do that I get the correct result. $\endgroup$ Apr 2, 2022 at 17:00
  • $\begingroup$ Thank you for your attention @MartyFouts. It is figured out that, we should not assign an np.array to matrix_word. By using mathutils.Matrix, it works fine. $\endgroup$
    – 翠花儿
    Apr 2, 2022 at 17:01

1 Answer 1

1
$\begingroup$

It is figured out that, we should not assign an np.array to "matrix_world". By using mathutils.Matrix, it works fine.

$\endgroup$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .