summaryrefslogtreecommitdiff
path: root/indra/newview/app_settings/shaders/class1/windlight
diff options
context:
space:
mode:
authorGeenz <geenz@geenzo.com>2019-04-10 02:11:07 -0700
committerGeenz <geenz@geenzo.com>2019-04-10 02:11:07 -0700
commit08812cbe060e62cb8b61e91bc2f878a74a0015e5 (patch)
tree50e6cd88845b96a7b457bc3f81c56f4d17a114b8 /indra/newview/app_settings/shaders/class1/windlight
parentdcd8117b85f45886f78a1a2e9756cb1709d6572a (diff)
Separate out vertex program objects from fragment program objects and use it.
Given that mShaderObjects only ever expects one copy of a given shader object (leading to lots of "shaderV" and "shaderF"), it made having utility shaders a bit more difficult to incorporate. This change makes sure the two are separated. Using this over a multimap largely for readibility. Also, actually, you know, use this functionality. --HG-- branch : OPEN-340
Diffstat (limited to 'indra/newview/app_settings/shaders/class1/windlight')
-rw-r--r--indra/newview/app_settings/shaders/class1/windlight/atmosphericsFuncs.glsl6
1 files changed, 3 insertions, 3 deletions
diff --git a/indra/newview/app_settings/shaders/class1/windlight/atmosphericsFuncs.glsl b/indra/newview/app_settings/shaders/class1/windlight/atmosphericsFuncs.glsl
index 2854fb8139..a099083883 100644
--- a/indra/newview/app_settings/shaders/class1/windlight/atmosphericsFuncs.glsl
+++ b/indra/newview/app_settings/shaders/class1/windlight/atmosphericsFuncs.glsl
@@ -77,7 +77,7 @@ void calcAtmosphericVars(vec3 inPositionEye, float ambFactor, out vec3 sunlit, o
temp2.x = dot(Pn, tmpLightnorm.xyz);
temp2.x = 1. - temp2.x;
//temp2.x is 0 at the sun and increases away from sun
- temp2.x = max(temp2.x, .03); //was glow.y
+ temp2.x = max(temp2.x, .001); //was glow.y
//set a minimum "angle" (smaller glow.y allows tighter, brighter hotspot)
temp2.x *= glow.x;
//higher glow.x gives dimmer glow (because next step is 1 / "angle")
@@ -109,8 +109,8 @@ void calcAtmosphericVars(vec3 inPositionEye, float ambFactor, out vec3 sunlit, o
+ tmpAmbient));
//brightness of surface both sunlight and ambient
- sunlit = vec3(sunlight.rgb);
- amblit = vec3(tmpAmbient * .25);
+ sunlit = sunlight.rgb;
+ amblit = tmpAmbient.rgb * .25;
additive = normalize(additive);
additive *= vec3(1.0 - exp(-temp2.z * distance_multiplier)) * 0.5;
} \ No newline at end of file