Simulating Ocean Water
This video presents a school project involving two people. The aim was to simulate the surface of the ocean using two well-known models. The simulation is written in c++ and the rendering uses OpenGL. A windows executable can be downloaded here: https://drive.google.com/open?id=1HBTW-csEw9MxYY6SSlB7iZZeQZkLFLsV The first model is the Gerstner model. The surface is defined as a sum of elementary waves of decreasing amplitude and wave length and random propagation directions. This model is very simple to implement but has some issues, the most problematic one being its cost. Indeed, 5 to 10 elementary waves are necessary to achieve a realistic surface. The asymptotic cost is proportional to the number k of elementary waves and to the number of vertices: O(kn²) Adding more waves will increase the visual fidelity but the cost becomes unbearable for detailed grids. The second model is the Phillips model and addresses this issue. Instead of defining the elementary waves in a spatial formulation, they are defined in the frequency space. A 2D inverse FFT is performed in order to transform the 2D frequencies in a spatial displacement. The strength of the FFT is that its cost does not depend on the number of elementary waves and the asymptotic cost becomes O(n²*log(n)). A much higher number of elementary waves can be used without any impact on the performance. A good distribution of amplitudes for the wave vectors can be quite tricky to get and needs a lot of tweaking. The GUI enables to play with the distribution parameters interactively in order to find a suitable set of parameters. The FFT is currently implemented on the CPU but a parallel implementation computed on the GPU is mandatory for real-time applications such as video games. Source: https://people.cs.clemson.edu/~jtessen/reports/papers_files/coursenotes2004.pdf
Download
0 formatsNo download links available.