X-Git-Url: http://git.mutantstargoat.com/user/nuclear/?p=dosdemo;a=blobdiff_plain;f=src%2Fscr%2Ftunnel.c;h=5411e53683cd2edd717dbfb783136f4f39f8933a;hp=9071b74ea4a1cba12010c6bcd4c86c88bfff6da3;hb=e8b26db00c934d141f16652cb8dcbeae23b17e48;hpb=b0159ee29e4e616e4506d3cea5aee6ecc97aa93a diff --git a/src/scr/tunnel.c b/src/scr/tunnel.c index 9071b74..5411e53 100644 --- a/src/scr/tunnel.c +++ b/src/scr/tunnel.c @@ -62,10 +62,10 @@ static int init(void) int i, j, n; unsigned int *tmap; unsigned char *fog; - float aspect = (float)fb_width / (float)fb_height; + float aspect = (float)FB_WIDTH / (float)FB_HEIGHT; - xsz = fb_width; - ysz = fb_height; + xsz = FB_WIDTH; + ysz = FB_HEIGHT; vxsz = xsz * VSCALE; vysz = ysz * VSCALE; @@ -185,7 +185,7 @@ static void draw(void) int rest_lines = num_lines - draw_lines; draw_tunnel_range(fb_pixels, xoffs, yoffs, starty, draw_lines, time_msec); if(rest_lines) { - memset(fb_pixels + resty * fb_width, 0, rest_lines * fb_width * 2); + memset(fb_pixels + resty * FB_WIDTH, 0, rest_lines * FB_WIDTH * 2); } } @@ -221,7 +221,7 @@ static void draw_tunnel_range(unsigned short *pix, int xoffs, int yoffs, int sta unsigned char *fog = tunnel_fog + (starty + yoffs) * vxsz + xoffs; long toffs = tm / 8; - unsigned int *pixels = (unsigned int*)pix + starty * (fb_width >> 1); + unsigned int *pixels = (unsigned int*)pix + starty * (FB_WIDTH >> 1); for(i=0; i>1); j++) {