From 511b73baf93e4e1661c95c7bb717a087a08aaf55 Mon Sep 17 00:00:00 2001 From: Denis Pauk Date: Sun, 11 Mar 2018 13:03:06 +0200 Subject: [PATCH] Particle fixes from q2dos and kmquake Authors: maraakate Knightmare --- src/client/refresh/soft/sw_misc.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/src/client/refresh/soft/sw_misc.c b/src/client/refresh/soft/sw_misc.c index e5e9631a..db17a638 100644 --- a/src/client/refresh/soft/sw_misc.c +++ b/src/client/refresh/soft/sw_misc.c @@ -61,10 +61,22 @@ D_ViewChanged (void) d_pix_min = 1; d_pix_max = (int)((float)r_refdef.vrect.width / (320.0 / 4.0) + 0.5); - d_pix_shift = 8 - (int)((float)r_refdef.vrect.width / 320.0 + 0.5); if (d_pix_max < 1) d_pix_max = 1; + if(r_newrefdef.width >= 800) + { + d_pix_shift = 16 - (int)((float)r_refdef.vrect.width / 320.0 + 0.5); + } + else if(r_newrefdef.width >= 640) + { + d_pix_shift = 12 - (int)((float)r_refdef.vrect.width / 320.0 + 0.5); + } + else + { + d_pix_shift = 8 - (int)((float)r_refdef.vrect.width / 320.0 + 0.5); + } + d_vrectx = r_refdef.vrect.x; d_vrecty = r_refdef.vrect.y; d_vrectright_particle = r_refdef.vrectright - d_pix_max;