someday - ERC Tricks - ( post includes code for nerds )
i must return to the midi animation project
so this wont be available right now
but
sometimes i animate Amy's head using mcjKeepOrient
this keeps her had still while the rest of the body moves, a walk or a dance
this means there's 1 keyframe per animation frame imposed on the head node
but during the walk i'd like her attention to turn to the camera or the road or things
so how do i mix the two ?
by adding a second head joint
using an ERC Link and a gizmo
the gizmo's rotations are added to the head rotations
in the gif below, the gizmo animation is a slow Bend/Unbend
and Amy's initial head animation is a fast head bobbing
if you know daz script programming, here's the script i used
you can also see i did a quick rigging of the Mitsu hair
---
another advantage of this system is that i could reserve the head node for morph/lipsync keyframes
and have all the head rotation keyframes on the gizmo
it would be easier on the DS Timeline to keep track of what's going on
----
note the precise sinewave animation curves were created using mcjCycleFilter
https://www.youtube.com/watch?v=4rcAHyf0lxs
----
// DAZ Studio version 3.0 filetype DAZ Script
//uninstall()
install1()
//install2()
function install1()
{
var masterNode = Scene.findNodeByLabel( "mcjGizmo3" );
var slaveNode = Scene.findNodeByLabel( "Amy" ).findBone("head");
var slaveProp = slaveNode.getXRotControl();
var masterProp = masterNode.getXRotControl();
var oERCLink = new DzERCLink( masterProp );
slaveProp.insertController( oERCLink );
}
function install2()
{
var masterNode = Scene.findNodeByLabel( "Amy" ).findBone("head");
var masterProp = masterNode.getXRotControl();
var slaveNode = Scene.findNodeByLabel( "AmyHair" );
var slaveProp = slaveNode.getObject().findModifier( "NeckFwd2" ).getValueChannel();
debug( slaveProp.getLabel() )
var oERCLink = new DzERCLink( masterProp );
slaveProp.insertController( oERCLink );
}
function uninstall()
{
var slaveNode = Scene.findNodeByLabel( "Amy" ).findBone("head");
var slaveProp = slaveNode.getXRotControl();
var ctls = slaveProp.getControllerList();
if( ctls.length > 0 )
{
if( ctls[0].getCurrentProperty().getOwner().name == "mcjGizmo3" );
{
slaveProp.removeController( ctls[0] )
}
}
}