Enum Class MotorParam

java.lang.Object
java.lang.Enum<MotorParam>
com.jme3.bullet.joints.motors.MotorParam
All Implemented Interfaces:
Serializable, Comparable<MotorParam>, Constable

public enum MotorParam extends Enum<MotorParam>
Enumerate certain parameters of a RotationMotor or TranslationMotor, based on Bullet's btConstraintParams.
See Also:
  • Nested Class Summary

    Nested classes/interfaces inherited from class java.lang.Enum

    Enum.EnumDesc<E extends Enum<E>>
  • Enum Constant Summary

    Enum Constants
    Enum Constant
    Description
    restitution/bounce factor at the limits (m_bounce, default=0)
    spring's viscous damping ratio (m_springDamping, default=0)
    spring's equilibrium point (m_equilibriumPoint, default=0)
    constraint lower limit (m_loLimit/m_lowerLimit, default=1[rot] or 0[translate])
    maximum motor force (m_maxMotorForce, default=6[rot] or 0[translate])
    constraint-force mixing parameter between limits (m_motorCFM, native name: BT_CONSTRAINT_CFM, default=0)
    error-reduction parameter between limits (m_motorERP, native name: BT_CONSTRAINT_ERP, default=0.9)
    servo's target (m_servoTarget, default=0)
    spring's stiffness (m_springStiffness, default=0)
    constraint-force mixing parameter at limits (m_stopCFM, native name: BT_CONSTRAINT_STOP_CFM, default=0)
    error-reduction parameter at limits (m_stopERP, native name: BT_CONSTRAINT_STOP_ERP, default=0.2)
    motor's target velocity (m_targetVelocity, default=0)
    constraint upper limit (m_hiLimit/m_upperLimit, default=-1[rot] or 0[translate])
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    canSet(float value)
    Test whether this parameter can be set to the specified value.
    float
    Determine the default value for this parameter in a RotationMotor.
    float
    Determine the default value for this parameter in a TranslationMotor.
    float
    Determine the maximum value for this parameter.
    float
    Determine the minimum value for this parameter.
    int
    Determine the parameter's index in native code.
    Determine the serialization-tag suffix for this parameter.
    static MotorParam
    Returns the enum constant of this class with the specified name.
    static MotorParam[]
    Returns an array containing the constants of this enum class, in the order they are declared.

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Enum Constant Details

    • Bounce

      public static final MotorParam Bounce
      restitution/bounce factor at the limits (m_bounce, default=0)
    • Damping

      public static final MotorParam Damping
      spring's viscous damping ratio (m_springDamping, default=0)
    • Equilibrium

      public static final MotorParam Equilibrium
      spring's equilibrium point (m_equilibriumPoint, default=0)
    • LowerLimit

      public static final MotorParam LowerLimit
      constraint lower limit (m_loLimit/m_lowerLimit, default=1[rot] or 0[translate])
    • MaxMotorForce

      public static final MotorParam MaxMotorForce
      maximum motor force (m_maxMotorForce, default=6[rot] or 0[translate])
    • MotorCfm

      public static final MotorParam MotorCfm
      constraint-force mixing parameter between limits (m_motorCFM, native name: BT_CONSTRAINT_CFM, default=0)
    • MotorErp

      public static final MotorParam MotorErp
      error-reduction parameter between limits (m_motorERP, native name: BT_CONSTRAINT_ERP, default=0.9)
    • ServoTarget

      public static final MotorParam ServoTarget
      servo's target (m_servoTarget, default=0)
    • Stiffness

      public static final MotorParam Stiffness
      spring's stiffness (m_springStiffness, default=0)
    • StopCfm

      public static final MotorParam StopCfm
      constraint-force mixing parameter at limits (m_stopCFM, native name: BT_CONSTRAINT_STOP_CFM, default=0)
    • StopErp

      public static final MotorParam StopErp
      error-reduction parameter at limits (m_stopERP, native name: BT_CONSTRAINT_STOP_ERP, default=0.2)
    • TargetVelocity

      public static final MotorParam TargetVelocity
      motor's target velocity (m_targetVelocity, default=0)
    • UpperLimit

      public static final MotorParam UpperLimit
      constraint upper limit (m_hiLimit/m_upperLimit, default=-1[rot] or 0[translate])
  • Method Details

    • values

      public static MotorParam[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static MotorParam valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • canSet

      public boolean canSet(float value)
      Test whether this parameter can be set to the specified value.
      Parameters:
      value - the desired parameter value
      Returns:
      true if settable, otherwise false
    • defaultForRotationMotor

      public float defaultForRotationMotor()
      Determine the default value for this parameter in a RotationMotor.
      Returns:
      the default parameter value
    • defaultForTranslationMotor

      public float defaultForTranslationMotor()
      Determine the default value for this parameter in a TranslationMotor.
      Returns:
      the default parameter value
    • maxValue

      public float maxValue()
      Determine the maximum value for this parameter.
      Returns:
      a maximum value, or Float.MAX_VALUE if there's no maximum
    • minValue

      public float minValue()
      Determine the minimum value for this parameter.
      Returns:
      a minimum value, or -Float.MAX_VALUE if there's no minimum
    • nativeIndex

      public int nativeIndex()
      Determine the parameter's index in native code.
      Returns:
      the index
    • tagSuffix

      public String tagSuffix()
      Determine the serialization-tag suffix for this parameter.
      Returns:
      the tag suffix