[orx-noise] Add tools for functional composition

This commit is contained in:
Edwin Jakobs
2021-07-25 22:36:07 +02:00
parent c388cbe7e2
commit 454affbdfd
15 changed files with 532 additions and 74 deletions

View File

@@ -29,4 +29,8 @@ inline fun value(seed: Int, x: Double, y: Double, crossinline interpolation: (Do
val xf1 = mix(valCoord2D(seed, x0, y1), valCoord2D(seed, x1, y1), xs)
return mix(xf0, xf1, ys)
}
}
val valueLinear2D: (Int, Double, Double) -> Double = ::valueLinear
val valueQuintic2D: (Int, Double, Double) -> Double = ::valueQuintic
val valueHermite2D: (Int, Double, Double) -> Double = ::valueHermite