Game Development Community

1.0.2 Still no Atlas Shadows for statics and interiors?

by James Brad Barnette · in Torque Game Engine Advanced · 08/11/2007 (1:29 pm) · 5 replies

Ok maybe I'm doing something wrong here. I can't get statics or interiors to have shadows on atlas terrain.

I though static shadows were fixed this time around?

I would think that these would be pretty high on the priority list no?

Does the problem lie in that that the editor cannot create the shadow information for atlast terrain. Or is it that the Atlas cannot have the texture added becsue it is merged into the file?

If the latter is the case perhaps the information for the static and interior shadows could be stored in a seperate file on disk somewhere and then use it as a multiplier against the color in the atlas shader. this should produce the right result. Atleast in 3D grpahics that is how I would do it but I have know idea how it would be implemented in code.

anyway I hope we can figer out a solution sometime soon.

#1
08/11/2007 (10:51 pm)
I haven't tested with statics lights, but I did with interiors and they still don't work. I just don't see atlas as being very usable without shadows. =(
#2
08/12/2007 (7:33 am)
Yeah, Surly there is something we can jsut do ourselves to sort this out since it doesn't seem to be very high on the GG tree. There are a few techniques for doing shadows in the Nvidia SDK. pehaps one of these can be used to add the shadows in at rendertime.
#3
08/21/2007 (12:19 pm)
Well, you could adapt the objectBasedProjector and objectShadows classes to work with statics and interiors. Build the geometry together in a buffer, do some texture atlas research and then use as few total textures as necessary with the geometry broken into large chunks of a few thousand polys each and then rarely if ever update the shadowtexture.

Not exactly a performance friendly approach.

With other solutions, how do you make it work on shader model 2 instead of just 3. I can see tons of ways to do it on high end shader model 3 cards (even more on shader model 4). But how do you make it work.

Furthermore, if you're terrain dependent how do you manage the detail of the terrain? How do you keep your decal geometry from being inaccurate at a medium to extended viewing distance?

It's not trivial, or it would there already.
#4
08/21/2007 (1:23 pm)
Here's a place to start doing some probing:

/// @name Shadow Detail Constants
///
/// The generic shadow level is the shadow detail at which
/// a generic shadow is drawn (a disk) rather than a generated
/// shadow. The no shadow level is the shadow level at which
/// no shadow is drawn. (Shadow level goes from 0 to 1,
/// higher numbers result in more detailed shadows).
///
/// @{

#define Player_GenericShadowLevel 0.4f
#define Player_NoShadowLevel 0.01f
#define Vehicle_GenericShadowLevel 0.7f
#define Vehicle_NoShadowLevel 0.2f
#define Item_GenericShadowLevel 0.4f
#define Item_NoShadowLevel 0.01f
#define StaticShape_GenericShadowLevel 2.0f
#define StaticShape_NoShadowLevel 2.0f


in ShapeBase.h
#5
08/21/2007 (8:44 pm)
I would have no idea what I was looking at man. We have a thread going and GG seems to be taking the TGEA issues a little more seriously so we'll see.