nw, refinement of previous fix

This commit is contained in:
therealmogminer@gmail.com 2015-06-26 15:37:46 +02:00
parent 03eaba0e31
commit 0c40d654b8
2 changed files with 2 additions and 2 deletions

View File

@ -58,8 +58,8 @@ void rgbaint_t::scale_add_and_clamp(const rgbaint_t& scale, const rgbaint_t& oth
void rgbaint_t::scale_imm_add_and_clamp(const INT32 scale, const rgbaint_t& other) void rgbaint_t::scale_imm_add_and_clamp(const INT32 scale, const rgbaint_t& other)
{ {
mul_imm(scale); mul_imm(scale);
add(other);
sra(8); sra(8);
add(other);
max(0); max(0);
min(255); min(255);
} }

View File

@ -3211,7 +3211,7 @@ INLINE void applyFogging(voodoo_state *v, UINT32 fogModeReg, UINT32 fbzCpReg, I
/* if fog_mult is 0, we add this to the original color */ /* if fog_mult is 0, we add this to the original color */
if (FOGMODE_FOG_MULT(fogModeReg) == 0) if (FOGMODE_FOG_MULT(fogModeReg) == 0)
{ {
tmpA.scale_imm_add_and_clamp((INT16) fogblend, tmpB); tmpA.scale_imm_add_and_clamp((INT32) fogblend, tmpB);
//color += fog; //color += fog;
//(RR) += fr; //(RR) += fr;
//(GG) += fg; //(GG) += fg;