R_DrawParticles: exit early if there is nothing to draw, avoid a useless glBegin() glEnd() pair.

This fixes a weird bug on Windows/AMD, where under some conditions, the
world would be drawn totally corrupted. Conditions for the bug were:
- gl_clear 0
- gamma 1
- glsl alias code in use
- status bar hidden, or, scr_sbaralpha 1
- map e1m1, look around the start position

git-svn-id: svn://svn.code.sf.net/p/quakespasm/code/trunk/quakespasm@1202 af15c1b1-3010-417e-b628-4374ebc0bcbd
This commit is contained in:
Eric Wasylishen 2015-04-16 23:57:39 +00:00
parent fe95edf20f
commit 44b7d3a4fc
1 changed files with 4 additions and 0 deletions

View File

@ -835,6 +835,10 @@ void R_DrawParticles (void)
if (!r_particles.value) if (!r_particles.value)
return; return;
//ericw -- avoid empty glBegin(),glEnd() pair below; causes issues on AMD
if (!active_particles)
return;
VectorScale (vup, 1.5, up); VectorScale (vup, 1.5, up);
VectorScale (vright, 1.5, right); VectorScale (vright, 1.5, right);