: Call this batch file in the following way
: permtest ruemorgue1.png 100 100 256
: test.png which is created should be an exact match to the input image.
: permindex.txt can be used in the permgui tools keytester.

png_to_perm -i=%1 > permindex.txt
png_from_perm -i=test.png -w=%2 -h=%3 -c=%4 -f=permindex.txt
