comparison tools/lib64fmts.c @ 1834:69871828838c

Separate the format entries for "FBI Crew FLI Designer 1.1" and "FLI Designer 2" and enable writing of those formats.
author Matti Hamalainen <ccr@tnsp.org>
date Fri, 22 Jun 2018 16:48:04 +0300
parents 843d3a593f05
children d02514ceed91
comparison
equal deleted inserted replaced
1833:19d4f76e003d 1834:69871828838c
372 372
373 static int fmtProbeSaracenPaint(const DMGrowBuf *buf, const DMC64ImageFormat *fmt) 373 static int fmtProbeSaracenPaint(const DMGrowBuf *buf, const DMC64ImageFormat *fmt)
374 { 374 {
375 if ((buf->len == 10219 || buf->len == 10220) && 375 if ((buf->len == 10219 || buf->len == 10220) &&
376 dmCompareAddr16(buf, 0, fmt->addr)) 376 dmCompareAddr16(buf, 0, fmt->addr))
377 return DM_PROBE_SCORE_GOOD;
378
379 return DM_PROBE_SCORE_FALSE;
380 }
381
382
383 static int fmtProbeFLIDesigner(const DMGrowBuf *buf, const DMC64ImageFormat *fmt)
384 {
385 if (buf->len == fmt->size &&
386 (dmCompareAddr16(buf, 0, 0x3c00) || dmCompareAddr16(buf, 0, 0x3ff0)))
387 return DM_PROBE_SCORE_GOOD; 377 return DM_PROBE_SCORE_GOOD;
388 378
389 return DM_PROBE_SCORE_FALSE; 379 return DM_PROBE_SCORE_FALSE;
390 } 380 }
391 381
1143 { DO_COPY , DS_BITMAP_RAM , 0x0000, 0, 0, NULL, NULL }, 1133 { DO_COPY , DS_BITMAP_RAM , 0x0000, 0, 0, NULL, NULL },
1144 DEF_SCREEN_RAMS_8(0x2000, 0, 0x400), 1134 DEF_SCREEN_RAMS_8(0x2000, 0, 0x400),
1145 { DO_LAST , 0 , 0 , 0, 0, NULL, NULL }, 1135 { DO_LAST , 0 , 0 , 0, 0, NULL, NULL },
1146 } 1136 }
1147 }, 1137 },
1138
1139 { // #9: FLI Designer 1.x & 2.0
1140 D64_FMT_MC | D64_FMT_FLI,
1141 C64_SCR_WIDTH / 2, C64_SCR_HEIGHT,
1142 C64_SCR_CH_WIDTH , C64_SCR_CH_HEIGHT,
1143 NULL, NULL,
1144 fmtGetPixelFLIDesigner,
1145 {
1146 { DO_COPY , DS_COLOR_RAM , 0x0000, 0, 0, NULL, NULL },
1147 DEF_SCREEN_RAMS_8(0x0400, 0, 0x400),
1148 { DO_COPY , DS_BITMAP_RAM , 0x2400, 0, 0, NULL, NULL },
1149 { DO_LAST , 0 , 0 , 0, 0, NULL, NULL },
1150 }
1151 },
1148 }; 1152 };
1149 1153
1150 1154
1151 // 1155 //
1152 // Array with data for supported formats 1156 // Array with data for supported formats
1583 fmtDecodeBlackMailFLIPacked, fmtEncodeBlackMailFLIPacked, 1587 fmtDecodeBlackMailFLIPacked, fmtEncodeBlackMailFLIPacked,
1584 { }, &dmC64CommonFormats[1] 1588 { }, &dmC64CommonFormats[1]
1585 }, 1589 },
1586 1590
1587 { 1591 {
1588 "fli", "FLI Designer (unpacked)", 0, 17409, DM_FMT_RDWR, 1592 "fd2", "FBI Crew FLI Designer 1.1 (unpacked)", 0x3c00, 17409, DM_FMT_RDWR,
1589 fmtProbeFLIDesigner, 1593 NULL,
1590 NULL, NULL, 1594 NULL, NULL,
1591 { 1595 { }, &dmC64CommonFormats[9]
1592 D64_FMT_MC | D64_FMT_FLI, 1596 },
1593 C64_SCR_WIDTH / 2, C64_SCR_HEIGHT, 1597
1594 C64_SCR_CH_WIDTH , C64_SCR_CH_HEIGHT, 1598 {
1595 NULL, NULL, 1599 "fli", "FLI Designer 2 (unpacked)", 0x3ff0, 17409, DM_FMT_RDWR,
1596 fmtGetPixelFLIDesigner, 1600 NULL,
1597 { 1601 NULL, NULL,
1598 { DO_COPY , DS_COLOR_RAM , 0x0000, 0, 0, NULL, NULL }, 1602 { }, &dmC64CommonFormats[9]
1599 DEF_SCREEN_RAMS_8(0x0400, 0, 0x400),
1600 { DO_COPY , DS_BITMAP_RAM , 0x2400, 0, 0, NULL, NULL },
1601 { DO_LAST , 0 , 0 , 0, 0, NULL, NULL },
1602 }
1603 },
1604 NULL
1605 }, 1603 },
1606 1604
1607 { 1605 {
1608 "eci", "ECI Graphic Editor 1.0 (unpacked)", 0x4000, 32770, DM_FMT_RDWR, 1606 "eci", "ECI Graphic Editor 1.0 (unpacked)", 0x4000, 32770, DM_FMT_RDWR,
1609 NULL, 1607 NULL,