use max
This commit is contained in:
1 parent
9894198028
commit
6cdce0c95d
1 file changed
+1
-4
@@ -98,10 +98,7 @@ static void HWR_DrawColumnInCache(const column_t *patchcol, UINT8 *block, GLMipm
|
||||
position = 0;
|
||||
}
|
||||
|
||||
position = ((position * scale_y) + (FRACUNIT/2)) >> FRACBITS;
|
||||
|
||||
if (position < 0)
|
||||
position = 0;
|
||||
position = max(((position * scale_y) + (FRACUNIT/2)) >> FRACBITS, 0);
|
||||
|
||||
if (position + count >= pblockheight)
|
||||
count = pblockheight - position;
|
||||
|
||||
Reference in new issue
Block a user