XR Ocean

Description
XR Ocean is a high-performance ocean rendering system specifically engineered for virtual reality applications. Built in Unity, this asset delivers physically accurate ocean simulation at the 72+ FPS required for comfortable VR experiences, achieving a 10x performance improvement over traditional CPU-based implementations through aggressive parallelization with DOTS and VR-specific shader computation.
Let me know if you have any questions or suggestions about the tool.
Download the spreadsheet
Here you can test a lite version of this tool right now. Let me know if you are interested in the Full-Version.
To the Lite Version

Technical Implementation

The system implements Jerry Tessendorf's FFT-based ocean simulation model, computing statistically realistic wave patterns from wind parameters using the Phillips spectrum. The entire computation pipeline runs on Unity's Burst-compiled Job System, dividing the workload into 13 specialized parallel jobs that process wave synthesis, displacement mapping, and surface normal generation concurrently.

Core Mathematical Framework:

  • Wave Synthesis: Inverse Fast Fourier Transform converts frequency-domain wave spectra into time-evolved displacement fields
  • Phillips Spectrum: Statistical ocean model generates realistic wave distributions based on wind speed and direction
  • Choppy Waves: Horizontal displacement creates sharp wave crests through Lagrangian perturbation
  • Dynamic Foam: Jacobian determinant detects wave folding for physically-based foam generation

Key Features

Adaptive Quadtree Rendering - Hierarchical level-of-detail system dynamically subdivides the ocean surface based on camera distance, rendering nearby waves at full detail while optimizing distant water. Custom edge-stitching with 16 mesh configurations eliminates cracks between LOD boundaries.

VR-Optimized Pipeline - Single-pass stereo rendering, reduced shader complexity for VR, and aggressive frustum culling specifically tuned for wide FOV headsets. Distance-based quality scaling maintains visual fidelity while ensuring consistent frame timing.

Physically-Based Shading - Multi-layer rendering with subsurface scattering approximation, Fresnel-based reflections, and hierarchical normal mapping. Seamless integration of ocean-scale waves with high-frequency detail normals.

Production-Ready - Configurable 128×128 to 512×512 FFT resolution, real-time parameter tweaking, smooth environment transitions, and comprehensive wind control system. Fully compatible with Unity's Universal Render Pipeline.

Performance Metrics

  • Computation: 1.5ms total CPU time for full ocean update (128×128 grid)
  • Memory: ~8MB for displacement/normal textures and lookup tables
  • Scalability: Maintains 72 FPS on Quest 3, 90 FPS on PC VR
  • Draw Calls: Maximum 16 instanced draws regardless of visible patch count

Technical Stack

Unity 6000.0.41 LTS | Burst Compiler | Job System | URP | HLSL | C# | FFT | Parallel Computing