Game Development Community

Lighting DTS Models

by Tim Dix (Raverix) · in Torque Game Engine Advanced · 11/29/2004 (8:35 pm) · 12 replies

It looks like, at least on my card, that even with all the mission lighting down to 0... (both ambient and direct), that DTS models are still lit as if full intensity lights? Anyone able to confirm this for me?

Both screenshots taken with ambient light = 0 0 0 0

Sun Color 1.0 1.0 1.0 1.0
Sun Color 0.1 0.1 0.1 0.1

I'm usin' a Radeon 9800xt

#1
11/30/2004 (10:13 am)
What you're seeing there is the cubemap reflection, specular, and eye glow. Each of these are added to the lighting in the scene, so even if the lights are black, they will still show up.

To make the effects darker, you can:

- Darken the cubemap (or just lower the alpha channel of the textures using the cubemap)
- Make the specular color darker in the material
#2
11/30/2004 (12:32 pm)
Hm.. i've noticed this too.. When you run into shadows and everything with the orc, nothing changes. I know you just said how to make it darker Brian, but will it later be in TSE so it'll get darker normally as it should? I sure hope so.. :/
#3
11/30/2004 (1:26 pm)
Right now the objects can't "go into shadow". Yes, this will be addressed on a later milestone when shadows are implemented.
#4
12/01/2004 (11:00 am)
Ok, well then what about the Non-shader enhanced DTS in the background of the ship?
#6
12/01/2004 (1:01 pm)
I expeirenced that too.. You need to set a material in materials.cs.. don't know why though.. But setup a material mapping for the orc and in its custom material just have it point off to its own material, just don't apply any shaders or effects.
#7
12/01/2004 (2:48 pm)
The reason is because it's much more efficient to light models with shaders. Trying to support the same type of lighting between fixed function and shaders would be a pain in the ass and muck up some clean code as well.

It renders unmapped textures as unlit textures for now, I'm thinking of setting it up to render an "error" texture when something isn't mapped. Everything in your scene should be mapped to a material.
#8
12/01/2004 (5:19 pm)
Alright, then I'm a bit confused... does this mean that there is no method to adjust the global lighting to uniformly light up my different models?
#9
12/01/2004 (8:15 pm)
Use a global var to set it in script?
#10
12/02/2004 (1:49 pm)
Right now the models only light from the sun. That's global, you can set it in the editor.
#11
12/03/2004 (4:17 am)
In TGE I could control the direct sunlight as well as the ambient... in TSE, it looks like only the ambient lighting works. Both of these shots were taken with the sun behind the camera....
1 1 1 1 Light Color
0 0 0 0 Light Color

Both of these were taken with the sun behind the orc. They've got the same lighting minus just a little bit of specular action goin' on.

Sun Color 1.0 1.0 1.0 1.0
Sun Color 0.1 0.1 0.1 0.1
#12
12/06/2004 (10:22 am)
How about in the show tool - does the Orc light OK there?