summaryrefslogtreecommitdiff
path: root/README
blob: b7102c2b850313d4c5d7ad80377c7c849860879a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
This is the update server. By default, it will output files to:
/var/www/html/assets

Simply use comp.py and it will convert assets and pretty much handle everything
for you. Make sure that raw/ folder is consistent with the same rules which builtin
assets follow regarding paths.

This is a development tool for optimization and not required for your server.
It **only** works in Debian Buster and other systems similar to this one, like
Ubuntu 18.04.
You can use, eg. GitLab Pages to serve the files and make a 301 on main server, or
simply not use the tool at all.

The choice is yours.

----
Accepted licenses:

* GPLv3 or later
* GPLv2 or later (we will use as GPLv3)
* CC BY SA 4.0 (no earlier version!)
* LGPL v2.1 or later
* CC BY 3.0 (not advised)
* CC BY 4.0
* CC 0
* Apache License

Licenses not listed above are subject to prior analysis.
They must be:
* irrevocable
* attend the Open Source Definition
* compatible with GPLv3 terms
* compatible with CC-BY-SA 4.0 terms

Keep in mind that NC licenses are NOT open source, nor are they compatible with the
GPL!


----
Other tools (Linux-only)

Dependencies:
```sh
apt install imagemagick
pip3 install pillow opencv-python```

* mobs.py
  * Converts everything in "ready-mobs" to proper image size for mob db.
    but attribution isn't generated. Input is PNG, output is WebP.
    Image name should be the faction + monster ID. Model `FFMM`. So an imperial
    spearman is named `0001` and an arch wizard is named `0701`.
    Attribution template is sent to ATTR.txt for convenience
* units.py
  * Based in "ready-units" folder, using semi-qualified name (e.g. 1002 - 1 star,
    unit 2; The "10" prefix and 0x suffix is not needed). Resizes image to 640x960
    and finds a face, which is then centered and a square is produced, then the
    three image slices are made. Accepts PNG and JPG input, output is Webp.
    If there is a image with same name but "sq_" prefix, it's used instead of face
    detection tool. The output is saved in square/ and unit/ subfolder
  * Structure:
    ready-units/
        unit/
        square/
        base/  Save your images here

DISCLAIMER: lbpcascade_animeface obtained from https://github.com/nagadomi/lbpcascade_animeface - License state unknown. Feel free to use your own cascate rule, which is also required for some images.