Fafalada said:
I am a bit skeptical myself (haven't tried this approach yet), it seems to put a lot of faith in fancy filtering resolving the resolution artifacts remaining.
Something to keep in mind is that I am so far not doing the same thing John C is doing. John C's version of the idea is definitely better for generalized rendering, and probably even better for specialized cases like my game. I have a milestone deadline on Tuesday, but later that week I am going to play around with John C's version and see how it goes.
The main difference is that in mine, I am switching between shadow maps by testing uv coordinates in the shader and using those to mask one shadow map versus another. When I draw an object, all shadow maps that touch the object need to be selected into the shader at once. For complex filtering operations, I would need to perform them on all the selected shadow maps and throw most away, or else eat dynamic branches. But the biggest problem is that there's going to be a limited number of shadow maps (currently two, I was thinking of expanding it to 3 but that's a bad road to go down), and the object has to fit inside the biggest one. In my scenes shown on that web page, the nearest shadow map is actually a lot more low-res than it could be, because of just this issue.
John C's stencil idea removes this problem. There only has to be one shadow map selected at a time, and for things that cross boundaries, you just render them multiple times and stencil the invalid stuff away. This generalizes to nearby point light sources etc etc (I was worried only about sunlight).
With this scheme I could make the shadow pixels in those screenshots 1/4 the size in each dimension, using the same texture resources I am now (so 16 pixels to 1). That is a pretty good increase, though the fill rate would be a bit higher (due to the stencil, and the fact that I'd be filling 4x the amount of shadow texture space). But it runs great on my laptop already, and my target system is a high-end desktop, so I think it will work fine.
At that point, the aliasing issues will be greatly diminished. Yes, some filtering will be employed too, but I don't think it will be necessary to get decent shadow resolution on a high-end card (like an X800). On an X800 you could just jack up the shadow map resolution one more time (to 1024x1024) so then you have 64 shadow pixels for every 1 in that screenshot.