Java-Gaming.org    
Featured games (81)
games approved by the League of Dukes
Games in Showcase (498)
Games in Android Showcase (114)
games submitted by our members
Games in WIP (563)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Perlin Noise (Infinite) Biomes?  (Read 910 times)
0 Members and 1 Guest are viewing this topic.
Offline Seiya02

JGO Coder


Medals: 3
Projects: 4
Exp: 5 years


No Text Here :x


« Posted 2013-12-23 15:19:27 »

So I tryed to do something with 2D Perlin Noise (The generation is Infinite) and made some 1024x1024 Images to see how the Biomes and the height fits together.

Seed 1


Seed 2


Seed 3


The third one is quite ok inside the 1024x1024, but the other ones are a little messed up, i mean those small Biomes within a big one isn't what i want. The Biomes are generated by Using 2 Noise Maps (For Example Tempreture and Climate) and like when the values of both are above 0.5f it's red, etc. How do i get those Biomes to be "Smooth"?
Offline jmguillemette
« Reply #1 - Posted 2013-12-23 16:07:02 »

very cool,

would you be able to give a quick tutorial or write up on perlin noise?

this is an area im very interested in.

thanks!
j.

-=Like a post.. give the author a medal!=-
Offline matheus23

JGO Kernel


Medals: 107
Projects: 3


You think about my Avatar right now!


« Reply #2 - Posted 2013-12-23 17:36:45 »

How do i get those Biomes to be "Smooth"?

I think this algorithm might help out as a 'after-effect':
http://roguebasin.roguelikedevelopment.org/index.php?title=Cellular_Automata_Method_for_Generating_Random_Cave-Like_Levels

Quote
The basic idea is to fill the first map randomly, then repeatedly create new maps using the 4-5 rule: a tile becomes a wall if it was a wall and 4 or more of its nine neighbors were walls, or if it was not a wall and 5 or more neighbors were.

See my:
    My development Blog:     | Or look at my RPG | Or simply my coding
http://matheusdev.tumblr.comRuins of Revenge  |      On Github
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline Seiya02

JGO Coder


Medals: 3
Projects: 4
Exp: 5 years


No Text Here :x


« Reply #3 - Posted 2013-12-23 18:23:10 »

Okay, But how will this work with infinit biomes?
Offline matheus23

JGO Kernel


Medals: 107
Projects: 3


You think about my Avatar right now!


« Reply #4 - Posted 2013-12-23 18:24:39 »

Okay, But how will this work with infinit biomes?

Good question. I have no clue  Grin

See my:
    My development Blog:     | Or look at my RPG | Or simply my coding
http://matheusdev.tumblr.comRuins of Revenge  |      On Github
Offline RawringNymNym

Senior Newbie





« Reply #5 - Posted 2013-12-23 20:02:07 »

I did similar with a "round" world generator I was playing with, I put the world through a few passes of a check for how many points around it. Checking 8 around it would work for smoothing, but not for removing the small biomes. To do that you would need to use a wider area to check.

From my testing, the wider the area, the more small areas are cleaned up, the more times it is run, the smoother the edges. One difference with my generator is that this was done at the end of each step, as my world generator subdivided until it reached full size. ( Square-Diamond algorithm)

Here's an example of before and after:




As for getting it to work on infinite generation, just don't perform the smoothing on the outer edge, so there's always something to sample. Make the border is as wide or wider than your scan range, so you never try to access outside of what's generated (if 17x17, or 8 radius, then atleast Cool

Of course this isn't always the fastest ever, so you have to balance accuracy and speed.
Offline RobinB

JGO Ninja


Medals: 44
Projects: 1
Exp: 3 years


Spacegame in progress


« Reply #6 - Posted 2013-12-23 21:14:54 »


Look up voronoi diagram (also cellular noise).
This algorithm helps dividing space in regions, which you could give values according to other noise.

How it looks:


With this you still could have small places, this could be overcome with some variation of the Halton sequence (fills up space random, but evenly).

Good luck!
Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

BurntPizza (20 views)
2014-09-21 02:42:18

BurntPizza (14 views)
2014-09-21 01:30:30

moogie (14 views)
2014-09-21 00:26:15

UprightPath (25 views)
2014-09-20 20:14:06

BurntPizza (27 views)
2014-09-19 03:14:18

Dwinin (40 views)
2014-09-12 09:08:26

Norakomi (73 views)
2014-09-10 13:57:51

TehJavaDev (96 views)
2014-09-10 06:39:09

Tekkerue (49 views)
2014-09-09 02:24:56

mitcheeb (70 views)
2014-09-08 06:06:29
List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06

List of Learning Resources
by SilverTiger
2014-07-31 11:54:12

HotSpot Options
by dleskov
2014-07-08 01:59:08
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!