Hi
ich versuche gerade mit einem script bones in blender zu importieren, scheitere allerdings kläglich an der Rotation.
Das bone soll aus einem Vector und einem Quaternion erstellt werden.
Kennt sich jemand damit aus wie ich die richtig hinbekomme?
Die Bones werden alle erstellt sind allerdings wie gesagt falsch rotiert.
bone.parent = parent
bone.head = parent.tail
bone.use_connect = True
bone.use_inherit_rotation = False
(trans, parent_rot, scale) = parent.matrix.decompose()
pivot_rot = Quaternion((pivot.rotation.val1,pivot.rotation.val2, pivot.rotation.val3, pivot.rotation.val4))
vec = Vector((pivot.pos[0], pivot.pos[1], pivot.pos[2]))
bone.tail = (pivot_rot*parent_rot)*vec + bone.head
Gruß Tarcontar