Optiroc / SuperFamiconv

Flexible and composable tile graphics converter supporting Super Nintendo, Game Boy, Game Boy Color, Game Boy Advance, Mega Drive, PC Engine and WonderSwan formats.
MIT License
152 stars 22 forks source link

What does this mean? #16

Closed oziphantom closed 4 years ago

oziphantom commented 4 years ago

invoking .\superfamiconv.exe -i .\FxLogoPacked_1.png -p FxLogoPacked_1t.clr -t FxLogoPacked_1t.pic -m FxLogoPacked_1t.map -B4 -W16 -H16 -R -v I get Loaded image from ".\FxLogoPacked_1.png" (512x512px, indexed color) Mapping palette straight from indexed color image Created palette with 36 colors [16,16,4] Created optimized tileset with 130 entries (discarded 894 redundant tiles) Mapping 1024 16x16px tiles from image No matching tile for position 224,16 No matching tile for position 272,16 No matching tile for position 288,16 No matching tile for position 336,16 No matching tile for position 352,16 No matching tile for position 416,16 No matching tile for position 16,32 No matching tile for position 32,32 No matching tile for position 208,32 No matching tile for position 224,32 No matching tile for position 288,32 No matching tile for position 336,32 No matching tile for position 352,32 No matching tile for position 400,32 No matching tile for position 416,32 No matching tile for position 464,32 No matching tile for position 480,32 No matching tile for position 0,48 No matching tile for position 16,48 No matching tile for position 32,48 No matching tile for position 48,48 No matching tile for position 64,48 No matching tile for position 80,48 No matching tile for position 96,48 No matching tile for position 112,48 No matching tile for position 128,48 No matching tile for position 144,48 No matching tile for position 160,48 No matching tile for position 176,48 No matching tile for position 192,48 No matching tile for position 208,48 No matching tile for position 224,48 No matching tile for position 240,48 No matching tile for position 256,48 No matching tile for position 272,48 No matching tile for position 288,48 No matching tile for position 304,48 No matching tile for position 320,48 No matching tile for position 336,48 No matching tile for position 352,48 No matching tile for position 368,48 No matching tile for position 384,48 No matching tile for position 400,48 No matching tile for position 416,48 No matching tile for position 432,48 No matching tile for position 448,48 No matching tile for position 464,48 No matching tile for position 480,48 No matching tile for position 496,48 No matching tile for position 0,64 No matching tile for position 16,64 No matching tile for position 32,64 No matching tile for position 48,64 No matching tile for position 64,64 No matching tile for position 80,64 No matching tile for position 96,64 No matching tile for position 112,64 No matching tile for position 128,64 No matching tile for position 144,64 No matching tile for position 160,64 No matching tile for position 176,64 No matching tile for position 192,64 No matching tile for position 208,64 No matching tile for position 224,64 No matching tile for position 240,64 No matching tile for position 256,64 No matching tile for position 272,64 No matching tile for position 288,64 No matching tile for position 304,64 No matching tile for position 320,64 No matching tile for position 336,64 No matching tile for position 352,64 No matching tile for position 368,64 No matching tile for position 384,64 No matching tile for position 400,64 No matching tile for position 416,64 No matching tile for position 432,64 No matching tile for position 448,64 No matching tile for position 464,64 No matching tile for position 480,64 No matching tile for position 496,64 No matching tile for position 0,80 No matching tile for position 16,80 No matching tile for position 32,80 No matching tile for position 48,80 No matching tile for position 64,80 No matching tile for position 80,80 No matching tile for position 96,80 No matching tile for position 112,80 No matching tile for position 128,80 No matching tile for position 144,80 No matching tile for position 160,80 No matching tile for position 176,80 No matching tile for position 192,80 No matching tile for position 208,80 No matching tile for position 224,80 No matching tile for position 240,80 No matching tile for position 256,80 No matching tile for position 272,80 No matching tile for position 288,80 No matching tile for position 304,80 No matching tile for position 320,80 No matching tile for position 336,80 No matching tile for position 352,80 No matching tile for position 368,80 No matching tile for position 384,80 No matching tile for position 400,80 No matching tile for position 416,80 No matching tile for position 432,80 No matching tile for position 448,80 No matching tile for position 464,80 No matching tile for position 480,80 No matching tile for position 496,80 No matching tile for position 0,96 No matching tile for position 16,96 No matching tile for position 32,96 No matching tile for position 48,96 No matching tile for position 64,96 No matching tile for position 80,96 No matching tile for position 96,96 No matching tile for position 112,96 No matching tile for position 128,96 No matching tile for position 144,96 No matching tile for position 160,96 No matching tile for position 176,96 No matching tile for position 192,96 No matching tile for position 208,96 No matching tile for position 224,96 No matching tile for position 240,96 No matching tile for position 256,96 No matching tile for position 272,96 No matching tile for position 288,96 No matching tile for position 304,96 No matching tile for position 320,96 No matching tile for position 336,96 No matching tile for position 352,96 No matching tile for position 368,96 No matching tile for position 384,96 No matching tile for position 400,96 No matching tile for position 416,96 No matching tile for position 432,96 No matching tile for position 448,96 No matching tile for position 464,96 No matching tile for position 480,96 No matching tile for position 496,96 No matching tile for position 0,112 No matching tile for position 16,112 No matching tile for position 32,112 No matching tile for position 48,112 No matching tile for position 64,112 No matching tile for position 80,112 No matching tile for position 96,112 No matching tile for position 112,112 No matching tile for position 128,112 No matching tile for position 144,112 No matching tile for position 160,112 No matching tile for position 176,112 No matching tile for position 192,112 No matching tile for position 208,112 No matching tile for position 224,112 No matching tile for position 240,112 No matching tile for position 256,112 No matching tile for position 272,112 No matching tile for position 288,112 No matching tile for position 304,112 No matching tile for position 320,112 No matching tile for position 336,112 No matching tile for position 352,112 No matching tile for position 368,112 No matching tile for position 384,112 No matching tile for position 400,112 No matching tile for position 416,112 No matching tile for position 432,112 No matching tile for position 448,112 No matching tile for position 464,112 No matching tile for position 480,112 No matching tile for position 496,112 No matching tile for position 0,128 No matching tile for position 48,128 No matching tile for position 64,128 No matching tile for position 112,128 No matching tile for position 128,128 No matching tile for position 176,128 No matching tile for position 192,128 No matching tile for position 240,128 No matching tile for position 256,128 No matching tile for position 304,128 No matching tile for position 320,128 No matching tile for position 368,128 No matching tile for position 384,128 No matching tile for position 432,128 No matching tile for position 448,128 No matching tile for position 496,128 No matching tile for position 128,176 No matching tile for position 144,176 No matching tile for position 224,176 No matching tile for position 240,176 No matching tile for position 32,192 No matching tile for position 48,192 No matching tile for position 64,192 No matching tile for position 112,192 No matching tile for position 128,192 No matching tile for position 144,192 No matching tile for position 160,192 No matching tile for position 224,192 No matching tile for position 240,192 No matching tile for position 256,192 No matching tile for position 352,192 No matching tile for position 368,192 No matching tile for position 16,208 No matching tile for position 32,208 No matching tile for position 48,208 No matching tile for position 64,208 No matching tile for position 112,208 No matching tile for position 128,208 No matching tile for position 144,208 No matching tile for position 160,208 No matching tile for position 208,208 No matching tile for position 224,208 No matching tile for position 240,208 No matching tile for position 256,208 No matching tile for position 336,208 No matching tile for position 352,208 No matching tile for position 368,208 No matching tile for position 384,208 No matching tile for position 400,208 No matching tile for position 16,224 No matching tile for position 32,224 No matching tile for position 48,224 No matching tile for position 64,224 No matching tile for position 112,224 No matching tile for position 128,224 No matching tile for position 144,224 No matching tile for position 160,224 No matching tile for position 208,224 No matching tile for position 224,224 No matching tile for position 240,224 No matching tile for position 256,224 No matching tile for position 320,224 No matching tile for position 336,224 No matching tile for position 352,224 No matching tile for position 368,224 No matching tile for position 384,224 No matching tile for position 400,224 No matching tile for position 16,240 No matching tile for position 32,240 No matching tile for position 48,240 No matching tile for position 64,240 No matching tile for position 112,240 No matching tile for position 128,240 No matching tile for position 144,240 No matching tile for position 160,240 No matching tile for position 208,240 No matching tile for position 224,240 No matching tile for position 240,240 No matching tile for position 256,240 No matching tile for position 320,240 No matching tile for position 336,240 No matching tile for position 352,240 No matching tile for position 368,240 No matching tile for position 384,240 No matching tile for position 400,240 No matching tile for position 16,256 No matching tile for position 32,256 No matching tile for position 48,256 No matching tile for position 64,256 No matching tile for position 112,256 No matching tile for position 128,256 No matching tile for position 144,256 No matching tile for position 160,256 No matching tile for position 208,256 No matching tile for position 224,256 No matching tile for position 240,256 No matching tile for position 256,256 No matching tile for position 320,256 No matching tile for position 336,256 No matching tile for position 352,256 No matching tile for position 368,256 No matching tile for position 384,256 No matching tile for position 400,256 No matching tile for position 16,272 No matching tile for position 32,272 No matching tile for position 48,272 No matching tile for position 64,272 No matching tile for position 112,272 No matching tile for position 128,272 No matching tile for position 144,272 No matching tile for position 160,272 No matching tile for position 208,272 No matching tile for position 224,272 No matching tile for position 240,272 No matching tile for position 256,272 No matching tile for position 320,272 No matching tile for position 336,272 No matching tile for position 352,272 No matching tile for position 368,272 No matching tile for position 384,272 No matching tile for position 400,272 Saved native palette data to "FxLogoPacked_1t.clr" Saved native tile data to "FxLogoPacked_1t.pic" Saved native map data to "FxLogoPacked_1t.map"

