public class RandomNoise extends java.lang.Object implements NoiseGenerator
Random
. Every time a noise
generating function is called, a new value will be returned.Constructor and Description |
---|
RandomNoise()
Create a new noise generator with a newly constructed
Random
instance. |
RandomNoise(java.util.Random random)
Create a new noise generator using the given
Random . |
Modifier and Type | Method and Description |
---|---|
float |
noise(Vector2 position)
Get the noise value for the given position.
|
float |
noise(Vector3 position)
Get the noise value for the given position.
|
public RandomNoise(java.util.Random random)
Random
.random
- the random instancepublic RandomNoise()
Random
instance.public float noise(Vector2 position)
NoiseGenerator
noise
in interface NoiseGenerator
position
- the positionpublic float noise(Vector3 position)
NoiseGenerator
noise
in interface NoiseGenerator
position
- the position