MathUtils class

Constructors

MathUtils()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Properties

deg2rad num
getter/setter pair
rad2deg num
getter/setter pair

Static Methods

ceilPowerOfTwo<T extends num>(T value) num
clamp<T extends num>(T value, T min, T max) → T
damp(num x, num y, num lambda, num dt) num
degToRad(num degrees) num
denormalize(num value, dynamic array) → dynamic
euclideanModulo<T extends num>(T n, T m) num
floorPowerOfTwo<T extends num>(T value) num
generateUUID() String
inverseLerp<T extends num>(T x, T y, T value) num
isPowerOfTwo(int value) bool
lerp<T extends num>(T x, T y, T t) num
mapLinear<T extends num>(T x, T a1, T a2, T b1, T b2) num
normalize(dynamic value, dynamic array) → dynamic
pingPong<T extends num>(T x, {int length = 1}) num
radToDeg(num radians) num
randFloat(double low, double high) double
randFloatSpread(double range) double
randInt(int low, int high) int
seededRandom([int? s]) double
setQuaternionFromProperEuler(dynamic q, num a, num b, num c, String order) → void
smootherstep(num x, num min, num max) num
smoothstep(num x, num min, num max) num