WIP - Not for you yet:)
Last update: 10.11.2017
- side - If none, Centre is assumed
- headIK - CHANGE TO headAim
- headRotate - offset for
- headType - Not fully implemented
- neckBuild - Whether we want a neck or not
- neckControls - Number of neck joints you want.
- neckIK - Build ik for blend chain
- neckJoints - Number of neck joints, if this matches neck controls, no segment control is necessary
_blockModule- Creation/editing module for the rigBlock
_callKws- Kws from call
RigBlocks.factoryinstance with rigBlock
moduleTarget- Link to cgmModule
asHandleFactory- Returns handleFactory instance
blockType- change blockType for verify
size- set size on call
doName- Overload on cgmNode call
atBlockModule- String calling functions from block module
atBlockUtils- String calling functions from block utilites
contextual_methodCall- Function to contextually call a series of rigBlocks and run a methodCall on them with
string_methodCall- Function to call a self function by string. For menus and other reasons
Rig Build Steps¶
from cgm.core import cgm_Meta as cgmMeta import cgm.core.mrs.RigBlocks as RBLOCKS RBLOCKS.get_modules_dat()#...also reloads _block = 'head_block' b1 = cgmMeta.asMeta(_block) b1.atBlockModule('build_skeleton') mRigFac = RBLOCKS.rigFactory(b1) mRigFac.log_self()#>>uses pprint mRigFac.atBlockModule('rig_skeleton') mRigFac.atBlockModule('rig_shapes') mRigFac.atBlockModule('rig_controls') mRigFac.atBlockModule('rig_neckSegment') mRigFac.atBlockModule('rig_frame') mRigFac.atBlockModule('rig_cleanUp')
Initial checks on a module to see if it is buildable and buffering data to several dicts. Once initialized, the easiest way to see the data is to use the
It goes through several checks, any failures of which will bail the process.
Checks the rigBlock the factory will be using to do the rest of the build.
- Verifies the rigBlock before we move forward to make sure all expected attributes exist
- Buffers some block data including the module for our rigBlock type which is used extensively in the building process
Makes sure our cgmModule and cgmPuppet nodes are intact.
- cgmModule - makes sure we have one and creates one if not
- cgmPuppet - ditto. Verfies groups for parenting work we'll need
- Skeleton - Checks for a module skeleton. If it doesn't exist, builds one
Some logic checks to see if we can move forward as long as...
- If our cgmModule has a moduleParent, it must be rigged to rig a child
- Check build version to see if it is out of date and needs a build
- If force new, delete existing (NOT DONE)
Store a bunch of data we use multiple times like module colors, direction, mirror base data, global scale stuff and more.
Verify our cgmModule RigNull is ready to roll
- Some more buffering
- Wire our gutsVis
- Verify our module objectSet
Create our deformNull for our cgmModule underwhich the bulk of our rig stuff that isn't noTransform will be put.
- Rig joints built based on module joints
- Depending on options
- fk/ik/blend joints
- handle joints
- ik driver joints
Necessary control shapes from rigBlock
- FK/IK handles
Control registration. After this stage, the rig process is just hooking all our building blocks up.
- Add attribute drivers like - FKIK
- vis drivers - sub, direct, root. Connect to control shapes and not transforms to keep children visibile
- Controls registered - dynamic parent groups initialized, space pivots added, mirror settings
- Mirror registration - mirror settings and indexing
- MetaData - controls registered back to module
- Module objectSet extended with all controls
Build the ik/fk framework
- Ik/FK setups
- aim setups
Specialized spline ik and other setups
Clean up of base rig
- Parent and constraining joints and rig parts
- Lock and hide
- DynParentGroups - Register parents for various controls and
- Attribute defaults
- Build - BlockModule
- isSkeletonized - cgmModule
In general Skeleton ------------- * moduleJoints - * skinJoints - * fkJoints - main handle chain. Other chains are duplicated from this
- Frame - frame structure for blending like fk/ik
- Handle - Handle for segment manipulation
- Fix single rigBlock masterControl sizing
- Add rigPrecheck report
- Joint estimate
- Is undo corrupting red9 buffer?
- HeadIK - change to headAim attribute
if joints == handles: no direct
- ``if handles == joints: ``
if joints > handles: build segment handles
- Generate mesh, parent to rigJoints
DONE- Proxymesh creation complete. Must have rigJoints to build
- No aim, no neck -
- Aim, no neck -
- Single handle/Single Joint
- Single handle/Multiple joints
- Multi Handle/Multiple Joints
- No aim, no neck -
FIXEDBug - master anim control sizing got broken somewhere.
- The skeleton_getCreateDict all in one with orientation isn't gonna work as all in one. Just getting positions makes the most sense.
- New skeleton builder -
cgm.core.rig.joint_utils.build_chain. Moved from a couple of places to get it more usable. Need to link up to ui