## Continent Samples

Added Continent Samples.

Steps to create:

- Outline the border to ensure all edges are ocean.
- Draw random lines originating from each edge to avoid flat coast lines.
- Draw random lines in the interior to separate landforms and create large bodies of water.
- Build Voronoi Diagram based on points that are members of lines. (Each cell value equals the distance to the nearest line point)
- Normalize Voronoi Diagram to values between 0.0 and 1.0
- Create FBM noise pattern and normalize to 0.0 and 1.0.
- Multiply Voronoi Diagram by FBM noise pattern.
- Set values < 0.2 to ocean, >= 0.2 to land.

It seems to me that you obtained wonderful results and I would be very interested in understand more about how you did.

I am writing too a world-generator in Java. I started playing with the perlin-noise algorithm and then I added some basic tectonics simulation (without it my continents tend to have mountains in the center and then degrades to the ocean).

We could exchange results and code if you like,

I can send to you some screenshots about what I obtained and some more detailed explanation,

Federico

So, I’m attempting to start the whole world generation aspect of my project (in Python) and I’m attempting to implement your algorithm. I feel like my method is horribly under-optimized and I’m sort of wondering how you chose to normalize your values. I have to run through the array twice in order to first determine the unnormalized values for each cell and find the maximum value that the array contains and then I run through it again to normalize. Is there some faster way you’ve done it?

John: in python you can avoid the first loop using the built-in max() function, which is faster — it loops through the elements and selects the greatest number, but implemented in an much more efficient way.

You may also want to check out map, reduce, all, any… which can be helpful in some situations. The module itertools (section 9.7 of the manual) has even more functions; using built-in operators as described at the top of that section of the manual should yield much faster results. Translating loops to this sort of operation can be a bit of a brain-twister though, not all algorithms can be translated, and although I can vouch for the super-speed of functions like max(), I haven’t tested the ones that ask for function handles like the ones in itertools.

I really like that you took your time. Hahaha just joking

Any chance I could get the source code you are using for “Build and Normalize Voronoi Diagram” and “Create FBM noise pattern and normalize to 0.0 and 1.0.”?

I’ve been searching all over the internet for this sort of thing. It’d be awesome if the steps outlined in the article could be fleshed out into a tutorial of sorts. Then people like me, who find it kinda hard to figure out the specifics, could learn to generate these cool continents. Please consider making one!

love your work!