mirror of
https://github.com/w23/xash3d-fwgs
synced 2024-11-19 16:37:07 +01:00
ref_soft: Bound texcoords again, disable drawing spans on FloorDivMod overflow
This commit is contained in:
parent
1c49d76fb7
commit
0c6c0003b1
@ -105,6 +105,11 @@ byte *skinstart;
|
||||
|
||||
void (*d_pdrawspans)(spanpackage_t *pspanpackage);
|
||||
|
||||
void R_PolysetStub (spanpackage_t *pspanpackage)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void R_PolysetDrawSpans8_33 (spanpackage_t *pspanpackage);
|
||||
void R_PolysetDrawSpans8_66 (spanpackage_t *pspanpackage);
|
||||
void R_PolysetDrawSpans8_Opaque (spanpackage_t *pspanpackage);
|
||||
@ -308,12 +313,16 @@ void FloorDivMod (float numer, float denom, int *quotient,
|
||||
}
|
||||
if( q > INT_MAX / 2 || q < INT_MIN / 2 )
|
||||
{
|
||||
int i;
|
||||
d_pdrawspans = R_PolysetStub;
|
||||
gEngfuncs.Con_Printf( S_ERROR "FloorDivMod: q overflow!\n" );
|
||||
q = 1;
|
||||
}
|
||||
|
||||
if( r > INT_MAX / 2 || r < INT_MIN / 2 )
|
||||
{
|
||||
int i;
|
||||
d_pdrawspans = R_PolysetStub;
|
||||
gEngfuncs.Con_Printf( S_ERROR "FloorDivMod: r overflow!\n");
|
||||
r = 1;
|
||||
}
|
||||
|
@ -245,8 +245,8 @@ void TriTexCoord2f( volatile float u, volatile float v )
|
||||
v1 = v1 - 1;
|
||||
|
||||
|
||||
s = r_affinetridesc.skinwidth * bound(0,u1,1);
|
||||
t = r_affinetridesc.skinheight * bound(0,v1,1);
|
||||
s = r_affinetridesc.skinwidth * bound(0.01,u1,0.99);
|
||||
t = r_affinetridesc.skinheight * bound(0.01,v1,0.99);
|
||||
}
|
||||
|
||||
/*
|
||||
|
Loading…
Reference in New Issue
Block a user