mirror of
https://github.com/ZDoom/raze-gles.git
synced 2025-01-12 03:00:38 +00:00
Fix tints with negative shades in r_usenewshading 4.
Patch from Fox. git-svn-id: https://svn.eduke32.com/eduke32@6561 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
583dc0f47a
commit
4c095c954d
1 changed files with 1 additions and 3 deletions
|
@ -81,9 +81,7 @@ static inline float getshadefactor(int32_t const shade)
|
|||
return 1.f;
|
||||
|
||||
if (r_usenewshading == 4)
|
||||
{
|
||||
return 1.f - (shade * shadescale / frealmaxshade);
|
||||
}
|
||||
return max(min(1.f - (shade * shadescale / frealmaxshade), 1.f), 0.f);
|
||||
|
||||
float const shadebound = (float)((shadescale_unbounded || shade>=numshades) ? numshades : numshades-1);
|
||||
float const scaled_shade = (float)shade*shadescale;
|
||||
|
|
Loading…
Reference in a new issue