Convert orx-shader-phrases and orx-noise to MPP
This commit is contained in:
8
orx-noise/src/commonMain/kotlin/ValueNoise1D.kt
Normal file
8
orx-noise/src/commonMain/kotlin/ValueNoise1D.kt
Normal file
@@ -0,0 +1,8 @@
|
||||
package org.openrndr.extra.noise
|
||||
|
||||
fun valueLinear(seed: Int, x: Double) = value(seed, x, ::linear)
|
||||
fun valueQuintic(seed: Int, x: Double) = value(seed, x, ::quintic)
|
||||
fun valueHermite(seed: Int, x: Double) = value(seed, x, ::hermite)
|
||||
|
||||
inline fun value(seed: Int, x: Double, crossinline interpolation: (Double) -> Double = ::linear): Double =
|
||||
value(seed, x, 0.0, interpolation)
|
||||
Reference in New Issue
Block a user