Game Development Community

Selfshadowing

by Simon Sejer Nielsen · in Torque 3D Professional · 10/19/2009 (3:35 pm) · 14 replies

Im not sure if I did something wrong when importing my object here or anything but it seems like that selfshadowing is pretty messed up, also for some reason I am able to see every single face/poly on the object. If its me who did something wrong when I imported it please do feel free to correct me on this :)

img29.imageshack.us/img29/8652/shadow2f.jpg
img9.imageshack.us/img9/7081/shadowau.jpg

#1
10/19/2009 (7:50 pm)
It looks almost as if the flag object has no smoothing groups assigned. If this is the case, you will see all the polys as illustrated on the orange object. Check and make sure you have smoothing groups assigned. If so, then this may actually be a bug. I have not had this problem, however, when smoothing groups are assigned.

As for the shadows, I'm not too sure what would cause that. However, your example shows a pretty oversaturated light source at very close range, so maybe this has something to do with it.
#2
10/19/2009 (7:57 pm)
hmm yeah the upper part doesnt have any smoothing groups at all, but the lower part (not displayed on this picture) has and I think I might had been able to see it there, but I might be mistaken.
#3
10/19/2009 (8:53 pm)
512 shadow map ialways looks rough, bump it up to 1024 and "fiddle" with the other shadow settigns (like logwieght), I always set my splitfadedistances to 1 1 1 1 - but that's more distance related stuff.
#4
10/20/2009 (6:44 am)
@Steve, okay I tried to bump the shadow up to 2048 even, and also tried different values with the logweight - plus a little with the splitfadedistance, however the result on the character doesnt change at all, the shadows still looks awfully, weird on the character - even if positioned correctly at a close range he will turn all dark because the shadow seems to cover him completely.
#5
10/20/2009 (7:45 am)
It seems like that its only the Point Light that has these awfull selfshadowing problems, I tried with spotlight, and I, there diddent seem to be any problems with selfshadowing from the spotlight.

I also tried to change the shadowtype on the Point Light, both DualParaBoloidSinglePass, DualParaBoloid, and Cubemap has these awfull selfshadowing problems.

EDIT: ParaBoloid doesnt seem to be casting any shadows
#6
10/20/2009 (2:09 pm)
I had noticed the point light shadows looking like that in 1.0 as well.
#7
10/21/2009 (2:31 am)
Turn down the overDarkFactor on that light.

The 2000 was selected as the default to make the sun work fairly well with default settings, but it totally makes point and spot lights look like crap.

Bring it down to 100-300 or so.
#8
10/21/2009 (8:03 am)
@Tom, that certainly made it look a lot better, however it still seems like its splitting a lot, but it certainly look a ton better ;D
#9
10/21/2009 (10:33 pm)
Quote:however it still seems like its splitting a lot
Not sure what you mean by that.
#10
10/22/2009 (8:11 am)
@Tom, As shown on the picture with Gideon, the shadows on him is splitting or either seems like that the faces/poly's on the character has each an individual shadow.

Sorry im not quite sure how I otherwise would be able to explain it.
#11
10/22/2009 (8:15 am)
I think thats the shadow map granularity border which is reached much faster by point lights than by other lights due to the way they work.
#12
10/22/2009 (11:21 am)
Change the shadowType to DualParaboloid instead of DualParaboloidSinglePass. The single pass will never work in DX9 without causing splits, because a polygon cannot be drawn to both hemispheres at the same time (it's only possible using DirectX 10/11's geometry shaders).
#13
10/22/2009 (11:33 am)
@Manoel - So before DualParaboloidSinglePass would first work properly if I get DX10/11 shaders then?

And I take it as that T3D properly doesnt come with that, atleast of what I remember anyway heh :p
#14
10/26/2009 (5:38 pm)
It was an experiment, I don't know why it's the default method since it's only useful if you make sure you don't have shadow casters along the split plane. It was said that in the future T3D will get a DX11 render path, then the single pass will be useful.