Volumes Of Fun
http://www.volumesoffun.com/phpBB3/

fractal noise generator?
http://www.volumesoffun.com/phpBB3/viewtopic.php?f=2&t=167
Page 1 of 2

Author:  Shanee [ Wed Mar 09, 2011 12:46 pm ]
Post subject:  fractal noise generator?

Anyone might have a fractal noise class/function for c++? I found only one explanation of the math but didn't manage to apply it properly.

Author:  beyzend [ Wed Mar 09, 2011 5:10 pm ]
Post subject:  Re: fractal noise generator?

The libnoise tutorials does a good introduction to "noise"

http://libnoise.sourceforge.net/tutoria ... rial2.html

I'm currently using a library called noisepp (you can download it; it's home page is offline though)

http://sourceforge.net/projects/noisepp/

It supposedly incorporates several optimizations not available with libnoise. Although I haven't done extensive testing since I'm just trying to get my game together right now. Another plus is that it's API is directly compatible with libnoise.

Author:  Shanee [ Wed Mar 09, 2011 5:45 pm ]
Post subject:  Re: fractal noise generator?

Are you sure? When I tried libnoise it was SUPER slow, took ages for small regions to work.

Author:  beyzend [ Wed Mar 09, 2011 6:46 pm ]
Post subject:  Re: fractal noise generator?

I said I'm using noisepp because it's supposedly faster than libnoise. I'm not using libnoise.

And it depends on what you mean by fast. If you are generating 3D terrain with a bunch of "filters" it's may take awhile. For me, I'm only generating 2D terrain at the moment. When I was doing 3D noise it wasn't excruciatingly slow, it was decent.

The only way around it is implement it yourself and optimize the crap out of for multiple cores. I was planning on implementing it for OpenCL, just haven't got around to doing it.

Either way you have to realize depending on the terrain you expect it will have to generate a lot of data. R^3 is not to be trifled with, lol.

Author:  beyzend [ Wed Mar 09, 2011 6:51 pm ]
Post subject:  Re: fractal noise generator?

See this post where I have some times for how long it takes me to generate a 32x32x256 patch. Without the compression stuff it takes 0.04 ms so well above 60fps (with compression it's still around 60fps). Note that however, I'm only generating a 2D type terrain. BUT, for Minecraft style 3d terrain you should expect the same timing. I say this because I think Minecraft he only uses a single noise FBM "type"--i.e Perlin. Whereas in my setup I'm using a multifractal and perlin, plus other filters.

I don't know for sure though. You just have to mess around with it. I'm only at the beginning with my own terrain generation, I just have something up and running there is still a lot of work left to do.

Author:  beyzend [ Wed Mar 09, 2011 6:58 pm ]
Post subject:  Re: fractal noise generator?

Oh btw I'm using threads via a task-based system. So it doesn't really appear like it's slow... once the entire terrain is generated, new patches can be generated and it doesn't seem to slow down my rendering because generation and rendering are decoupled.

Maybe that's the reason why it feels so slow for you. You are generating them in sequence in a single thread.

Add: I also tried it on a single core machine with thread it still feels responsive. The overall generating may be slow but it's just as interactive as on my multicore machine. I think the trick is to decouple generation from rendering.

Author:  Shanee [ Wed Mar 09, 2011 7:13 pm ]
Post subject:  Re: fractal noise generator?

Are you talking about libnoise or the app? cause libnoise is kinda known to be not for real time.

About the app, is it fractal noise or perlin noise?

Author:  Shanee [ Wed Mar 09, 2011 7:16 pm ]
Post subject:  Re: fractal noise generator?

here you go:

http://www.ogre3d.org/forums/viewtopic. ... 1032dd0e69

there is a performance comparison just for that reaaon :)

Author:  beyzend [ Wed Mar 09, 2011 8:03 pm ]
Post subject:  Re: fractal noise generator?

My game is using noisepp so whatever noisepp supports so I guess it's coherent noise. Hey I'm not really at the point where I'm exploring options for generating terrain. I using noisepp right now and it works for me, decently enough so I can work on other aspects of my app.

Also, i'm confused on when you say fractal noise. When I think of Perlin noise I categorize that as a fractal noise because of self similarity. Do you have something else in mind when you say "fractal noise". Maybe midpoint displacement or something? I know these coherent noise functions are suitable for my needs because they generate 3D noise. I've messed with things like midpoint displacement but only for 2D and I'm not sure whether it carries over to 3D or not.

Author:  beyzend [ Wed Mar 09, 2011 8:31 pm ]
Post subject:  Re: fractal noise generator?

Hey Notch made a post on terrain generation just now. He generates 3D noise at a lower resolution then interpolates.

Page 1 of 2 All times are UTC
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/