A Volume Light Behavior is a light behavior whose color varies depending on your position relative to the light's location and to the volume's geometry. The volume surrounds the light. Within the volume, the light has the primary color; outside the volume it takes the secondary color.
if:
eye_distance_from_light = the distance of the viewing
position from the light
volume_distance_from_light = the distance between the light
and the volume boundary along
the same vector
then:
final_intensity =
minimum_color_intensity +
(((volume_distance_from_light -
eye_distance_from_light) /
volume_distance_from_light) *
(full_intensity -
minimum_color_intensity))
If my position from the light is a distance of 500m
along a vector from the light to a corner of the volume then
the final_intensity is 0.614.
0.0 + (((1414.2 - 500.0) / 1414.2) * (0.95 - 0.0))
If my position from the light is 3000m then the final_intensity is 1.0 (using the secondary color) because I am outside the volume and there is a secondary color on the Volume Light Behavior.
If my distance from the light is a distance of 100m then the final_intensity is 1.0, since my position is inside the volume and the use_full_intensity flag is set to true.
If my distance from the light is a distance of 0 units then the final_intensity is 1.0 since my position is inside the volume and the use_full_intensity flag is set to true.
| SE_BOOLEAN | use_full_intensity; | (notes) |
|---|---|---|
| SE_FLOAT64 | minimum_color_intensity; | (notes) |
volume center
volume shape
To locate and orient the volume within the currently scoped 'world' spatial reference frame
A flag, if true indicates that the full intensity of the light is shown within the volume. If this flag is false, then the intensity of the light decreases (towards the minimum_color_intensity value) as you move away from the light. The intensity of the light would reach the minimum_color_intensity value when you reach the boundary of the volume.
This value (between 0.0 and 1.0) is used in conjunction with the intensity value of the primary color. If the primary color is a <Color Index> then the full intensity will be the intensity attribute of that class. If the primary color is an <Inline Color> then the full intensity is 1.0. If your location is the same as that of the light then you receive the full (intensity) value. As you move away from the light (but are still within the volume), the intensity decreases toward the minimum_color_intensity value (unless the use_full_intensity flag is TRUE). Once you get outside the volume, the intensity is that of the minimum_color_intensity value. If the minimum_color_intensity value is 0.0 and you're outside the volume, the secondary color will be seen. If no secondary color is used then nothing will be seen.