# HG changeset patch # User Matti Hamalainen # Date 1528729740 -10800 # Node ID 027fb7313d857b0d4cfb2a32da53a156d21061b9 # Parent 8014e4cbebfe64e13832ff3cda1930331c97ed52 Add a format flag for marking formats that have broken/incomplete support and use it. diff -r 8014e4cbebfe -r 027fb7313d85 tools/64vw.c --- a/tools/64vw.c Mon Jun 11 17:58:44 2018 +0300 +++ b/tools/64vw.c Mon Jun 11 18:09:00 2018 +0300 @@ -59,10 +59,11 @@ { const DMC64ImageFormat *fmt = &dmC64ImageFormats[i]; char buf[64]; - printf("%-6s| %-15s | %s\n", + printf("%-6s| %-15s | %s%s\n", fmt->fext, dmC64GetImageTypeString(buf, sizeof(buf), fmt->type, FALSE), - fmt->name); + fmt->name, + fmt->flags & DM_FMT_BROKEN ? " [BROKEN]" : ""); } printf("%d formats supported.\n", ndmC64ImageFormats); } diff -r 8014e4cbebfe -r 027fb7313d85 tools/gfxconv.c --- a/tools/gfxconv.c Mon Jun 11 17:58:44 2018 +0300 +++ b/tools/gfxconv.c Mon Jun 11 18:09:00 2018 +0300 @@ -172,12 +172,13 @@ { const DMC64ImageFormat *fmt = &dmC64ImageFormats[i]; char buf[64]; - printf("%-6s| %c%c | %-15s | %s\n", + printf("%-6s| %c%c | %-15s | %s%s\n", fmt->fext, (fmt->flags & DM_FMT_RD) ? 'R' : ' ', (fmt->flags & DM_FMT_WR) ? 'W' : ' ', dmC64GetImageTypeString(buf, sizeof(buf), fmt->type, FALSE), - fmt->name); + fmt->name, + fmt->flags & DM_FMT_BROKEN ? " [BROKEN]" : ""); } printf("%d formats supported.\n", ndmC64ImageFormats); } diff -r 8014e4cbebfe -r 027fb7313d85 tools/lib64fmts.c --- a/tools/lib64fmts.c Mon Jun 11 17:58:44 2018 +0300 +++ b/tools/lib64fmts.c Mon Jun 11 18:09:00 2018 +0300 @@ -1094,7 +1094,7 @@ }, { - D64_FMT_MC, "mil", "MIL (unpacked)", 0x18dc, 10022, DM_FMT_RDWR, + D64_FMT_MC, "mil", "MIL (unpacked)", 0x18dc, 10022, DM_FMT_RDWR | DM_FMT_BROKEN, C64_SCR_WIDTH / 2, C64_SCR_HEIGHT, C64_SCR_CH_WIDTH , C64_SCR_CH_HEIGHT, NULL, @@ -1236,7 +1236,7 @@ }, { - D64_FMT_MC | D64_FMT_FLI, "bfli", "Big FLI (unpacked) [BROKEN]", 0x3bff, 33795, DM_FMT_RD, + D64_FMT_MC | D64_FMT_FLI, "bfli", "Big FLI (unpacked)", 0x3bff, 33795, DM_FMT_RD | DM_FMT_BROKEN, C64_SCR_WIDTH / 2, C64_SCR_HEIGHT * 2, C64_SCR_CH_WIDTH , C64_SCR_CH_HEIGHT, NULL, diff -r 8014e4cbebfe -r 027fb7313d85 tools/libgfx.h --- a/tools/libgfx.h Mon Jun 11 17:58:44 2018 +0300 +++ b/tools/libgfx.h Mon Jun 11 18:09:00 2018 +0300 @@ -59,9 +59,10 @@ // Flags for readability/writeability of formats enum { - DM_FMT_WR = 0x0001, - DM_FMT_RD = 0x0002, - DM_FMT_RDWR = (DM_FMT_RD | DM_FMT_WR), + DM_FMT_WR = 0x0001, // Format can be written + DM_FMT_RD = 0x0002, // Format can be read + DM_FMT_RDWR = (DM_FMT_RD | DM_FMT_WR), // Read and write support + DM_FMT_BROKEN = 0x1000, // Support is broken/incomplete };