0
$\begingroup$

enter image description here

Notice how the object local transform axes are left handed after the mirror. Is this a problem? It's a little odd for me from a python scripting, I often transform objects with python matrices. Is it just that the word matrix represents a left handed set of axes?

So to test, I use the world matrix on each of these objects to inspect what Blender thinks is the positive local x axis. Strangely, I get 2 different answers depending on how I ask what the local x axis is!

import bpy
from mathutils import Vector

X = Vector((1,0,0))
for ob in bpy.data.objects:
    mx = ob.matrix_world
    mxrot = mx.to_3x3()
    quat = mx.to_quaternion()

    print(mxrot*X)
    print(quat*X)

result: Vector (1.0000, 0.0000, 0.0000)

Vector (1.0000, 0.0000, 0.0000)

Vector (-1.0000, 0.0000, 0.0000)

Vector (1.0000, 0.0000, 0.0000)

$\endgroup$
1
  • $\begingroup$ Would you like to accept your own answer. (Maybe extend it slightly, with what you expected instead of the -1 scale). $\endgroup$
    – Leander
    Commented Jul 8, 2018 at 15:09

1 Answer 1

1
$\begingroup$

Turns out the "problem" is that the scale was -1 after the mirror operator. After applying scale, the coordinate system was right handed again.

-P

$\endgroup$

You must log in to answer this question.

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