From 2313517279e92053fa74c58c99f92d641dea15af Mon Sep 17 00:00:00 2001 From: TimeServ Date: Wed, 15 Mar 2006 10:04:41 +0000 Subject: [PATCH] fix spr32 loading for sw renderer git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@2119 fc73d0e0-1445-4013-8a0c-d673dee63da5 --- engine/sw/sw_model.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/engine/sw/sw_model.c b/engine/sw/sw_model.c index d60cdabc2..148ef7c25 100644 --- a/engine/sw/sw_model.c +++ b/engine/sw/sw_model.c @@ -3572,6 +3572,7 @@ void * SWMod_LoadSpriteFrame (void * pin, mspriteframe_t **ppframe, int version) else ppixout[i] = GetPaletteNoFB(ppixin[i*4], ppixin[i*4+1], ppixin[i*4+2]); } + size *= 4; } else Q_memcpy (&pspriteframe->pixels[0], (qbyte *)(pinframe + 1), size); @@ -3593,6 +3594,7 @@ void * SWMod_LoadSpriteFrame (void * pin, mspriteframe_t **ppframe, int version) else p16out[i] = ((ppixin[i*4]*32/255)<<10) + ((ppixin[i*4+1]*32/255)<<5) + ((ppixin[i*4+2]*32/255)<<0); } + size *= 4; } else { @@ -3618,6 +3620,8 @@ void * SWMod_LoadSpriteFrame (void * pin, mspriteframe_t **ppframe, int version) for (i=0 ; i