Exemple #1
0
 public override void DestroyInputPort(int inputPortIndex)
 {
     DestroyInputPortWithCallback(inputPortIndex, p =>
     {
         LayerMixerNodeInputPort port = (LayerMixerNodeInputPort)p;
         SetBlendMode(port.Index, port.BlendMode);
         SetAvatarMask(port, port.AvatarMask);
     });
 }
Exemple #2
0
        public void SetAvatarMask(LayerMixerNodeInputPort inputPort, AvatarMask mask)
        {
            if (inputPort.AvatarMask == null && mask == null)
            {
                return;
            }

            inputPort.AvatarMask = mask;
            ((AnimationLayerMixerPlayable)Playable).SetLayerMaskFromAvatarMask((uint)inputPort.Index, mask);
        }
Exemple #3
0
        public LayerMixerNodeInputPort CreateInputPort(LayerBlendMode blendMode, float weight = 1f, AvatarMask avatarMask = null)
        {
            LayerMixerNodeInputPort port = new LayerMixerNodeInputPort {
                Node = this, Weight = weight, BlendMode = blendMode, AvatarMask = avatarMask
            };

            SetupInputPort(port, weight);

            SetBlendMode(port, blendMode);
            SetAvatarMask(port, avatarMask);

            return(port);
        }
Exemple #4
0
 public void SetBlendMode(LayerMixerNodeInputPort inputPort, LayerBlendMode blendMode)
 {
     inputPort.BlendMode = blendMode;
     SetBlendMode(inputPort.Index, blendMode);
 }