prevnext   » SZS: Wiimms SZS Toolset » wszst: Wiimms SZS Tool » wszst distribution

wszst distribution

Load each SOURCE (SZS, WBZ, U8 or WU8) and calculate a checksum ot the uncompressed data. If SOURCE is a directory, scan it for SZS, WBZ, U8 and WU8 files. Finally print the results into file RESULT.

The default name for RESULT is ++distribution.txt+½. Extension .txt is appended to the filename if not defined. If RESULT is a directory, it is used as first source too.

If file RESULT exists, it is automatically added as last source to the list of option --source, but only if not already added. On scanning of file result, parameters are scanned too.

Contents

1.   Syntax

wszst DISTRIBUTION result source...
wszst DISTRIBUTION directory [source]...

2.   Options

Options
Option Param Description
-i --ignore Ignore non existing source files without warning.
-n --norm The uncompressed data will be normalized. See command NORMALIZE for more details.
--ignore-setup Ignore hidden setup file 'wszst-setup.txt'. This file is used to determine some default settings and to find out sub archives and files to encode. Use this option only if you know what you do.
--u8 Create an U8 archive, if possible. If the source is a WU8 archive, convert it to an U8 archive. This is the default if the setup file 'wszst-setup.txt' has no other definition. The default compression mode is set to Yaz0 (see --yaz0).
--wu8 Create a WU8 archive, if possible. If the source is an U8 archive, convert it to a WU8 archive.
--pack Create a PACK archive.
--brres Create a BRRES archive.
--breff Create a BREFF archive.
--breft Create a BREFT archive.
--yaz0 If creating a compressed file, force Yaz0 compression. Yaz0 compression is the default, if no compression method is defined by option or setup file.
--yaz1 If creating a compressed file, force Yaz1 compression. The difference to Yaz0 is only the magic, which is set to 'Yaz1'.
--bz If creating a compressed file, force BZ compression (a BZIP2 variant).
--szs Short cut for »--u8 --yaz0«: Create an U8 archive, if possible, and set the compression method to Yaz0.
--wbz Short cut for »--wu8 --bz«: Create a WU8 archive, if possible, and set the compression method to BZ.
--pt-dir [=mode] Set one of the `point directory' modes REMOVE (=0), FORCE (=1) or AUTO (default). If --pt-dir is used without parameter, then FORCE is assumed.

This option is only relevant if creating an U8 archive. It decides, if a special directory with name '.' will be added as base for all other files.

--rm-aiparam Remove the directory AIParam and all files from the archive. This option has only impact, if creating a new archive or normalizing an existing archive. --rmai is a short cut.
--align-u8 size Define an align value for the sub files in U8 archives. The value must be a power of 2 and the default value is 32 (0x20) This value is only relevant if creating or normalizing U8 archives.
--align-pack size Define an align value for the sub files in PACK archives. The value must be a power of 2 and the default value is 32 (0x20) This value is only relevant if creating or normalizing OACK archives.
--align-brres size Define an align value for the sub files in BRRES archives. The value must be a power of 2 and the default value is 4 This value is only relevant if creating or normalizing BRRES archives.
--align-breff size Define an align value for the sub files in BREFF archives. The value must be a power of 2 and the default value is 4 This value is only relevant if creating or normalizing BREFF archives.
--align-breft size Define an align value for the sub files in BREFT archives. The value must be a power of 2 and the default value is 0x20 This value is only relevant if creating or normalizing BREFT archives.
--align size Define an align value for the sub files in all archives. This is a short cut for »--align-u8=size --align-pack=size --align-brres=size --align-breff=size --align-breft=size«.
-L --logging This debug option enables the logging of internal lists and maps.
--encode-all Encode all files. Normally a file is only encoded, if the source is younger than the destination or the destination is missing. Only files in the [encode] section of the file 'wszst-setup.txt' are candidates for encoding. --eall is a short cut. Option --no-encode takes precedence over --encode-all.
--encode-img Encode all image files. Normally a image file is only encoded, if the source is younger than the destination or the destination is missing. Only files in the [encode] section of the file 'wszst-setup.txt' are candidates for encoding. --eimg is a short cut. If set, option --no-encode is ignored for images.
-a --all Encode all files. This is a short cut for --encode-all (and more options in the future).
--no-encode Do not encode files before creating an archive. --noenc is a short cut. Option --no-encode takes precedence over --encode-all, but --encode-img takes precedence for images.
--no-recurse Do not create archives recursively. Normally files in the [create] section of the file 'wszst-setup.txt' are created first. --norec is a short cut.
--no-echo Suppress output of @ECHO commands while scanning text files.
-N --no-check Do not make plausibility checks for KCL and KMP files.
-x --transform list Convert image formats when reading. A comma separated list with terms is expected. A term have the syntax '[SRC=]DEST'. It means: convert SRC format into DEST format. If SRC= is not set, the destination format is used for all source formats. This makes only sense as last rule. If DEST is empty no transformation is done for the source. Examples: 'TPL' or 'GRAY' or 'BTI.IA8' or 'TPL.I4+I8=IA8,TEX=,CMPR'

SRC and DEST are tupel of file, image and palette formats and of 2 more attributes. All parts are optional and separated by points, the order is irrelevant.

Allowed file formats are: TPL, TEX, BTI, BREFT-IMG (=BTIMG), PNG (import). Allowed image formats are: I4, I8, IA4, IA8, RGB565 (=R565), RGB5A3 (=R3), RGBA32 (=R32), C4, C8, C14X2, CMPR. Allowed palette formats are: P-IA8 (=P8), P-RGB565 (=P565), P-RGB5A3 (=P3). Attributtes are PALETTE, NO-PALETTE, GRAY, COLOR, ALPHA and NO-ALPHA.

All terms are managed as list. For each graphic the list is iterated until the first SRC tupel of a term matches the graphic. Then the destination tupel is used for the transformation.

The command »wimgt TEST« prints a clearly arranged readable table as result of this option.

--auto-add Analyze the KMP (if exist) and add missing BRRES, BREFF, BREFT, BRASD and KCL files automatically, if the tool can find the files in any sub directory named 'auto-add'. This sub directory is searched in all directories of 'SEARCH_PATH'; use command »wszst AUTOADD« to view them. Command »wszst AUTOADD« may also create an auto-add database. --aadd is a short cut.
--n-mipmaps num Force the number of mipmaps. Values between 0 and 20 are allowed. Value AUTO (default) enabless automatic detection. The creation of mipmaps stops if the witdh or the height of the mipmap becomes 0. --n-mm is a short cut.
--mipmap-size num Define the minimal width and minimal height of a generated mipmap. The default is 16. Tools before v1.49 used 1 as not alterable value. --mm-size is a short cut.
--mipmaps If reading a source, scan for mipmaps and load them too. For PNG files, files named NAME.mm#.EXT with #=1.. are searched. This is the default.
--no-mipmaps If reading a source, ignore mipmaps. This disables not the creation of mipmaps (see -n-mipmaps). --no-mm is a short cut.
--smart If resizing an image, use the new smart resize function. The new function is much slower (factor 2-4) than the old function, but creates much better resized images. This is only relevant for creating mipmaps with odd width or height.
--base64 [mode] Encode the the checksum string as BASE64 with 27 characters instead of hex. If a parameter is set, it acts like --coding=mode.
--db64 [mode] Encode the the checksum string and some length as BASE64 with 32 characters instead of hex for database searches. This options implies --coding=URL if no other coding is defined. If a parameter is set, it acts like --coding=mode. Option --db64 has priority over --base64.
--coding mode Define the coding of the non alhanumeric characters for BASE64: STANDART (+/=, default), URL (-_=), STAR (-_*) or XML (.-*).
-s --source path Define a text file for filename to slot translation. A »slot filename« list is expected. Use this option multiple times to define more than one source file. A definition of a later source overwrites previous definitions. The file RESULT of the command line is appended automatically as last entry, if exists and not already defined.

3.   Description

...

3.1   Example

  1. Enter the directory where all you files of your distribution reside.
  2. Execute: wszst distribution .
    Don't forget the point at the end of the command.
  3. Edit the file distribution.txt.
  4. Visit https://ct.wiimm.de/upload, follow the instructions and upload the configuration file.