toggle menu
korge-root
5.1.0
common
switch theme
search in API
korge-foundation
/
korlibs.math.interpolation
Package-level
declarations
Types
Functions
Properties
Types
Easing
Link copied to clipboard
fun
interface
Easing
Easing
Cubic
Link copied to clipboard
class
EasingCubic
(
val
x1
:
Float
,
val
y1
:
Float
,
val
x2
:
Float
,
val
y2
:
Float
,
val
name
:
String
?
=
null
)
:
Easing
Interpolable
Link copied to clipboard
interface
Interpolable
<
T
>
Mutable
Interpolable
Link copied to clipboard
interface
MutableInterpolable
<
T
>
Ratio
Link copied to clipboard
inline
class
Ratio
(
val
value
:
Double
)
:
Comparable
<
Ratio
>
Properties
nice
Str
Link copied to clipboard
val
Ratio
.
niceStr
:
String
Functions
abs
Link copied to clipboard
fun
abs
(
a
:
Ratio
)
:
Ratio
clamp
Link copied to clipboard
fun
Ratio
.
clamp
(
min
:
Ratio
,
max
:
Ratio
)
:
Ratio
convert
Range
Link copied to clipboard
fun
Ratio
.
convertRange
(
srcMin
:
Ratio
,
srcMax
:
Ratio
,
dstMin
:
Ratio
,
dstMax
:
Ratio
)
:
Ratio
div
Link copied to clipboard
inline operator
fun
Ratio
.
div
(
value
:
Double
)
:
Double
inline operator
fun
Ratio
.
div
(
value
:
Float
)
:
Float
inline operator
fun
Double
.
div
(
ratio
:
Ratio
)
:
Double
inline operator
fun
Float
.
div
(
ratio
:
Ratio
)
:
Float
inline operator
fun
Int
.
div
(
ratio
:
Ratio
)
:
Double
interpolate
Link copied to clipboard
fun
<
T
:
Interpolable
<
T
>
>
Ratio
.
interpolate
(
l
:
T
,
r
:
T
)
:
T
fun
Ratio
.
interpolate
(
l
:
Matrix
,
r
:
Matrix
)
:
Matrix
fun
Ratio
.
interpolate
(
l
:
MatrixTransform
,
r
:
MatrixTransform
)
:
MatrixTransform
fun
Ratio
.
interpolate
(
l
:
Rectangle
,
r
:
Rectangle
)
:
Rectangle
fun
Ratio
.
interpolate
(
l
:
Scale
,
r
:
Scale
)
:
Scale
fun
Ratio
.
interpolate
(
l
:
Size
,
r
:
Size
)
:
Size
fun
Ratio
.
interpolate
(
l
:
Vector2D
,
r
:
Vector2D
)
:
Vector2D
fun
Ratio
.
interpolate
(
l
:
Vector2F
,
r
:
Vector2F
)
:
Vector2F
fun
<
T
>
Ratio
.
interpolate
(
l
:
Interpolable
<
T
>
,
r
:
Interpolable
<
T
>
)
:
T
fun
Ratio
.
interpolate
(
l
:
Ratio
,
r
:
Ratio
)
:
Ratio
fun
Ratio
.
interpolate
(
l
:
Double
,
r
:
Double
)
:
Double
fun
Ratio
.
interpolate
(
l
:
Float
,
r
:
Float
)
:
Float
fun
Ratio
.
interpolate
(
l
:
Int
,
r
:
Int
)
:
Int
fun
Ratio
.
interpolate
(
l
:
Long
,
r
:
Long
)
:
Long
is
Almost
Equals
Link copied to clipboard
fun
Ratio
.
isAlmostEquals
(
that
:
Ratio
,
epsilon
:
Ratio
=
Ratio(0.000001)
)
:
Boolean
is
Almost
Zero
Link copied to clipboard
fun
Ratio
.
isAlmostZero
(
epsilon
:
Ratio
=
Ratio(0.000001)
)
:
Boolean
max
Link copied to clipboard
fun
max
(
a
:
Ratio
,
b
:
Ratio
)
:
Ratio
min
Link copied to clipboard
fun
min
(
a
:
Ratio
,
b
:
Ratio
)
:
Ratio
nice
Str
Link copied to clipboard
fun
Ratio
.
niceStr
(
decimalPlaces
:
Int
,
zeroSuffix
:
Boolean
=
false
)
:
String
times
Link copied to clipboard
inline operator
fun
Ratio
.
times
(
value
:
Ratio
)
:
Ratio
inline operator
fun
Ratio
.
times
(
value
:
Double
)
:
Double
inline operator
fun
Ratio
.
times
(
value
:
Float
)
:
Float
inline operator
fun
Double
.
times
(
ratio
:
Ratio
)
:
Double
inline operator
fun
Float
.
times
(
ratio
:
Ratio
)
:
Float
inline operator
fun
Int
.
times
(
ratio
:
Ratio
)
:
Double
to
Ratio
Link copied to clipboard
fun
Ratio
.
toRatio
(
)
:
Ratio
fun
Double
.
toRatio
(
)
:
Ratio
fun
Float
.
toRatio
(
)
:
Ratio
inline
fun
Number
.
toRatio
(
)
:
Ratio
fun
Double
.
toRatio
(
max
:
Double
)
:
Ratio
fun
Float
.
toRatio
(
max
:
Float
)
:
Ratio
inline
fun
Number
.
toRatio
(
max
:
Number
)
:
Ratio
to
Ratio
Clamped
Link copied to clipboard
fun
Double
.
toRatioClamped
(
)
:
Ratio
fun
Float
.
toRatioClamped
(
)
:
Ratio
inline
fun
Number
.
toRatioClamped
(
)
:
Ratio