Is there any good shadowing techniques that work really well in XNA and are easy to implement. I have seen lots of tutorials on shadows, but many do not work on big worlds it seems like almost like the depth map can't see that far? I really just need help rendering shadow maps onto large worlds. If anyone has seen a good article or use a certain method please tell me. Thanks in advance!
Members - Reputation: 889
Posted 17 September 2013 - 10:18 PM
There are a number of shadow mapping tutorials for XNA, so I guess that should be easy to implement. Shadow mapping is perhaps the most widely used shadowing technique in modern games. As you pointed out, it has some issues, especially with shadowing large outdoor areas.
If you want to have all objects cast a shadow from a directional light like the sun, for example, you might want to look at cascaded shadow maps. CSM is farily trivial to implement after having implemented normal shadow mapping, as it essentially just means you render the shadow map a number of times instead of just once. With CSM, shadow mapping generally works well in large areas.
Crossbones+ - Reputation: 8278
Posted 19 September 2013 - 05:55 PM
The most suitable shadowing technique really depends on a lot of factors, but the really relevant ones would be how many lights you have, how many of those do you want to be shadow-casting lights, is your light-blocking geometry static or moving, are your lights static or dynamic, are you doing directional lights, point lights or spotlights, are you a forward or deferred renderer, and how much do you actually care about performance? (That last one's only semi-tongue-in-cheek).
Shadow maps are the standard "go to" technique but can suffer from aliasing and depth-biasing crap which can be fiddly to deal with. Oddly, I'm doing some research at the moment that seems to indicate that for certain scenarios (deferred, lots of omni-directional lights, everything can cast shadows, DX10+ GPU) using stencil shadow volumes may be a more optimal choice. This is really an "it depends" answer.
It appears that the gentleman thought C++ was extremely difficult and he was overjoyed that the machine was absorbing it; he understood that good C++ is difficult but the best C++ is well-nigh unintelligible.