SSAO (Screen Space Ambient Occlusion) with D3DX9
This is my SSAO implementation by useing D3DX9 API. I had tried some other solutions, and this is the best SSAO algorithm that I can found to gives good result.
If you have a better solution, please let me know, thant you!
the follow picture show the steps of my implementation:

my demo screenshot:
1) use simple blur

2) use gaussian blur

the below picture is the screenshot of another SSAO solution I had tried:

you can download the sourcecode from here.
Tips :
In my demo, you can view the argb buffer when press key 'C'.

浙公网安备 33010602011771号