When we’re not building games or creating incredible experiences with augmented reality we like to try and dive deep into a topic to broaden our skill set. The way we run our research means we don't always have a specific purpose for the tech. Really we just want to learn along the way and make something cool!
As beneficial as this has been for us, it’s even better when we share that learning. Maybe we’ll inspire someone, maybe we’ll get one of those fancy Facebook Likes, and hopefully someone way smarter than us will point out all of our mistakes!
Through a series of posts we’re going to be tackling a personal challenge we've set for ourselves. The real-time simulation and rendering of an ocean.
One of the biggest challenges in creating a convincing ocean is that the ocean is constantly in motion. This motion is complex and makes it impractical to have it modelled and animated by hand in a traditional 3D tool. This means that you need to generate the ocean through code using a variety of procedural techniques.
There are an endless amount of features that you can support and it helps to have a goal so we settled on the following requirements.
- Real Time
- Support buoyancy queries so objects can float on the surface.
- Level Of Detail (LOD) scheme to handle covering the entire camera view for an infinite sized Ocean.
- Support wakes, obstacles, and user controlled waves.
- Support landmasses and coasts.
- Artist controllable values to tweak the behaviour and look of the ocean.
- Scalable (From a high end PC down to a mobile device)
Table Of Contents:
Getting to the final product takes some time so this post will be updated to keep a table of contents as we share our progress.
- First Attempts
- Gerstner Waves
- FFT Waves
- LOD Approaches
- Wakes, Obstacles and User Controlled Waves
- Scalability (Mobile vs PC)
We didn't build this in a vacuum. A considerable amount of research went into this series and we built off the work of many others. We truly are standing on the shoulders of giants and are incredibly grateful to these individuals for sharing their experiences and research. This list will continue to grow as we progress further.
- UV Mapper Texture courtesy of: http://www.render-lab.com/UV_mapper.jpg
(If you wrote any of these papers come find us, we'll buy you a beer...and maybe pick your brain a bit)