We stand with Ukraine!
Simulating Ocean Waves

How does it work?

As you will see in this chapter, making an implementation of the Tessendorf paper doesn't require any complicated code or magic Fourier transform library. We believe this is the first and only document on the internet that makes it readily available to anyone (and that probably deserves a little donation) if you can afford it).

How does it work? The first thing we recommend you to do is to have a look at the original paper entitled "Simulating Ocean Water" (by Jerry Tessendorf). It is readily available on the internet. The paper was published in 2001 (a long while ago already).

As mentioned in the introduction, the main idea is that the motion of waves can be decomposed into frequencies (using for instance from measured data the forward discrete Fourier transform that we studied in the previous chapter). By applying the inverse operation from this very specific set of frequencies, which you can look at as the unique signature of the way ocean waves move, we can thus reconstruct an ocean surface. Very simply put, if you know the recipe of a dish, you know how to make that dish. We showed such example in the previous chapter: if you know the frequencies that are making up an image, you can reconstruct this image from theses frequencies. The principle is the same excepted that in this particular case we will reconstruct a patch of ocean water.

If we want to represent a patch of ocean surface, you can guess that what we will need to do is move the vertices of a 3D grid up or down (vertically, along the y-axis). You can see this operation as a form of displacement. The question is thus "how do we compute the height of these vertices to have a resulting mesh that actually looks like an ocean surface?"