Perlin noise uses a matrix of random vectors and interpolates between those vectors to generate the noise values. The SIZE var tells it how large that matrix of vectors will be. You shouldn't need to worry about that too much but if you are making a 100x100 map you'd want the SIZE and scale to be set such that the noise values don't repeat.
The interpolation var determines what method is used to interpolate between vectors when generating noise values. It can be set to LINEAR or COSINE.
The scale var is a multiplier applied to all coordinates. If you're making a 32x32 icon and the size of the matrix you're using is 5x5x5. If you use each pixel's coordinates to get noise values the function will repeat (noise(1, 1, 1) is the same as noise(6, 1, 1) because the size is 5). You can set the scale to 0.1 so that calling noise(32, 32, 1) will actually sample the noise function at the coordinates 3.2, 3.2, 0.1.
The levels var determines how many times the noise function is sampled.
This web page has some good pictures to show how it works and what these variables are used for: http://freespace.virgin.net/hugo.elias/models/m_perlin.htm
1
2
<> Jul 27 2012, 6:19 am


<> Jul 27 2012, 1:05 pm
In response to Forum_account


Thanks for the rundown and the link. Perlin noise seems like it can be very useful in creating games.

1
2
The ones I am curious about are: