Jump to content

  • Log In with Google      Sign In   
  • Create Account


#ActualMchart

Posted 16 August 2014 - 10:43 AM

 

 

Prefiltering is just an optimization. You could use NxN sampling kernel with gaussian weights in your shadow shader. Try to also use bilinear filtering, You can also generate mipmaps and use trilinear/anistro filtering.

 

I am doing trilinear (GL_MIN and GL_MAG with GL_LINEAR and I generate mipmaps) but the result is somehow disappointing. I have no penumbra at all. 

I am using almost exactly the code here: http://fabiensanglard.net/shadowmappingVSM/  and my result is http://imgur.com/nkVtTYI which is rather blocky and no much better than a basic less than test :\

 

I know I can increase the resolution, but still no better than a simple test. PCF gives much more pleasing results

 

 

Have you tried aniso? How about more samples? Have you played with minimum variance constant? How about fast single pass 3x3 blur before creating mipmaps?

 

 

 

Thank you for your reply.

Yes I've tried aniso and the result is still the above. Regarding the min. variance constant what it change is just what change with the classic epsilon bias (i.e. acne and peter panning) and change the "blackness" of the shadow which however remains uniform. nothing about the penumbra. 

As for the 3x3 pass before the mip maps I wanted to avoid to write another shader for it, also for my application I may have to re-render the shadow maps at each frame so if I have to perform a filtering everytime, what's the advantage over a simple PCF? 

Note that my subject is one and all I'm dealing with is the correct selfshadowing as the in the picture above, don't know if this changes anything. 


#1Mchart

Posted 16 August 2014 - 10:43 AM

 

 

Prefiltering is just an optimization. You could use NxN sampling kernel with gaussian weights in your shadow shader. Try to also use bilinear filtering, You can also generate mipmaps and use trilinear/anistro filtering.

 

I am doing trilinear (GL_MIN and GL_MAG with GL_LINEAR and I generate mipmaps) but the result is somehow disappointing. I have no penumbra at all. 

I am using almost exactly the code here: http://fabiensanglard.net/shadowmappingVSM/  and my result is http://imgur.com/nkVtTYI which is rather blocky and no much better than a basic less than test :\

 

I know I can increase the resolution, but still no better than a simple test. PCF gives much more pleasing results

 

 

Have you tried aniso? How about more samples? Have you played with minimum variance constant? How about fast single pass 3x3 blur before creating mipmaps?

 

 

 

 

Prefiltering is just an optimization. You could use NxN sampling kernel with gaussian weights in your shadow shader. Try to also use bilinear filtering, You can also generate mipmaps and use trilinear/anistro filtering.

 

I am doing trilinear (GL_MIN and GL_MAG with GL_LINEAR and I generate mipmaps) but the result is somehow disappointing. I have no penumbra at all. 

I am using almost exactly the code here: http://fabiensanglard.net/shadowmappingVSM/  and my result is http://imgur.com/nkVtTYI which is rather blocky and no much better than a basic less than test :\

 

I know I can increase the resolution, but still no better than a simple test. PCF gives much more pleasing results

 

 

Have you tried aniso? How about more samples? Have you played with minimum variance constant? How about fast single pass 3x3 blur before creating mipmaps?

 

 

Thank you for your reply.

Yes I've tried aniso and the result is still the above. Regarding the min. variance constant what it change is just what change with the classic epsilon bias (i.e. acne and peter panning) and change the "blackness" of the shadow which however remains uniform. nothing about the penumbra. 

As for the 3x3 pass before the mip maps I wanted to avoid to write another shader for it, also for my application I may have to re-render the shadow maps at each frame so if I have to perform a filtering everytime, what's the advantage over a simple PCF? 

Note that my subject is one and all I'm dealing with is the correct selfshadowing as the in the picture above, don't know if this changes anything. 


PARTNERS