How do control light_environment brightness?

Started by jrocket, June 23, 2015, 10:12:33 PM

Previous topic - Next topic

jrocket

In Source, the there is a brightness property in the light_environment that takes 4 values- the first 3 is the rgb value of the light, and the last is the brightness of the light. How do I set this last value in 3ds max? It's always coming out as "20" and the color slider only lets me select the color of the light. I noticed that there is a brightness scale, but that only seems to set the HDR Brightness scale.

wallworm

Hello! And Welcome to WW :) I'm really happy to see you experimenting.

Lights in WW are controlled with these parameters:

Color + Multiplier.

The multiplier value for lights controls the brightness.

One more thing:

The VMF Exporter dialog has two light multipliers that are global multipliers of the lights that export. For Omni and Spot lights, the light multiplier is applied to each light's multiplier. For Sun, Direct and Daylight (that export as light_environment) the env mult is used.

So, if you have a spot light with a multiplier of 2 and a Omni with a multiplier of 1.2 and your VMF exporter dialog has a light multiplier of 200, then the spot will have a brightness of 400 and the Omni will be a brightness of 240.

And for a direct light with a multiplier of 1 and an env mult of 20 will be 20. You can either change the env multiplier in the VMF export dialog or the multiplier in the light.

Explaining why it was done like this is too much for tonight. But the main benefit you have with a global VMF exporter multiplier is that you can globally increase/decrease lighting in your lights with the light multiplier. The env multiplier has less diverse utility because there should generally only be one environment light, but it was prudent to make this a separate value from the general lights.

Hopefully this helps explain it.

jrocket

Okay that makes sense. The scale of light values are also different- A value of 10 light units in max is quite high, while in source that's barely anything. I think my confusion came from the presence of the brightness color picker in the entity properties.

wallworm

Yes, the fact that Source's light scale is not identical to Max is actually one of the reasons I added the multiplier. Once you find a value that works best for you, stick with that. It's been a long time since I did actual comparisons, but my own past tests led me to conclude that it may be a 200:1 ratio, which may be why I chose 200 as the default multiplier for lights in the VMF Exporter. I cannot recall off the top of my head why I chose a 20:1 default for environment lights.

In terms of the color picker in the entity rollout, when you change that value, it automatically updates the color of the light. I actually chose to exclude the brightness value in that rollout because I felt it was important for people to understand that multiplier value in the Max light itself, which is a native value in Max; that and by the time I added full entity support in Wall Worm, there was already a long history of the light's multiplier X the VMF exporter dialog in scenes I've worked on. So this is also another reason behind the current light brightness methods in WW.

It takes a slight adjustment, but it's pretty simple once you understand the relationships.

wallworm

I will experiment with this momentarily. I've not had lights come out with incorrect rotations that I know of. I'll either find an explanation or a fix shortly.

wallworm

There is indeed a bug. The temporary fix is to turn on the Targeted option in the light. I will make an actual fix for this probably today.

SMF spam blocked by CleanTalk