Class BlendAction

All Implemented Interfaces:
Tween, JmeCloneable, Cloneable

public class BlendAction extends BlendableAction
  • Constructor Details

  • Method Details

    • doInterpolate

      public void doInterpolate(double t)
      Specified by:
      doInterpolate in class BlendableAction
    • getActions

      protected Action[] getActions()
    • getBlendSpace

      public BlendSpace getBlendSpace()
    • getSpeed

      public double getSpeed()
      getSpeed in class Action
    • getSpeedFactors

      public double[] getSpeedFactors()
      The speed factor or null if there is none
    • setSpeedFactors

      public void setSpeedFactors(double... speedFactors)
      Used to resolve the slow motion side effect caused by stretching actions that doesn't have the same length.
      speedFactors - The speed factors for each child action. BlendAction will interpolate factor for current frame based on blend weight and will multiply it to speed.
    • clearSpeedFactors

      public void clearSpeedFactors()
    • applyDefaultSpeedFactors

      public void applyDefaultSpeedFactors()
      BlendAction will stretch it's child actions if they don't have the same length. This might cause stretched animations to run slowly. This method generates factors based on how much actions are stretched. Multiplying this factor to base speed will resolve the slow-motion side effect caused by stretching. BlendAction will use the blend weight taken from BlendSpace to interpolate the speed factor for current frame.
    • setFirstActiveIndex

      protected void setFirstActiveIndex(int index)
    • setSecondActiveIndex

      protected void setSecondActiveIndex(int index)
    • getTargets

      public Collection<HasLocalTransform> getTargets()
      Specified by:
      getTargets in class BlendableAction
    • collectTransform

      public void collectTransform(HasLocalTransform target, Transform t, float weight, BlendableAction source)
      Specified by:
      collectTransform in class BlendableAction