Gamestudio Links
Zorro Links
Newest Posts
FXCM demo test failed
by qin. 01/13/26 13:53
Camera always moves upwards?
by NeoDumont. 01/12/26 09:39
Alpaca Plugin v1.5.2 Release
by kzhao. 01/11/26 13:42
Alpaca Plugin v1.4.0
by kzhao. 01/11/26 13:38
separating groups of 3 digits by a comma
by joe_kane. 01/11/26 00:01
MRC.c and WFO
by joe_kane. 01/10/26 23:58
BarOffset (default = 940 for daily bars?
by joe_kane. 01/10/26 23:46
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
0 registered members (), 5,207 guests, and 4 spiders.
Key: Admin, Global Mod, Mod
Newest Members
promfast, joe_kane, Namitha_NN, Syndrela, agasior
19190 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 3 of 4 1 2 3 4
Re: view frusta and shadow map [Re: zazang] #185622
03/01/08 02:49
03/01/08 02:49
Joined: May 2002
Posts: 7,441
ventilator Offline
Senior Expert
ventilator  Offline
Senior Expert

Joined: May 2002
Posts: 7,441
i think pd3ddev->clear() can be used in lite-c but the question is where to use it. how could i only use it for the depth buffers? doesn't render_sky get called for all rendering? can i access the current view there?

Re: view frusta and shadow map [Re: ventilator] #185623
03/01/08 09:47
03/01/08 09:47
Joined: Jan 2004
Posts: 2,013
The Netherlands
E
Excessus Offline
Expert
Excessus  Offline
Expert
E

Joined: Jan 2004
Posts: 2,013
The Netherlands
Great work, ventilator! I tried this back in the A6 times but couldn't get it to work because of the many workarounds it required then.

There are several shadowmapping techniques that are compatible with pssm. It's the group of warping techniques (pssm is a splitting technique). Some examples are PSM, LiSPSM, TSM, and some more. They're all based on using a different projection, so that the shadowmap space is used optimally.

Do your split-frustums fit tightly around their chunk of the normal view frustums?

Re: view frusta and shadow map [Re: Excessus] #185624
03/01/08 10:19
03/01/08 10:19
Joined: May 2002
Posts: 7,441
ventilator Offline
Senior Expert
ventilator  Offline
Senior Expert

Joined: May 2002
Posts: 7,441
you mean psm, lispsm, tsm,... additionally could be used for the single frustum splits?

what i do at the moment is to take the usual light projection matrix and then apply a cropping matrix for each frustum split. just like in pssm example from the link. so the split frustum gets scaled up to fit the size of the shadow map but i guess depending on perspective distortion there still can be quite some wasted resolution.

Re: view frusta and shadow map [Re: ventilator] #185625
03/01/08 11:57
03/01/08 11:57
Joined: Jan 2004
Posts: 2,013
The Netherlands
E
Excessus Offline
Expert
Excessus  Offline
Expert
E

Joined: Jan 2004
Posts: 2,013
The Netherlands
Yes, I think it could be done, but I've never implemented a warping scheme so I can't say for sure.

If you could pull this off and add some softening technique too, we'll have the perfect shadowmapping technique for large outdoor scenes.

BTW, I mentioned PSM, but I would stay away from it because it has many issues. I'd probably go with TSM.

Re: view frusta and shadow map [Re: Excessus] #185626
03/01/08 14:57
03/01/08 14:57
Joined: Jan 2003
Posts: 4,615
Cambridge
Joey Offline
Expert
Joey  Offline
Expert

Joined: Jan 2003
Posts: 4,615
Cambridge
the problem is that you need one view per spotlight and up to 6 for point lights. now imagine how many views you'd have to render when your scene has 8 visible lights? of course you can optimize the process, e.g. via view clipping etc... but it will be slow.

Re: view frusta and shadow map [Re: Joey] #185627
03/01/08 15:04
03/01/08 15:04
Joined: May 2002
Posts: 7,441
ventilator Offline
Senior Expert
ventilator  Offline
Senior Expert

Joined: May 2002
Posts: 7,441
yes, 8 * 6 views would be a bit extreme. but the pssm example only uses 4 views. 3 could be enough too. i wouldn't need many more shadow casting lights for the outdoor scenes i have in mind for my projects.

Re: view frusta and shadow map [Re: Joey] #185628
03/01/08 15:13
03/01/08 15:13
Joined: Jan 2004
Posts: 2,013
The Netherlands
E
Excessus Offline
Expert
Excessus  Offline
Expert
E

Joined: Jan 2004
Posts: 2,013
The Netherlands
Yes, but PSSM is mainly usefull for shadowing large scenes with a directional (sun) light. Shadowmap aliasing increases as the light moves further from the shadowed objects, so PSSM is not needed for omnidrirectional lights (since they are mostly used in indoor scenes).

Using it only for the sun leaves you with 4 depthmap renders and one normal render. That's acceptable on modern hardware and gives you shadowing for the entire scene.

Re: view frusta and shadow map [Re: Excessus] #185629
03/02/08 13:46
03/02/08 13:46
Joined: Jan 2003
Posts: 4,615
Cambridge
Joey Offline
Expert
Joey  Offline
Expert

Joined: Jan 2003
Posts: 4,615
Cambridge
true. does anyone know a way of attaching more than 4 textures to a material so that we can make use of the 16 texture samplers of modern graphics hardware?

Re: view frusta and shadow map [Re: Joey] #185630
03/02/08 13:53
03/02/08 13:53
Joined: May 2002
Posts: 7,441
ventilator Offline
Senior Expert
ventilator  Offline
Senior Expert

Joined: May 2002
Posts: 7,441
i think this can be done with the LPD3DXEFFECT settexture() function but currently you have to do it with a plugin because the lite-c d3d9.h seems to be lacking the effect interface.

Re: view frusta and shadow map [Re: ventilator] #185631
03/02/08 14:02
03/02/08 14:02
Joined: Jan 2004
Posts: 2,013
The Netherlands
E
Excessus Offline
Expert
Excessus  Offline
Expert
E

Joined: Jan 2004
Posts: 2,013
The Netherlands
Yes I needed that too and jcl was so nice to add it right away. It's available in the latest beta (7.08.0b).

Page 3 of 4 1 2 3 4

Moderated by  Blink, Hummel, Superku 

Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1