Remove unplanned TODO comments in src/gfx/pal_spec.cpp

ACT palette files support a transparent color index, but RGBGFX
cannot apply *one* such transparent color; it would need every
palette's first color to be transparent. Also ACT files tend to
say the first color is transparent anyway, which the user may
not have intended.

ACO palette files can specify version 2 color data, but it's
required to come after version 1 data, and the colors themselves
already exist in the earlier v1 data; v2 just adds UTF-16 names.

Thus, we do not need to be handling these data in those formats.
This commit is contained in:
Rangi42
2025-05-02 21:29:14 -04:00
parent 122d91509f
commit bdac0ce053

View File

@@ -413,7 +413,6 @@ static void parseACTFile(std::filebuf &file) {
uint16_t nbColors = 256; uint16_t nbColors = 256;
if (len == 772) { if (len == 772) {
nbColors = readBE<uint16_t>(&buf[768]); nbColors = readBE<uint16_t>(&buf[768]);
// TODO: apparently there is a "transparent color index"? What?
if (nbColors > 256 || nbColors == 0) { if (nbColors > 256 || nbColors == 0) {
error("Invalid number of colors in ACT file (%" PRIu16 ")", nbColors); error("Invalid number of colors in ACT file (%" PRIu16 ")", nbColors);
return; return;
@@ -524,9 +523,6 @@ static void parseACOFile(std::filebuf &file) {
return; return;
} }
} }
// TODO: maybe scan the v2 data instead (if present)
// `codecvt` can be used to convert from UTF-16 to UTF-8
} }
static void parseGBCFile(std::filebuf &file) { static void parseGBCFile(std::filebuf &file) {