User Tools

Site Tools


democap:blender_democaptools

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
democap:blender_democaptools [2022/04/18 21:04] dragonlorddemocap:blender_democaptools [2022/07/11 20:06] (current) – [Import Object Rig] dragonlord
Line 14: Line 14:
 The addon scripts can be installed using the typical Blender3D workflow for [[https://docs.blender.org/manual/en/latest/editors/preferences/addons.html|installing addons]].  The addon scripts can be installed using the typical Blender3D workflow for [[https://docs.blender.org/manual/en/latest/editors/preferences/addons.html|installing addons]]. 
  
-You can download the zip file from: [[https://github.com/LordOfDragons/democap/releases/latest]], file **democap-tools-*.zip** where * is the version number.+You can download the zip file from: [[https://github.com/LordOfDragons/democap/releases/latest]], file <wrap em>blender-democap-tools-*.zip</wrap> where * is the version number.
  
 Click the "Install" button and select the plugin zip file. Click the "Install" button and select the plugin zip file.
Line 21: Line 21:
  
 Now a new toolbox panel is added with the title "DEMoCap Tools". Now a new toolbox panel is added with the title "DEMoCap Tools".
 +
  
 ====== DEMCA Browser ====== ====== DEMCA Browser ======
Line 68: Line 69:
 This button can be used if the motion capture contains VR device capture information. Select the Armature imported by "Import Devices Rig" button. Depending on the playtime of the motion capture the importing can take a longer time to finish. Once the button is no more highlighted the import finished. This button can be used if the motion capture contains VR device capture information. Select the Armature imported by "Import Devices Rig" button. Depending on the playtime of the motion capture the importing can take a longer time to finish. Once the button is no more highlighted the import finished.
  
 +===== Import Object Rig =====
 +
 +This button can be used if the motion capture contains object position and orientation information. Press this button to import the rig used by the motion capture to store the object parameters. The rig contains these bones:
 +  * <wrap em>object</wrap>: Represents the position and orientation of the object relative to the game world. You typically use a "Child of" constraint to attach the motion captured objects. Since Blender3D uses negative Y axis as forward direction for bones you have to set the Z Rotation of the attached object to 180 degrees to get the correct result.
 +  * <wrap em>attach</wrap>: Determines if the object is attached/grabbed at specific points in time. Only the local Y position is used. A local Y position of 0 represents not attached and 0.1 represents attached. As of DEMoCap 0.7 this value is not used yet.
 +This import is quick and produces an Armature.
 +
 +If multiple captures use object position and orientation you can use the same rig layout but you have to duplicate the object since each attached object needs a unique parent.
 +
 +===== Import Object Animation =====
 +
 +This button can be used if the motion capture contains object position and orientation information. Select the Armature imported by "Import Object Rig" button. Depending on the playtime of the motion capture the importing can take a longer time to finish. Once the button is no more highlighted the import finished.
 <WRAP clear/> <WRAP clear/>
  
 +====== Correction Bones ======
 +<WRAP box right :en >{{ :democap:blender_democaptools3.png?direct|}}</WRAP>
 +
 +The <wrap em>Correction Bones</wrap> tools allows to post process motion capture data in a non-destructive way. Correcting bones has various uses, for example (including others):
 +  * Correct actor poses to remove unwanted arching and rotating
 +  * Fit motion capture pose to existing animations they are overlaying to get better looking blending
 +  * Exaggerate or tone down motions
 +  * Create variations of motions
 +
 +===== Add Correction Bones =====
 +
 +To use correction bones you have to first add them to your armature. Enter <wrap em>Pose Mode</wrap> and select the bones to add correction support to then press the <wrap em>Add Rot</wrap> or <wrap em>Add Rot+Loc</wrap> button.
 +
 +Correction bones are added directly to your armature to allow saving them into the actions as well as allowing them to be animated for fine control. The added bones are named <wrap em>"ik.mocap.{name}"</wrap> where <wrap em>"{name}"</wrap> is the name of the bone the correction applies to. To help organize bones the added correction bones are added to a bone group named <wrap em>"DEMoCap Correction"</wrap>. The bone group is assigned the next unused color theme. The correction bones are assigned the same parent and transformation but are shortened in length to 65% of the original bone.
 +
 +For each corrected bone a bone constraint is added using the respective correction bone as input.
 +
 +If the <wrap em>Add Rot</wrap> button has been used a <wrap em>Copy Rotation</wrap> bone constraint is added. The bone constraint is set to superimpose the local rotation of the correction bone onto the original bone in local bone space. This means you can rotate the correction bones to rotationally offset the motion captured animation. Use this for all bones which require only rotation to be modified. This is the majority of bones.
 +
 +If the <wrap em>Add Rot+Loc</wrap> button has been used a <wrap em>Copy Transforms</wrap> bone constraint is added. The bone constraint is set to superimpose the local rotation and translation of the correction bone onto the original bone in local bone space. This means you can rotate and mvoe the correction bones to rotationally and translationally offset the motion captured animation. Use this for all bones which require rotation and translation to be modified. This is typically used for location bones like the hip or origin bone where the location of the bone is important.
 +
 +The image below shows the process of adding bones to the Dragonroo example character.
 +{{ :democap:blender_democaptools4.png?direct&600 |}}
 +
 +The image below shows how rotating spine correction bones offsets the animation without destroying it.
 +{{ :democap:blender_democaptools5.png?direct&400 |}}
 +
 +===== Align Correction Bones =====
 +
 +If the motion captured animation is used by blending over an existing animation (for example an idle animation) then it is useful to align the animation to match as closely as possible the base animation at the beginning and end. This allows to blend into the motion captured animation with the highest quality.
 +
 +To align correction bones activate the action and frame number to use as animation frame to match against. Select the correction bones to copy the original bone world space transforms for. It is also possible to select the respective original bones instead but selecting the correction bones is a faster workflow. With the bones selected click the <wrap em>Copy Bone Matrices</wrap> button. The states are now stored in memory. Select now the motion capture action and go to the first frame to use. Select all correction bones you want to align. This is not required to be all the copied bones so you can apply the corrections in batches if you like. With the bones selected press the <wrap em>Align Correction Bones</wrap> button. The correction bones are not rotated and optionally moved (if they have been added using Add Rot+Loc). After aligning the original bones match the rotation (and optionally location) of the copied world bone states. You can now add keyframes for the bones to the action.
 +
 +The typical workflow to create overlay motion capture animations is to align the first and last frame to the base animation. Optionally add keyframes at 0.5-1s after the begin and before the end with the rotation and location cleared. This way the corrections ensure the animation fits well over the base animation when blended into while the clearing ensures the animation playes unmodified after being fully blended in.
 +
 +It is also possible to the aligning to match specific time positions inside the animation to an existing animation.
 +
 +The video below shows how this works. The imported animation is aligned to a base animation. Blending into the animation would produce good results like this. As an of altering the motion captured animation the spine is bend over causing the character to play the motion captured animation in a hunched over pose instead of the upright one as performed by the actor.
 +{{ youtube>tlp5mZsl66Y?800x473 }}
democap/blender_democaptools.1650315897.txt.gz · Last modified: 2022/04/18 21:04 by dragonlord