Skip to content

Commit 5e83027

Browse files
authored
Merge pull request #6 from anasrar/development
add keyframe group (using bone name) on bake operator for better workflow with graph editor
2 parents 868e263 + 4f82a21 commit 5e83027

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

ReNimNode/production/editorType_operator.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -429,16 +429,16 @@ def execute(self, context):
429429
for pose_bone , is_bake_location, is_bake_rotation, is_bake_scale, ori_location, ori_rotation, ori_scale in bake_bones:
430430
# bake location
431431
if is_bake_location:
432-
pose_bone.keyframe_insert("location", options={"INSERTKEY_VISUAL"})
432+
pose_bone.keyframe_insert("location", options={"INSERTKEY_VISUAL"}, group=pose_bone.name + " (loc)")
433433

434434
# bake rotation
435435
if is_bake_rotation:
436-
pose_bone.keyframe_insert("rotation_quaternion", options={"INSERTKEY_VISUAL"})
437-
pose_bone.keyframe_insert("rotation_euler", options={"INSERTKEY_VISUAL"})
436+
pose_bone.keyframe_insert("rotation_quaternion", options={"INSERTKEY_VISUAL"}, group=pose_bone.name + " (rot quat)")
437+
pose_bone.keyframe_insert("rotation_euler", options={"INSERTKEY_VISUAL"}, group=pose_bone.name + " (rot euler)")
438438

439439
# bake scale
440440
if is_bake_scale:
441-
pose_bone.keyframe_insert("scale", options={"INSERTKEY_VISUAL"})
441+
pose_bone.keyframe_insert("scale", options={"INSERTKEY_VISUAL"}, group=pose_bone.name + " (scale)")
442442

443443
frame += self.frame_step
444444

0 commit comments

Comments
 (0)