mirror of
https://git.code.sf.net/p/quake/newtree
synced 2024-11-21 19:51:18 +00:00
don't try to add contrast to the blend if we don't yet know what contrast is
This commit is contained in:
parent
aed7b1c08d
commit
0bca15c502
1 changed files with 9 additions and 6 deletions
|
@ -87,7 +87,9 @@ V_CalcBlend (void)
|
|||
a = 1.0 - a3;
|
||||
}
|
||||
|
||||
if ((a2 = 1 - bound (0.0, contrast->value, 1.0)) < 0.999) { // add contrast
|
||||
if (contrast) {
|
||||
if ((a2 = 1 - bound (0.0, contrast->value, 1.0)) < 0.999) {
|
||||
// add contrast
|
||||
r += (128 - r) * a2;
|
||||
g += (128 - g) * a2;
|
||||
b += (128 - b) * a2;
|
||||
|
@ -95,6 +97,7 @@ V_CalcBlend (void)
|
|||
a3 = (1.0 - a) * (1.0 - a2);
|
||||
a = 1.0 - a3;
|
||||
}
|
||||
}
|
||||
|
||||
// LordHavoc: saturate color
|
||||
if (a) {
|
||||
|
|
Loading…
Reference in a new issue