Screen space ambient occlusion
- Falagard
- OGRE Retired Moderator
- Posts: 2060
- Joined: Thu Feb 26, 2004 12:11 am
- Location: Toronto, Canada
- x 3
- Contact:
Screen space ambient occlusion
I don't think this has been discussed here yet.
Crytek published a course paper about the technologies they used in Crysis. One that came up is Screen Space Ambient Occlusion.
Basically it is calculating ambient occlusion in realtime using the z buffer and some fancy tricks, or rendering the scene to a floating point texture and storing depth. No need to precalculate ambient occlusion maps, and works well for large scenes.
http://delivery.acm.org/10.1145/1290000 ... EN=6184618
There's a thread about it here on GameDev.net and some developers have actually started getting results with it:
http://www.gamedev.net/community/forums ... _id=463075
Screenshot below from one of the Gamedev.net posts:
http://www.rgba.org/iq/trastero/ssao6.jpg
I'm guessing within the next couple months some source code will materialize that we can look at and implement in Ogre.
Clay
Crytek published a course paper about the technologies they used in Crysis. One that came up is Screen Space Ambient Occlusion.
Basically it is calculating ambient occlusion in realtime using the z buffer and some fancy tricks, or rendering the scene to a floating point texture and storing depth. No need to precalculate ambient occlusion maps, and works well for large scenes.
http://delivery.acm.org/10.1145/1290000 ... EN=6184618
There's a thread about it here on GameDev.net and some developers have actually started getting results with it:
http://www.gamedev.net/community/forums ... _id=463075
Screenshot below from one of the Gamedev.net posts:
http://www.rgba.org/iq/trastero/ssao6.jpg
I'm guessing within the next couple months some source code will materialize that we can look at and implement in Ogre.
Clay
- Fiesch
- Gremlin
- Posts: 159
- Joined: Mon Oct 10, 2005 11:08 am
- Location: Bavaria, Germany
- Contact:
- PolyVox
- OGRE Contributor
- Posts: 1316
- Joined: Tue Nov 21, 2006 11:28 am
- Location: Groningen, The Netherlands
- x 18
- Contact:
-
- Silver Sponsor
- Posts: 597
- Joined: Sun Jan 07, 2007 11:55 pm
- Location: Cologne, Germany
- Contact:
- Falagard
- OGRE Retired Moderator
- Posts: 2060
- Joined: Thu Feb 26, 2004 12:11 am
- Location: Toronto, Canada
- x 3
- Contact:
If Crysis is using it, the results have to be pretty decent.jjp wrote:I just wonder how this looks like when the camera is moving around. Because obviously you only get occlusion from things that are visible on the screen.
Me too. If it works as well as I hope, this is THE solution I've been waiting for for large outdoor games where there is a dynamic moving sun.This is so cool! My heart rate actually sped up when I read this Shocked . One of those ideas that seem so obvious once you hear it - those are always the best ones.
Shouldn't be too hard to implement, no?
It doesn't have anything directly to do with casting shadows from a sun, of course, but my problem is that I've been banging my head on how to implement a combination of ambient occlusion + dynamic shadows on a large scene. For example, if I had to baked ambient occlusion textures for all stuff outside it was going to be a nightmare, but if this is just a post process and it works quickly - wow. It's right up there with the invention of parallax mapping as a cool technology.
That's assuming that someone can get it working, and running fast.
There's another paper out there that implements something similar here:
http://www.cs.utexas.edu/~perumaal/FINAL-paper121.pdf
I saw this one quite a while back but the speed was far too slow for real games (15 to 30 fps on an 8800 GTX). However, the Crysis guys got it working, and that GameDev.net has some other developers playing with the technique and getting between 30 and 150 fps.
How easy will it be to implement? It depends if someone releases some source code
- milliams
- Gremlin
- Posts: 172
- Joined: Fri Feb 16, 2007 1:47 am
- Location: Portsmouth, UK
- Contact:
- Praetor
- OGRE Retired Team Member
- Posts: 3335
- Joined: Tue Jun 21, 2005 8:26 pm
- Location: Rochester, New York, US
- x 3
- Contact:
-
- Silver Sponsor
- Posts: 597
- Joined: Sun Jan 07, 2007 11:55 pm
- Location: Cologne, Germany
- Contact:
That's what I thought. I guess as they are using it only for the ambient component artifacts aren't really noticable. Still... I'd be interested if there are scenarios where this technique would not be usable.Falagard wrote:If Crysis is using it, the results have to be pretty decent.
Enough is never enough.
-
- Halfling
- Posts: 57
- Joined: Wed Jul 14, 2004 10:12 am
- Location: Berlin
- Falagard
- OGRE Retired Moderator
- Posts: 2060
- Joined: Thu Feb 26, 2004 12:11 am
- Location: Toronto, Canada
- x 3
- Contact:
- milliams
- Gremlin
- Posts: 172
- Joined: Fri Feb 16, 2007 1:47 am
- Location: Portsmouth, UK
- Contact:
Flavien Brebion (A.K.A. Ysaneya, developer on the Inifinity Engine) managed to get this technique running with framerates at around 150 (http://www.gamedev.net/community/forums ... ?jn=263350). It's not the fastest but it's certainly a good speed tradeoff considering the payback. Given the speed with which people seem to have developed early prototypes, it doesn't seem difficult to get working in a simple fashion.
-
- Ogre Magi
- Posts: 1266
- Joined: Tue Aug 12, 2003 1:53 am
- Location: Melbourne, Australia
- x 1
- Contact:
The guy from the gameDev forums (first post) just released a demo of his own SSAO screenspace ambient occulusion with realtime fractals here in **4**k
There's a video of it for lower gfx cards otherwise SM3.0 is needed and it's pretty slow, not for the SSAO but the fractals.
http://rgba.scenesp.org/iq/demoscene/pr ... noiser.zip
from http://rgba.scenesp.org/iq/ demo section
Anyone trying to implement this technique yet?
There's a video of it for lower gfx cards otherwise SM3.0 is needed and it's pretty slow, not for the SSAO but the fractals.
http://rgba.scenesp.org/iq/demoscene/pr ... noiser.zip
from http://rgba.scenesp.org/iq/ demo section
Anyone trying to implement this technique yet?
Last edited by Vectrex on Sat Oct 20, 2007 1:59 pm, edited 2 times in total.
- cybereality
- Hobgoblin
- Posts: 563
- Joined: Wed Jul 12, 2006 5:40 pm
- x 12
- Falagard
- OGRE Retired Moderator
- Posts: 2060
- Joined: Thu Feb 26, 2004 12:11 am
- Location: Toronto, Canada
- x 3
- Contact:
Yeah, that demo is great. Runs at a decent clip on my machine, and the dude said that the screen space ambient occlusion is fast but it's the fractal stuff that's slowing things down.
He didn't release any code or shaders so I sneakily tried to use GLIntercept to grab the shaders (out of curiosity only of course) but it wouldn't run - exiting immediately. Darn
He didn't release any code or shaders so I sneakily tried to use GLIntercept to grab the shaders (out of curiosity only of course) but it wouldn't run - exiting immediately. Darn