the best ssao ive seen

Started by
237 comments, last by Paksas 12 years, 5 months ago
Awesome work, excellent !!
Advertisement
Quote:Original post by LotusExigeS1
Awesome work, excellent !!


Thank you :). It´s been quite some time of tinkering with ssao & co. but with this one i´m satisfied enough :)
Firstly, thanks again ... the end result looks stunning.

I have an ati x1950 card and in render monkey I am getting about 28 fps when using iterations=32. Does this sound low to you ?

I am using 35 for sample rad, jitter of 1, intensity of 3 and scale of 1.

Any quick tips for getting more fps ? I am going to render at half (or maybe quarter size) of the screen and then scale up as required which will obviously help. Just wondered if I had stuffed up the params.

Thanks again for your awesome work !!
Quote:Original post by LotusExigeS1
Firstly, thanks again ... the end result looks stunning.

I have an ati x1950 card and in render monkey I am getting about 28 fps when using iterations=32. Does this sound low to you ?

Thanks again for your awesome work !!


Well, with those params it does sound low for me :S. However i have a 8800GT, which -i´ve heard, don´t know for sure- it´s faster than yours, so that might make the difference...

Anyway there´s no magical tip to increase the fps, just try to find a parameter combination that looks ok for you. Maybe 16 samples with jitter and a post-blur will do the trick for you...

i´m glad you liked the results :)

Quote:Original post by ArKano22
I found and fixed another bug in the RenderMonkey project, the jittering texture was being incorrectly sampled and the jittering factor affected the sampling radius, which is not supposed to do.

Great! Now I see that eveything works as expected. I didn't realize how many errors I had introduced to your code. Thank you very much for those corrections.

If I drop to iterations=24 then it goes up to 60 fps. If I then also half the buffer size it goes up to 200 fps so thats good.

Thanks again for this.
First of all I'd like to say thanks to ArKano22 for originally providing the shader for this and those that have since made an HLSL version of it. Being interested in it I made a quick app earlier and all seems to be good apart from the left and top of the screen.

An image to show the problem:


Note, this doesn't happen on the right or bottom of the screen.

I'm just wondering if someone could help identify why the "artefact" is occurring? I render to two RT's for the postion and normal / depth and then switch to the main RT to calc and output the SSAO / image. As the issue is only apparent in the latter stage I assume it may be something to do with my full screen quad that I'm rendering to? This is the first time I've ever done pre/post processing to an image and outputting the final image via a quad, with the quad setup being as follows (if it helps):

#define FVF_QUADVERTEX (D3DFVF_XYZRHW | D3DFVF_TEX1)struct QuadVertex{	D3DXVECTOR4 p;	D3DXVECTOR2 t;};float width = 1.0f / (float)iBufferWidth_;float height = 1.0f / (float)iBufferHeight_;pVertices[0].p = D3DXVECTOR4( 0.0f, 0.0f, 0.0f, 1.0f );pVertices[1].p = D3DXVECTOR4( 0.0f, (float)iBufferHeight_, 0.0f, 1.0f );pVertices[2].p = D3DXVECTOR4( (float)iBufferWidth_, 0.0f, 0.0f, 1.0f );pVertices[3].p = D3DXVECTOR4( (float)iBufferWidth_, (float)iBufferHeight_, 0.0f, 1.0f );// It also happens without the offset added belowpVertices[0].t = D3DXVECTOR2( 0.0f - width, 0.0f - height);pVertices[1].t = D3DXVECTOR2( 0.0f - width, 1.0f - height);pVertices[2].t = D3DXVECTOR2( 1.0f - width, 0.0f - height);pVertices[3].t = D3DXVECTOR2( 1.0f - width, 1.0f - height);
Are you perhaps using WRAP rather than CLAMP for addressing the g-buffer texture?
Many thanks for sharing, very good job!

Does anyone try "posFromDepth" with the RM Project?
It looks bad if i use g_screen_to_camera, may be i do something wrong.
Quote:Original post by prem87
An image to show the problem:
Looks like you've got a jitter texture, which is supposed to be repeated over the whole screen, but is instead being clamped. Make sure your jitter texture is in wrap mode, not clamp mode.

Notice the top left corner is correctly jittered, the top rows are jittered horizontally only (using the right column of the jitter texture), and the left columns are jittered vertically only (using the bottom row of the jitter texture). All other pixels are jittered with the same constant value (i.e. not jittered) because they're all using the bottom right pixel of the jitter texture.

This topic is closed to new replies.

Advertisement