# HG changeset patch # User Matti Hamalainen # Date 1560204535 -10800 # Node ID 1e7d80bfc8f18c7139b0203f08d8ffdb702a2421 # Parent 875e2b7b24dd0d77d53a286dc91546a34e92d2eb Rename some variables. diff -r 875e2b7b24dd -r 1e7d80bfc8f1 tools/lib64fmts.c --- a/tools/lib64fmts.c Mon Jun 10 23:58:03 2019 +0300 +++ b/tools/lib64fmts.c Tue Jun 11 01:08:55 2019 +0300 @@ -1224,19 +1224,18 @@ const DMC64Image *img, const int rasterX, const int rasterY) { DM_C64_GENERIC_SC_PIXEL_DEFS(img) - const int ry = rasterY / D64_SPR_HEIGHT_PX; - const int yd = rasterY % D64_SPR_HEIGHT_PX; - const int rx = rasterX / D64_SPR_WIDTH_PX; - const int xd = rasterX % D64_SPR_WIDTH_PX; - const int offs = (ry * 8 + rx) * D64_SPR_SIZE + (yd * D64_SPR_WIDTH_UT) + (xd / 8); + const int spr_y = rasterY / D64_SPR_HEIGHT_PX; + const int spr_yd = rasterY % D64_SPR_HEIGHT_PX; + const int spr_x = rasterX / D64_SPR_WIDTH_PX; + const int spr_xd = rasterX % D64_SPR_WIDTH_PX; + const int offs = (spr_y * 8 + spr_x) * D64_SPR_SIZE + (spr_yd * D64_SPR_WIDTH_UT) + (spr_xd / 8); const int mask = 1 << (7 - (rasterX & 7)); + int res; Uint8 color1, color2 = img->extraData[0].data[offs] & mask ? 0x0f : 0, color3 = img->extraData[0].data[offs + D64_SPR_SIZE * 155] & mask ? img->d022 : 0; - int res; - if ((res = dmC64GetGenericSCPixel(&color1, img, bmoffs, scroffs, vshift, 0, 0)) != DMERR_OK) return res;