Recommended Posts

Hi,
my shadow map is displaying some (more) weird behaviour.
I have a test area, with a large plane, 4 static flat boxes and a ship I can move about. All objects use the same parallel split shadow mapping shader (except there is only a single shadowmap for debugging purposes.)
The shadow texture looks good now. However, there is a problem
The ship and boxes will cast shadows onto the plane.
The ship will cast shadows onto the box.
Like this:
However, the box doesn't cast shadows onto the ship!
You can see how the two shadows are overlapping on the plane, but where is the shadow on the ship?? (The other shadows you can see in the background are from other boxes)
Its like the depth test isnt working in this instance. The first picture shows that the depth resolution is adequate to shadow opjects so close together.
Any ideas welcome, I am stumped by this one.

0

Share this post

Link to post

Share on other sites

What type of precision are you using for your shadow maps? There is the possibility that they are too close, the depth for each gets converted to the same integer value (from it's floating point value). Have you tried using floating point textures for the shadow maps, or decreasing the depth range (to incrase the possible values between the local depths).