sinbad wrote:nullsquared wrote:Hm. If we want cubic shadows, think about it - Ogre preallocatoes shadow textures for each light - meaning, if you want to shadow 7 lights, you need 7 textures. If these are point lights, then 7*6 = 42 shadow textures! A better solution is to use a shadow map, render to it, render the light, and then continue the iteration using the same shadow map. This is where multiple shadow maps come in useful, though - you can render 2 lights at once with 2 shadow maps, and then use 1 pass, for example.
Deferred renderers fit really nicely with this. Since each light is automatically a separate pass, it's really easy to have per-light properties, only 1 shadow map for every light (thus even 10 lights can use 4096x4096 shadow maps, without running out of memory), and so on.
Yes, adding a path where each light shares the same shadowmap is something I've considered, although without deferred rendering it's not very efficient, since as you say it's much better to do all your lighting in one pass
Again, it's much project dependent. Even as some people say, you can do point light shadows by drawing each "side" separately, using only 1 shadow map and aggressive frustum culling.
(with a fixed maximum number of shadow casting lights, I've rarely found more than 3 to be necessary in most scenes to be honest).
Come on now, what is this?!? You actually
don't want DoomV to have at
least 50 fully-soft-self-shadowing point lights?
It's possible to do deferred rendering with Ogre already, I've done it before.
Of course, it's completely what powers Portalized's lighting and shadowing through portals

.
But it does require driving the render sequence much more manually than I would like.
Once again, much truth. But then again, I don't really mind it - having control is always nice. Besides, I got infinite (well, speed-limited) soft shadowing lights at with 2048x2048 shadow maps now - and it took me about 1 day to integrate, which was rather more with Ogre's in-built shadow mapping

(not sure if you remember some of the extremely odd issues I've had). There was an annoying "gotcha", though - tell me, why is PROJECTIONCLIPSPACE2DTOIMAGESPACE_PERSPECTIVE so conveniently hidden within the auto parameter sources? Took me quite a while to figure out how to align my shadow map to the scene right, and then all of a sudden I see Ogre's little handy matrix hidden deep within the sources
So yes, a core deferred rendering option would be good, again this is something on my pondering list. Won't happen before v1-6 though.
Not so sure about making it a core option. I'd say its much scene specific - different people lay out their G-buffer differently, materials differently, and so on.