Perlin Noise wrap issue

Hi folks,

I’m a little confused about how Perlin noise can generate a random boundary.

For instance, when I apply it to a circle’s radius function, I will always get a discontinuity at 0 degrees…which is most noticeable at low noise values. (example image attached)

Does anybody have a suggestion about how you can achieve a smooth transition here?


What are you using to generate Perlin noise? You probably just need to get a higher order derivative to get better xy values. There’s some SDL-ready code on this here:…-lin-noise/ and also Inigo Quilez has a really good article on more advanced noise:…-enoise.htm but his examples need some reworking to be usable (but that doesn’t look super hard).

worked on the same thing =>
i ended up averaging the values by going through each point and looking at the neighbouring points on both sides to work out the average. althought this approach dampens the definition of the circular perlin noise, i was only after a visual effect which didn’t have to be very accurate so it worked out ok in my case.

just out of curiosity - can you try the same with simplex noise (available here: ).

did something similar a while ago but with vvvv:
… hand cutted with a scissor.

cheers andreas

back on the topic,

just had a look at my old code … now I got the problem.

did it the same like julapy :wink:

Here are a few solutions you could try:

  1. Use 2d noise instead of 1d. Give the noise function the x,y of your circle [e.g. r*cos(a), r*sin(a)] instead of the angle itself, to avoid the discontinuity. This might be the easiest solution if your noise function can do this.

  2. Use wrapped noise. When calculating the noise grid control point info, mod the index so it wraps every N points. This limits your noise frequency to integer numbers of grid points, but can work fine if you don’t need to smoothly vary the frequency.

  3. Fake wrapped noise using interpolation. Find some extra values of noise for the angle > 360 and do a weighted average of those with the original noise values to avoid the discontinuity. For example something like this might smooth over the initial 20 degrees: n = interp(noise(a+360), noise(a), a/20)

Hope that helps!