Water Simulation - FFT/ Perlin Noise

Started by
2 comments, last by Soiled 19 years, 5 months ago
I`m trying to simulate the movement of water (a lake) by creating a heightmap using FFT as this appears to be the most suitable method for this situation. I have read "Deep-Water Animation and Rendering" by Jensen and "a simple fluid solver based on the FFT" by Jos Stam but have having great difficulties in understanding it. In particular in "Deep-Water Animation and Rendering" I am unsure of all the notation and which parameters I have to define to begin with. It also only seems to mention a horizontal position (X), how does this apply to making a 2D heightmap? Does anyone no any other useful links on this or are able to explain things to me in a simplified version? Thanks [Edited by - Paul7 on October 26, 2004 3:28:02 PM]
Advertisement
I remember a demo with this method. its in nvidia's developer site. I cant find it now, but try to look for it. maybe its in their FX Composer or something. Anyway, maybe i can help you, if you have a more specific question, and if ill find some time.
In general, the FFT method just uses an inverse fourier transform to take a lot of random waves, and sum them up to create the height map. each position on the map has a height, and moves only vertically. It looks like water, because the amplitudes are calculated using an empirical equation, philips spectrum, if i recall curectly.
Just read a lot, again and again, and read a bit about fourier transforms, you should be fine. leave the navier-stokes equations aside for now.
Thanks pickups, I`ll just have to keep going back to it and re-reading it, i`m sure i`ll get it eventually.

While I`m trying to figure that out I`ve decided to try animating the water using Perlin Noise.

Ive done this quite easily but am just unsure how to animate the perlin noise heightmap. Any insight into this would be much appreciated?

Also what dimension heightmap would you recommend using, should I do say 128x128 and tile it? if perlin noise is tileable?

Thanks.
I animate perlin noise heightmap by using 3D perlin noise (x,y,t) with 3rd dimension being time to create a sequence of heightmaps that I cycle through and lerp between. I make the noise tileable in all dimensions (including time, so that the animation doesn't pop when you repeat the time cycle). To make perlin noise tileable you can wrap the integer grid coordinates used to lookup the gradient noise (ie, (ix & tileMask) instead of ix).

This topic is closed to new replies.

Advertisement