I was wondering... is there an option to prevent pngout from moving colors in the palette? i need the colors to stay at their position in the palette...
Are they changing because it compresses better when the color indexes are organized a certain way?
Thanks
-Flat
Flatulus at
*NOTE:
In my test image, the 1st color in the palette was swaped with the last color in the palette (transparency).
-Flat
Awesoken at
Run PNGOUT with the /kp option to preserve the palette index order. By default, PNGOUT re-arranges the palette order to improve the file size.
FYI: If you afford to move your single transparent color from index 255 to index 0, then you could save yourself 255 bytes in file size. I realize this is not possible if you don't control the palette format. In fact, I'm a violator of this rule because Ken's Labyrinth and the Build Engine both use color 255 as transparency. Sometimes I wish I could go in a time machine and visit myself in 1992 and tell myself to use palette index 0 for transparency instead... To be fair, the PNG standard didn't exist until many years later, and I think they goofed in the specification by not having a start as well as end value for the tRNS list.