void _DrawBoneGizmo( Bone bone, ref Vector3 cameraForward )
{
if( bone == null || bone.transform == null ) {
return;
}
if( bone.boneType == BoneType.Eye ) {
if( _IsHiddenCustomEyes() ) {
return;
}
}
Transform parentTransform = bone.parentTransform;
Vector3 position = bone.transform.position;
Quaternion rotation = bone.transform.rotation * bone._worldToBoneRotation;
Matrix3x3 basis;
SAFBIKMatSetRot( out basis, ref rotation );
_DrawTransformGizmo( position, ref basis, ref cameraForward, bone.boneType );
if( parentTransform != null ) {
Gizmos.color = Color.white;
rotation = parentTransform.rotation * bone.parentBone._worldToBoneRotation;
SAFBIKMatSetRot( out basis, ref rotation );
_DrawBoneGizmo( parentTransform.position, position, ref basis, ref cameraForward, bone.boneType );
}
}