Skip to content

Perlin Noise Tree Generator with seeds on Processing. ✨🌳

License

Notifications You must be signed in to change notification settings

foximaychik/noise_generator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Perlin Noise Generator on Processing

Perlin Noise Generator with seeds on Processing.

Seeds and Trees

On the same seed trees locations and textures will be the same.

How to change seeds?

Change "seed" variable to your value (sb.pde).

int seed = seedGen(100, 1000);

To:

int seed = 999; //for example

How to add trees?

Add tree texture to the "tree_txr" folder. Then add some strings of code(sb.pde).

  • Add "PImage":
//Original code
PImage oak;
PImage sakura;
//Example code
PImage dark_oak;
  • Change this string:
tree_type = (int) random(0, num); 

Change "num" to number of your tree.

  • Add cases to switch:
switch (tree_type) {
//Original code
  case 0:
    image(oak, wn, hn, treeh, treeh);
    break;
  case 1:
    image(sakura, wn, hn, treeh,treeh);
    break;
//Example code
  case 2:
    image(dark_oak, wn, hn, treeh, treeh);
    break;
}

About

Perlin Noise Tree Generator with seeds on Processing. ✨🌳

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published