is it failing to map 130 unique tiles into 1024? why does it make a 16,16,4 palette for an image that has 16 colours in it?

Optiroc commented 4 years ago

Hi! Can you attach, or privately send, the image?

oziphantom commented 4 years ago

where do I send it to.

Optiroc commented 4 years ago

optiroc at gmail 👍

oziphantom commented 4 years ago

did you get the file?

Optiroc commented 4 years ago

Yep! 👍 I’ll get to look at it today.

Optiroc commented 4 years ago

@oziphantom It seems the basic issue is that you set the -R flag, which forces the converter to not remap anything. The palette in the source PNG looks like this:

Screen Shot 2020-03-03 at 15 07 27

Which is honored in both palette and tile conversion. As a consequence, the generated tileset can not be mapped to the image, since it is basically broken. A fault of the converter is perhaps that it doesn't warn that the palette can't sanely be mapped to the tileset. I'll keep this test case in mind for some day when I feel like improving the error output!

Edit: Oh, I forgot to mention that when the -R flag is omitted, the image is converted without issues.

oziphantom commented 4 years ago

After tumbling down the rabbit hole, and looking at files in a hex editor.. it seems that Pro Motion can not be trusted at all. Paint Shop Pro 7 caches files, so if they are changed it will still show you "what it knew before" and Photo shop somehow knows when an entry is transparent.