update readme
This commit is contained in:
parent
f328c214b7
commit
204518302a
56
readme.txt
56
readme.txt
@ -9,32 +9,23 @@ 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 idea is to simply load image data without worrying about image metadata.
|
||||||
the metadata contain basic stuff like width, height, format, etc...
|
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]
|
color palette are embedded in the file.
|
||||||
|
a palette hash is provided. this can be used to comparing
|
||||||
|
whether another image uses the same palette
|
||||||
|
|
||||||
|
usage: sillyimage -i <input image> -o <output dir> [options]
|
||||||
|
|
||||||
options:
|
options:
|
||||||
-o, --out
|
-i, --input input files [required] [may be repeated]
|
||||||
output directory
|
-o, --out output directory [required]
|
||||||
|
-h, --help shows help message and exits
|
||||||
-f, --format
|
-v, --version prints version information and exits
|
||||||
specify format {rgb256, rgb16, indexed4, indexed16, indexed256, indexed32a3, indexed8a5}
|
-f, --format texture format { rgb256, rgb16, indexed4, indexed16, indexed256, indexed32a3, indexed8a5 } [default: "rgb16"]
|
||||||
|
|
||||||
-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:
|
binary format:
|
||||||
[string] sillyimg (0x676D69796C6C6973 in hex or 7452728928599042419 in decimal (uint64))
|
[string] sillyimg (0x676D69796C6C6973 in hex or 7452728928599042419 in decimal (uint64))
|
||||||
[uint8] version (current version is 0)
|
[uint8] version (current version is 13)
|
||||||
[uint8] format
|
[uint8] format
|
||||||
0 - RGB256
|
0 - RGB256
|
||||||
1 - RGB16
|
1 - RGB16
|
||||||
@ -44,16 +35,14 @@ binary format:
|
|||||||
5 - INDEXED32A3
|
5 - INDEXED32A3
|
||||||
6 - INDEXED8A5
|
6 - INDEXED8A5
|
||||||
7 - PALETTE16
|
7 - PALETTE16
|
||||||
[uint8] paletteId
|
|
||||||
[uint16] width
|
[uint16] width
|
||||||
[uint16] height
|
[uint16] height
|
||||||
[uint8] compression
|
[uint16] palette count
|
||||||
0 - none
|
[uint32] palette hash
|
||||||
1 - lzss wram
|
[uint32] compress size
|
||||||
2 - lzss vram
|
[uint32] original size
|
||||||
3 - gzip
|
[palette buffer]
|
||||||
[uint32] buffer length
|
[image buffer]
|
||||||
[buffer]
|
|
||||||
|
|
||||||
TODO:
|
TODO:
|
||||||
[x] bitpacking for indexed format
|
[x] bitpacking for indexed format
|
||||||
@ -61,13 +50,14 @@ TODO:
|
|||||||
[ ] convert image using predefined palette
|
[ ] convert image using predefined palette
|
||||||
[ ] output preview image
|
[ ] output preview image
|
||||||
[ ] improve error handling
|
[ ] improve error handling
|
||||||
[ ] compression
|
[x] compression
|
||||||
|
|
||||||
dependecies:
|
dependencies:
|
||||||
argh (https://github.com/adishavit/argh)
|
argparse (https://github.com/p-ranav/argparse)
|
||||||
stb_image, stb_image_writer (https://github.com/nothings/stb)
|
stb_image (https://github.com/nothings/stb)
|
||||||
libimagequant (https://github.com/ImageOptim/libimagequant)
|
libimagequant (https://github.com/ImageOptim/libimagequant)
|
||||||
TImer.h from cherno (https://gist.github.com/TheCherno/b2c71c9291a4a1a29c889e76173c8d14)
|
murmurhash.c (https://github.com/jwerle/murmurhash.c)
|
||||||
|
Timer.h from cherno (https://gist.github.com/TheCherno/b2c71c9291a4a1a29c889e76173c8d14)
|
||||||
|
|
||||||
license:
|
license:
|
||||||
GPL v3
|
GPL v3
|
Loading…
x
Reference in New Issue
Block a user