fixed the GL3 debug uniform location check

it would incorrectly trigger with r_alphaToCoverage 1 and r_msaa 0
This commit is contained in:
myT 2020-10-08 04:19:20 +02:00
parent 633c5bd13c
commit 2aaf17b061

View file

@ -1986,11 +1986,12 @@ static void Init()
{
pipeline->uniformLocations[i] = glGetUniformLocation(pipeline->program.program, pipeline->uniformNames[i]);
#if defined(_DEBUG)
if(!(r_dither->integer == 0 && p == PID_GENERIC && i == GU_GAMMA_BRIGHT_NOISE_SEED) &&
!(r_alphaToCoverage->integer == 0 && p == PID_GENERIC && i == GU_A2C_ALPHA_BOOST))
if((p == PID_GENERIC && i == GU_GAMMA_BRIGHT_NOISE_SEED && r_dither->integer == 0) ||
(p == PID_GENERIC && i == GU_A2C_ALPHA_BOOST && !glInfo.alphaToCoverageSupport))
{
assert(pipeline->uniformLocations[i] != -1);
continue;
}
assert(pipeline->uniformLocations[i] != -1);
#endif
}
}