Contents
Sponsored Feature: Ocean Fog Using Direct3D 10
 
 
Printer-Friendly VersionPrinter-Friendly Version
 


Part of:



[More information...]
 

Latest News
spacer View All spacer
 
February 9, 2010
 
EA Reduces Quarterly Loss, Claims #1 Publisher Position [5]
 
EA: Distribution Business To Be Pared Down, Headcount Stable In 2010
 
Game Developer Announces Salary Survey Call, Now Including Indies [4]
spacer
Latest Jobs
spacer View All     Post a Job     RSS spacer
 
February 9, 2010
 
Konami Digital Entertainment Co., Ltd.
Sound designer
 
Trion Redwood City
Sr. Graphics Programmer
 
Trion Redwood City
Sr. Environment Modeler
 
Vicarious Visions / Activision
Tools Programmer
 
Sparkplay Media
Senior Game Designer
 
Blue Fang Games
Producer: Online/Mobile
 
Blue Fang Games
Senior Server Engineer: Online/Mobile
 
THQ
Global Brand Manager with Video Game industry Experience!
spacer
Latest Features
spacer View All spacer
 
February 9, 2010
 
arrow Two Halves, Together: Patrick Gilmore On Double Helix [1]
 
arrow The Road To Hell: The Creative Direction of Dante's Inferno [18]
 
arrow The Sensible Side of Immersion [10]
 
arrow Jumpstarting Your Creativity [5]
 
arrow Truth in Game Design [49]
 
arrow Postmortem: Vicious Cycle's Matt Hazard: Blood Bath and Beyond [4]
 
arrow Developers React: The iPad's Future [16]
 
arrow The Next Big Steps In Game Sound Design [12]
spacer
Latest Blogs
spacer View All     Post     RSS spacer
 
February 9, 2010
 
[Lineage 2] Freya Update Is Just a Beginning ②
 
Swashbuckling for Landlubbers: Why you may already be encouraging piracy! [4]
 
[Lineage 2] Freya Update Is Just a Beginning ①
spacer
About
spacer News Director:
Leigh Alexander
Features Director:
Christian Nutt
Editor At Large:
Chris Remo
Advertising:
John 'Malik' Watson
Recruitment/Education:
Gina Gross
 
Feature Submissions
Features
  Sponsored Feature: Ocean Fog Using Direct3D 10
by Jeff Andrews & Chuck Desylva,Alfredo Giminez
4 comments
Share RSS
 
 
June 11, 2009 Article Start Page 1 of 3 Next
 

[In this new Intel-sponsored feature from the Visual Computing microsite, a trio of Intel engineers showcase an experiment to create an ocean and complex fog effects using Direct3D 10 and Shader Model 4.0, complete with freely available source code and executable demo.]

Introduction

The purpose of this project was to investigate how we could effectively render a realistic ocean scene on differing graphics solutions while trying to provide a current working class set of data to the graphics community.

Given the complexities involved with rendering an ocean as well as fog effects we chose to start by using a projected grid concept, because of its realistic qualities, as our baseline.

We then ported the original Direct3D 9 code to Direct3D 10 and also ported the additional effects we needed to convert to Shader Model 4.0. In doing so we took advantage of a great opportunity to learn about an interesting subject (the projected grid) while adding many more nuances to it.

In addition to determining how best to work with this complex system under a DirectX10 scenario, we also wanted to know what would be required to achieve reasonable frame rates on both low- and high-cost graphics solutions.


During this endeavor we learned much about how to offload certain computations to the CPU versus the GPU, as well as when and where those compute cycles would be the most beneficial, both on high-end and low-end graphics solutions. For example, on the CPU front, using the Intel Compiler (version 10.1), we were able to gain an easy 10+ fps on our CPU-side computations (to generate fog and approximate wave movement).

Projected Grid Ocean

The basic concept behind the projected grid ocean is a regular discretized xz-plane that is displayed orthogonally to the viewer in world space. The vertices of this grid are then displaced using a height field. The height field is a product of two variables, which return the height value as specified by the following equation:

This method has proven very useful for generating a virtual large body of water.

The Perlin noise computation for generating the wave motion uses four textures of varying granularity called "octaves" to animate the grid in three dimensions. We chose this method to generate wave noise over other functions, such as Navier-Stokes, because it was less compute intensive on the CPU. The GPU-side Navier-Stokes implementation was not used, but it is worth further investigation. For reflections and refractions the algorithm uses derivations of Snell's function.

To further add realism to the scene we restricted the height of the camera on the y axis so that the illusion of ocean vastness could be maintained.

For a detailed description of this method, refer to Claes Johanson's Master Thesis.1

---

1 Johanson, Claes. "Real-time water rendering-introducing the projected grid concept." Master of Science thesis in computer graphics, March 2004. http://graphics.cs.lth.se/theses/projects/projgrid/, http://graphics.cs.lth.se/theses/projects/projgrid/projgrid-hq.pdf (PDF)

 
Article Start Page 1 of 3 Next
 
Comments

Jeromie Walters
profile image
Perhaps a video link or screenshot for those of us who would like to see it but still have Windows XP and cannot download the DirectX 10 runtime? Otherwise awesome article, enjoyed the read and just wish I could see it all in action! :)

David Paull
profile image
How can you have a article like this without pictures?

Simon Carless
profile image
We've added some screenshots, thanks - the original white paper this was taken from didn't have any, but Intel dug some up for us.

Jeromie Walters
profile image
Wow, screens look awesome! Thanks for adding the pics!


none
 
Comment:
 


Submit Comment