1 class ArmatureExporter:
2 def export_armature(self, obj):
3 if obj.type!="ARMATURE":
4 raise ValueError("Object {} is not an armature".format(obj))
6 from .armature import Armature
7 armature = Armature(obj.data)
10 from .datafile import Statement
13 for l in armature.links:
14 st = Statement("link", l.name)
15 st.sub.append(Statement("index", l.index))
17 st.sub.append(Statement("parent", l.parent.name))
18 st.sub.append(Statement("base", *tuple(l.base)))