Jump to content
  • Advertisement
Sign in to follow this  
terrence321

Shadow Maps With Checkerboard?

This topic is 4501 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I've been agonizing over this one a while, so I thought I'd post here to see if anyone else has seen this problem before. A picture would really explain it better than anything, so here are a couple: http://www.geocities.com/terrence321/ShadowMap1.jpg http://www.geocities.com/terrence321/ShadowMap2.jpg As you can see there are checkerboards in some of the trickier shadowed areas, and the weird thing is the checkerboard size is irrespective of distance to them! It's like there is a screen-aligned checkerboard of a fixed size, and there are "holes" on my models surface where I can see it. I've never had a problem like this before, and this one solitary problem is what's keeping my shadow mapping implementation from finally working. Any help is appreciated- please let me know if you can identify this problem. Thanks, Terrence

Share this post


Link to post
Share on other sites
Advertisement
which kind of shadow map implementation is this? Is it plain shadow maps? How do you soften the penumbra?

Share this post


Link to post
Share on other sites
It's plain-old shadow maps. I render the depth values from the light to a FBO, and then compare those values to pixels in a shader when I render the scene. The reason the shadows look a little soft is I perform 3x3 PCF on them. However, this exact problem occurs even if I don't do PCF.

Let me know if you have any more questions.

Terrence

Share this post


Link to post
Share on other sites
Also I should clarify that the checkerboard texture actually moves as my camera changes angles. Also I am using biasing, but even without that the checkerboard pattern is visible. Where on earth would that checkerboard even come from? I'm completely stumped.

Share this post


Link to post
Share on other sites
I had a problem like that some months ago, and that was caused by a driver bug (on an ATI card). Happened in very specific conditions.. it's been fixed in the latest drivers since, so if you haven't got those, that'd be the first thing to try.

Y.

Share this post


Link to post
Share on other sites
I got problems like these, when rendering depth to a 32-bit float rendertarget while the screen (accidentally) used 16-bits color and depth.

Share this post


Link to post
Share on other sites
Ok, thanks for sharing that information. But I did find out the error, and it was rather stupid. In some cases in my engine I was binding the shadow mapping shader (and thus the render target) while I was rendering to that target! OpenGL doesn't like that apparently.. imagine that.

So while it could be driver issues in some cases (that's what I thought for a while), it turns out there was a much simpler solution in this case.

Share this post


Link to post
Share on other sites
so do ati implement a checker pattern when somethings stuffed up?
shit thats what i do as well (ie i use it if the intended texture is missing/corrupt etc) im gonna have to change that then

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!