Record Class GivensParameters
java.lang.Object
java.lang.Record
com.mojang.math.GivensParameters
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionGivensParameters(float sinHalf, float cosHalf) Creates an instance of aGivensParametersrecord class. -
Method Summary
Modifier and TypeMethodDescriptionaroundX(Quaternionf input) aroundY(Quaternionf input) aroundZ(Quaternionf input) floatcos()floatcosHalf()Returns the value of thecosHalfrecord component.final booleanIndicates whether some other object is "equal to" this one.static GivensParametersfromPositiveAngle(float angle) static GivensParametersfromUnnormalized(float sinHalf, float cosHalf) final inthashCode()Returns a hash code value for this object.inverse()floatsin()floatsinHalf()Returns the value of thesinHalfrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
sinHalf
private final float sinHalfThe field for thesinHalfrecord component. -
cosHalf
private final float cosHalfThe field for thecosHalfrecord component.
-
-
Constructor Details
-
GivensParameters
public GivensParameters(float sinHalf, float cosHalf) Creates an instance of aGivensParametersrecord class.- Parameters:
sinHalf- the value for thesinHalfrecord componentcosHalf- the value for thecosHalfrecord component
-
-
Method Details
-
fromUnnormalized
-
fromPositiveAngle
-
inverse
-
aroundX
-
aroundY
-
aroundZ
-
cos
public float cos() -
sin
public float sin() -
aroundX
-
aroundY
-
aroundZ
-
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. -
sinHalf
public float sinHalf()Returns the value of thesinHalfrecord component.- Returns:
- the value of the
sinHalfrecord component
-
cosHalf
public float cosHalf()Returns the value of thecosHalfrecord component.- Returns:
- the value of the
cosHalfrecord component
-