This began as an exercise in generative art. With the goal of having a randomly generated, pseudo-accurate island rendered, I combined a variety of techniques to achieve the result. Every run generates a completely unique island.

The app itself was written in Coffeescript and rendered using the HTLM5 canvas element.

Drawing an Island

  1. Generate a Voronoi grid, and derive a node graph of cell centers, edges, verticies. Assign each cell an array of it’s neighbours.
  2. Use a modified, center-weighted Perlin noise generator to determine elevations, and normalize around a midway point which creates land and sea division.
  3. Run a recursive function to determine the downslopes (each vertex has a neighbour which is lower in elevation, which eventually leads to the coast).
  4. Randomly seed n rivers in the highlands, and trace their path to the coast. Allow pooling in flat areas, with a drain at the lowest point.
  5. Using coastal and river-generated moisture, alongside elevation, assign biomes to the cells. I used 16 unique biomes.
  6. Render the cells in 2.5D, using colors to differentiate biomes, draw rivers (width = flow), and draw vegetation sprites for some biomes.
The node graph used to determine coastlines, elevations, and other topological features.