sillyimage/readme.txt

73 lines
1.9 KiB
Plaintext

i make this tool for my ds to make loading texture easier...
desgined for my personal use only....
its not really optimized and use really minimal error checking
please use something more stable like ptexconv or grit instead!
since ptexconv and grit just simply convert image data into loose Binary
i tried to create header with the metadata information of the image
the idea is to simply load image data without worrying about image metadata.
the metadata contain basic stuff like width, height, format, etc...
there is also paletteId that tell which palette the image used.
usage: sillyimage <input image> [options]
options:
-o, --out
output directory
-f, --format
specify format {rgb256, rgb16, indexed4, indexed16, indexed256, indexed32a3, indexed8a5}
-c, --compress
specify compression {none, lzsswram, lzssvram, gzip}
-pid, --palette-id
specify the palette id
-n, --num
limit num color regardless of the format
-v, --verbose
enable verbose printing
binary format:
[string] sillyimg (0x676D69796C6C6973 in hex or 7452728928599042419 in decimal (uint64))
[uint8] version (current version is 0)
[uint8] format
0 - RGB256
1 - RGB16
2 - INDEXED4
3 - INDEXED16
4 - INDEXED256
5 - INDEXED32A3
6 - INDEXED8A5
7 - PALETTE16
[uint8] paletteId
[uint16] width
[uint16] height
[uint8] compression
0 - none
1 - lzss wram
2 - lzss vram
3 - gzip
[uint32] buffer length
[buffer]
TODO:
[x] bitpacking for indexed format
[ ] bitpacking for alpha indexed format
[ ] convert image using predefined palette
[ ] output preview image
[ ] improve error handling
[ ] compression
dependecies:
argh (https://github.com/adishavit/argh)
stb_image, stb_image_writer (https://github.com/nothings/stb)
libimagequant (https://github.com/ImageOptim/libimagequant)
TImer.h from cherno (https://gist.github.com/TheCherno/b2c71c9291a4a1a29c889e76173c8d14)
license:
GPL v3