Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender-addons.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLucio Rossi <lucio.rossi75@gmail.com>2017-07-24 19:14:16 +0300
committerLucio Rossi <lucio.rossi75@gmail.com>2017-07-24 19:14:30 +0300
commit33b0e2e9025965133656dd85506bbef62ca3183d (patch)
tree52f2368a79623272cadf64a9c1ca3ac209176231 /rigify/rigs/utils.py
parent49230a4c122013bf851ab37b029e7d4f624d68ad (diff)
Rigify 0.5: new features, Animation Tools and Quat/Euler converter
small fixes & UI improvements
Diffstat (limited to 'rigify/rigs/utils.py')
-rw-r--r--rigify/rigs/utils.py21
1 files changed, 21 insertions, 0 deletions
diff --git a/rigify/rigs/utils.py b/rigify/rigs/utils.py
new file mode 100644
index 00000000..c08cb8f9
--- /dev/null
+++ b/rigify/rigs/utils.py
@@ -0,0 +1,21 @@
+from .limbs.super_limb import Rig as LimbRig
+from ..utils import connected_children_names
+import re
+
+
+def get_limb_generated_names(rig):
+
+ pbones = rig.pose.bones
+ names = dict()
+
+ for b in pbones:
+ super_limb_orgs = []
+ if re.match('^ORG', b.name) and b.rigify_type == 'limbs.super_limb':
+ super_limb_orgs.append(b)
+ children = connected_children_names(rig, b.name)
+ for child in children:
+ if re.match('^ORG', child) or re.match('^MCH', child):
+ super_limb_orgs.append(pbones[child])
+ names[b.name] = LimbRig.get_future_names(super_limb_orgs)
+
+ return names