From 8b960915b51b50a398bb73aaff0effb49e38e363 Mon Sep 17 00:00:00 2001 From: TimeServ Date: Tue, 28 Feb 2006 05:50:26 +0000 Subject: [PATCH] fix SW since Spike broke it git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@2036 fc73d0e0-1445-4013-8a0c-d673dee63da5 --- engine/sw/d_sprite.c | 8 ++++---- engine/sw/r_alias.c | 8 ++++---- engine/sw/sw_model.c | 2 +- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/engine/sw/d_sprite.c b/engine/sw/d_sprite.c index ddd75c52b..f6ef8d4ee 100644 --- a/engine/sw/d_sprite.c +++ b/engine/sw/d_sprite.c @@ -1070,18 +1070,18 @@ void D_DrawSprite (void) D_SpriteDrawSpans16 (sprite_spans); else //1 { - if (currententity->alpha > TRANS_LOWER_CAP) + if (currententity->shaderRGBAf[3] > TRANS_LOWER_CAP) { if (currententity->flags & Q2RF_ADDATIVE) { - D_SetTransLevel(currententity->alpha, BM_ADD); + D_SetTransLevel(currententity->shaderRGBAf[3], BM_ADD); D_SpriteDrawSpansAdditive (sprite_spans); } - else if (currententity->alpha > TRANS_UPPER_CAP) + else if (currententity->shaderRGBAf[3] > TRANS_UPPER_CAP) D_SpriteDrawSpans (sprite_spans); else { - D_SetTransLevel(currententity->alpha, BM_BLEND); + D_SetTransLevel(currententity->shaderRGBAf[3], BM_BLEND); D_SpriteDrawSpansTrans (sprite_spans); } } diff --git a/engine/sw/r_alias.c b/engine/sw/r_alias.c index bb64ca646..542de1dea 100644 --- a/engine/sw/r_alias.c +++ b/engine/sw/r_alias.c @@ -878,22 +878,22 @@ void R_AliasDrawModel (alight_t *plighting) if (r_pixbytes == 1) { - if (currententity->alpha < TRANS_LOWER_CAP) + if (currententity->shaderRGBAf[3] < TRANS_LOWER_CAP) return; - if (currententity->alpha > TRANS_UPPER_CAP) + if (currententity->shaderRGBAf[3] > TRANS_UPPER_CAP) { transbackfac = 0; } else { - D_SetTransLevel(currententity->alpha, BM_BLEND); + D_SetTransLevel(currententity->shaderRGBAf[3], BM_BLEND); transbackfac = 1; } } else { - transfactor = currententity->alpha*255; + transfactor = currententity->shaderRGBAf[3]*255; transbackfac = 255 - transfactor; } diff --git a/engine/sw/sw_model.c b/engine/sw/sw_model.c index 6f4f9ea69..00602a294 100644 --- a/engine/sw/sw_model.c +++ b/engine/sw/sw_model.c @@ -3066,7 +3066,7 @@ void SWMod_LoadAlias3Model (model_t *mod, void *buffer) #endif #ifdef AVAIL_PNGLIB if (!texture) - texture = ReadPNGFile(buffer, com_filesize, &width, &height); + texture = ReadPNGFile(buffer, com_filesize, &width, &height, pinskin->name); #endif if (!texture) texture = ReadPCXFile(buffer, com_filesize, &width, &height);