I’m writing an exporter, and I want to transform an armature to Y-Up coordinates without actually saving it back to the blend file.
So, here’s my transformation matrix:
conversionMatrix = axis_conversion(from_forward='Y', from_up='Z', to_forward='Z', to_up='Y').to_4x4()
I get the armature, copy it, and transform it for exporting:
armature = ob.find_armature()
armature.data.transform(conversionMatrix)
# Export...
However, the actual armature in blender is transformed, 90 degrees, which would ruin the model if I were to save the file.
It seems like the armature isn’t actually copied. Is there something wrong with what I’m doing?
Blender 2.72b
StackExchange Question here: http://blender.stackexchange.com/questions/18621/copying-armature-through-python-api