DTS Collision Mesh & Lighting
by Scott Doerrfeld · in Torque Game Engine · 11/30/2006 (10:46 am) · 1 replies
I have modeled a room with furniture for my TGE+TLK game. I have used DIF for the structural elements (walls, floors, ceilings). I have used DTS for the furniture/props. My goal is to get a room with some really incredible-looking lighting. Here are some questions:
1) I have noticed that the TLK lights that I place will affect a DTS model differently based on the model's collision mesh. For example, when a DTS model has a simple box collision mesh (one that matches the bounding box), the model receives light beautifully with shading and everything. By contrast, when a DTS model has a complex collision mesh (one that matches the shape more) it is relatively unaffected by my light placement. Is this correct? Should I use simple collision meshes to get better lighting?
2) The TLK lights appear to ALWAYS affect DTS objects dynamically. That is, even when I make a light 'Static' it affects the lighting on all my furniture dynamically as I move it around. Is it true that there is always some amount of dynamic lighting going on when there are DTS objects in a scene? Does adding more lights cause a performance hit?
3) Would it be better to model all the furniture as DIF objects? I guess I am worried about the "dynamic" lighting always going on with the DTS objects.
4) Also, I am wondering if scaling a DTS object in Torque will have much effect on the lighting.
1) I have noticed that the TLK lights that I place will affect a DTS model differently based on the model's collision mesh. For example, when a DTS model has a simple box collision mesh (one that matches the bounding box), the model receives light beautifully with shading and everything. By contrast, when a DTS model has a complex collision mesh (one that matches the shape more) it is relatively unaffected by my light placement. Is this correct? Should I use simple collision meshes to get better lighting?
2) The TLK lights appear to ALWAYS affect DTS objects dynamically. That is, even when I make a light 'Static' it affects the lighting on all my furniture dynamically as I move it around. Is it true that there is always some amount of dynamic lighting going on when there are DTS objects in a scene? Does adding more lights cause a performance hit?
3) Would it be better to model all the furniture as DIF objects? I guess I am worried about the "dynamic" lighting always going on with the DTS objects.
4) Also, I am wondering if scaling a DTS object in Torque will have much effect on the lighting.
About the author
Torque Owner John Kabus (BobTheCBuilder)
1 - the collision mesh shouldn't affect the main mesh's lighting. Make sure the collision mesh is a proper collision mesh (it's colliding and invisible), and the main mesh's normals are properly setup before exporting (if you're using Max try adding the smoothing modifier).
2 - DTS objects are always dynamically lit (see the Torque Lighting System TDN section for details), but you can disable Affects DTS Objects in the light editor. This eliminates dynamic lighting on DTS objects by the light, but allows them to still receive environmental lighting based on the interior or terrain lighting directly beneath the object.
3 - I would use DTS objects, because of modeling flexibility.
4 - yes, but theres a fix in this thread.
Let me know if this helps.