**Wanho Choi
**

**(wanochoi.com)**

**Houdini 16 Ocean**

**FFT Ocean Algorithm**

• Jerry **Tessendorf**’s paper (SIGGRAPH 2001)

**Wind Waves**

• **Wind-generated waves**

• They result from the **wind blowing** over an area of fluid surface.
• After the wind ceases to blow, wind waves are called **swells**.

More generally, a swell consists of wind-generated waves that are not significantly affected by the local wind at that time.

**Wind Waves**

**Jean Baptiste Joseph Fourier**

*Théorie analytique de la chaleur (1822)*

**A continuous periodic function can be ****written as a sum of sine-waves**

https://en.wikipedia.org/wiki/Fourier_series

*f (x)* *= a*_{0} + (*a _{i}*

*cos(ix)*

*+ b*

_{i}*sin(ix)*)

*i*=1

∞

**Fourier Analysis / Synthesis**
**Fourier Analysis**
**Fourier Synthesis**
**Fourier Analysis**
**Fourier Synthesis**
**Fourier Analysis**
**Fourier Synthesis**
**Fourier Analysis**
**Fourier Synthesis**
https://commons.wikimedia.org/wiki/File:Fourier_synthesis.svg
**+**
**=**
**=**
**=**
**=**
**+** **+**
**+**
**+**
**+**

**Fourier Transform**

**FFT & IFFT**

• **F**ast **F**ourier **T**ransform

• **I**nverse **F**ast **F**ourier **T**ransform

• The grid resolution must be a **power of two**.

**Height Field Approach**

http://matthias-mueller-fischer.ch/talks/GDC2008.pdf

**Superposition**

http://andrewmacthoughts.blogspot.kr/

http://geology.uprm.edu/MorelockSite/morelockonline/2-waves.htm http://misclab.umeoce.maine.edu/boss/classes/SMS_491_2003/Week_6.htm

**Spectral Weights**

• Ocean wave spectrum

• Phillips spectrum
• Pierson-Moskowitz spectrum
• JONSWAP spectrum
**Phillips spectrum**
*P _{h}*

**(k)**

*= A*exp(

*−1/ (kL)*2 )

*k*4

**k**

**⋅w**2

**Dispersion Relationship**

• Waves of different wavelengths travel at different phase speeds.

• Deep water:

• Finite depth water: • Shallow water:

ω *(k)* *= gk*

ω *(k)* *= gk tanh(kD)*

• Horizontal displacement

• 3D displacement (2D field)

**Choppiness**

• Bi-linear interpolation • Ocean patch

**Ocean Patch & Interpolation**

1 2
3 4
3 4
2
1 a
b
α _{1}_{−} _{α}
β
1− β
a = (1− α ) × 1 +α × 2
b = (1− α ) × 3 +α × 4
= (1− β ) × a +β × b
= (1− α ) × (1− β ) × 1
+α × (1− β ) × 2
+(1− α ) × β × 3
+α × β × 4
?

**Ocean Patch Tiles**

**Grid Resolution**

**Ocean Foam Geometry Node**

• This node creates foam particles that can be used to enhance rendering of an

ocean surface. The input is a one or more merged Ocean Spectrum layers that comprise the ocean.

• There are two modes for this SOP:

• **Emitter: Particles are created within a specified region based on various emission **

criteria from the input ocean layers. These particles could then be fed into any custom particle simulation for emission.

• **Solver: Foam particles are created according to the various emission criteria then **

run through a 2-D particle simulation that incorporates the ocean velocity and neighboring particle proximity to give realistic foam behavior. The output of this mode can be used directly for rendering foam with the Ocean Surface shader.

**ocean_sample()**
vector **ocean_sample**
(
string geometry,
int phase,
int frequency,
int amplitude,
float hscale,
float time,
int mode,
int downsample,
vector pos
)
http://www.sidefx.com/docs/houdini/vex/functions/ocean_sample