Beispiel #1
0
 public virtual void ConnectToAnimationComponent(AnimationComponent animationComponent)
 {
     foreach (SceneNode child in mChildren)
     {
         child.ConnectToAnimationComponent(animationComponent);
     }
 }
Beispiel #2
0
 public virtual void ConnectToAnimationComponent(AnimationComponent animationComponent)
 {
     foreach (SceneNode child in mChildren)
     {
         child.ConnectToAnimationComponent(animationComponent);
     }
 }
Beispiel #3
0
 public override void ConnectToAnimationComponent(AnimationComponent animationComponent)
 {
     foreach (KeyValuePair<TraversalContext.MaterialFlags, EffectApplication> kvp in mMaterials)
     {
         if (kvp.Value.ParamSetters.ContainsKey(ParamSetter.Category.Skin))
             ((SkinParamSetter)(kvp.Value.ParamSetters[ParamSetter.Category.Skin])).AnimationComponent = animationComponent;
     }
 }
Beispiel #4
0
        protected virtual void ComponentsCreatedHandler(object sender, EventArgs e)
        {
            AnimationComponent animationComponent = Owner.GetComponent <AnimationComponent>(ComponentType.Animation);

            if (animationComponent != null)
            {
                SceneGraph.ConnectToAnimationComponent(animationComponent);
            }
        }
Beispiel #5
0
 public override void ConnectToAnimationComponent(AnimationComponent animationComponent)
 {
     foreach (KeyValuePair <TraversalContext.MaterialFlags, EffectApplication> kvp in mMaterials)
     {
         if (kvp.Value.ParamSetters.ContainsKey(ParamSetter.Category.Skin))
         {
             ((SkinParamSetter)(kvp.Value.ParamSetters[ParamSetter.Category.Skin])).AnimationComponent = animationComponent;
         }
     }
 }
Beispiel #6
0
 public override void Set(Effect effect, RenderContext context, Matrix transform)
 {
     if (AnimationComponent != null)
     {
         EffectRegistry.Params[effect][EffectRegistry.POSEDBONES_PARAM_NAME].SetValue(AnimationComponent.GetCurrentPose());
         EffectRegistry.Params[effect][EffectRegistry.WEIGHTS_PER_VERT_PARAM_NAME].SetValue(AnimationComponent.Animations.WeightsPerVert);
     }
     else
     {
         EffectRegistry.Params[effect][EffectRegistry.POSEDBONES_PARAM_NAME].SetValue(AnimationComponent.BindPose);
         EffectRegistry.Params[effect][EffectRegistry.WEIGHTS_PER_VERT_PARAM_NAME].SetValue(4);
     }
 }
Beispiel #7
0
 public SkinParamSetter()
 {
     AnimationComponent = null;
 }