Record Class Humanizer.Config
java.lang.Object
java.lang.Record
org.jjazz.humanizer.api.Humanizer.Config
- Record Components:
timingRandomness- [0;1.0] Amount of randomness to notes start time, and possibly their durationtimingBias- [-0.5;0.5] Shift to notes start timevelocityRandomness- [0-1.0] Amount of randomness to notes velocity
- Enclosing class:
Humanizer
public static record Humanizer.Config(float timingRandomness, float timingBias, float velocityRandomness)
extends Record
A humanization user configuration.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.static Humanizer.ConfigloadFromString(String str) setTimingBias(float newValue) setTimingRandomness(float newValue) setVelocityRandomness(float newValue) floatReturns the value of thetimingBiasrecord component.floatReturns the value of thetimingRandomnessrecord component.final StringtoString()Returns a string representation of this record class.floatReturns the value of thevelocityRandomnessrecord component.
-
Constructor Details
-
Config
public Config() -
Config
public Config(float timingRandomness, float timingBias, float velocityRandomness) Creates an instance of aConfigrecord class.- Parameters:
timingRandomness- the value for thetimingRandomnessrecord componenttimingBias- the value for thetimingBiasrecord componentvelocityRandomness- the value for thevelocityRandomnessrecord component
-
-
Method Details
-
setTimingRandomness
-
setTimingBias
-
setVelocityRandomness
-
toSaveString
-
loadFromString
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with thecomparemethod from their corresponding wrapper classes. -
timingRandomness
public float timingRandomness()Returns the value of thetimingRandomnessrecord component.- Returns:
- the value of the
timingRandomnessrecord component
-
timingBias
public float timingBias()Returns the value of thetimingBiasrecord component.- Returns:
- the value of the
timingBiasrecord component
-
velocityRandomness
public float velocityRandomness()Returns the value of thevelocityRandomnessrecord component.- Returns:
- the value of the
velocityRandomnessrecord component
-