[sw] Clean up use of r_rectdesc

I have no idea why the struct even had a local vrect that was used for
temporary storage.
This commit is contained in:
Bill Currie 2022-03-07 16:57:22 +09:00
parent ea2fd32228
commit ea223f6312

View file

@ -49,7 +49,6 @@
#include "vid_internal.h" #include "vid_internal.h"
typedef struct { typedef struct {
vrect_t rect;
int width; int width;
int height; int height;
byte *ptexbytes; byte *ptexbytes;
@ -699,19 +698,14 @@ Draw_TileClear (int x, int y, int w, int h)
CLIP (x, y, w, h, (int) vid.width, (int) vid.height); CLIP (x, y, w, h, (int) vid.width, (int) vid.height);
r_rectdesc.rect.x = x; vr.y = y;
r_rectdesc.rect.y = y; height = h;
r_rectdesc.rect.width = w;
r_rectdesc.rect.height = h;
vr.y = r_rectdesc.rect.y;
height = r_rectdesc.rect.height;
tileoffsety = vr.y % r_rectdesc.height; tileoffsety = vr.y % r_rectdesc.height;
while (height > 0) { while (height > 0) {
vr.x = r_rectdesc.rect.x; vr.x = x;
width = r_rectdesc.rect.width; width = w;
if (tileoffsety != 0) if (tileoffsety != 0)
vr.height = r_rectdesc.height - tileoffsety; vr.height = r_rectdesc.height - tileoffsety;