I am doing a loop with bezier curves and I am trying to make small variations between them, as you can see on the picture. I have read that noise function is the best way to make these kind of variations but I have seen some different tutorials and I am not able to use it correctly. Could you please help me to understand what am I doing bad? Thanks!
float v = 0.0;
size (1000,1000);
noFill();
strokeWeight(3);
float n = noise(v);
for(int i=-100; i < 1200; i = i+10) {
bezier(0,i, 0,i+n, 0,i+100, 1000,i);
}
I’ll give you a hint. You need to find a way to change the value of v and hence n on each iteration of your drawing loop. You might rearrange your code to fit inside the loop and perhaps use random() to generate a value for v within lower and upper limits. Perhaps placing your float n = noise(v) statement in the same block with your bezier function might work. Cheers.
Take a look at the Reference page for noise. There are at least 3 variations of setting parameters to noise() you can use or modify. Reference / Processing.org You may want to look into noiseSeed() and noiseDetail() to adjust the level of change in the Perlin noise function as well.
Good, your making progress. Perlin noise is subtle. You might try applying noiseDetail() as well to adjust it. Reference / Processing.org Once you have the parameters set to where you like them, usually by experimenting with them, there is no further need to adjust noiseDetail() in your rendering loop.