Skip to content

Commit 0c68ba4

Browse files
committed
Add documentation
1 parent 4e2564b commit 0c68ba4

4 files changed

+39
-0
lines changed

README.md

+39
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# Analogue Pal Tool
2+
3+
Simple over-engineered tool for generating PAL color palettes from images.
4+
5+
## Usage examples
6+
Prebuilt binaries are TODO. For now use [cargo from Rust](https://www.rust-lang.org/tools/install) to build and run.
7+
8+
* Display full help:
9+
```
10+
cargo run -- --help
11+
```
12+
* Display palette from .pal file in terminal (it must support 24-bit color obviously, use good terminal emulator like [Kitty](https://sw.kovidgoyal.net/kitty/) or [Alacritty](https://alacritty.org/))
13+
```
14+
cargo run -- --palette palette.pal
15+
```
16+
![example of display command](doc_images/display_example.png)
17+
* Create template .pal file:
18+
```
19+
cargo run -- create-template-pal -o template.pal
20+
```
21+
Use generate .pal file while taking screenshots on Analogue Pocket (Analogue + Start button combination). This palette does not look good, but will allow you to use next option
22+
* Colorize and scale (x3) .png image created using template .pal file:
23+
```
24+
cargo run -- colorize-image -s 3 --pal example.pal --output output.png 20240105_212250.png
25+
```
26+
It will generate file similar to this: ![example of single image colorization, Super Mario Land 2 by Nintendo](doc_images/colorize_single_example.png)
27+
* Colorize multiple images using multiple .pal files and generate HTML summary file:
28+
```
29+
cargo run -- colorize-image -t -m -s 3 -o 'dev_assets/output/test2.png' -p '/Users/pecet/dev/analogue_pal_tool/dev_assets/Trashuncle/GBP/**/*.pal' '/Users/pecet/dev/analogue_pal_tool/dev_assets/ScreenShots/*.png'
30+
```
31+
It will generate output.html (currently not configurable) in current directory containing all images and palette combinations. So basically you can preview any palettes you have using this. Example part of output from this command (html):
32+
![example of multiple image colorization, Super Mario Land 1, 2 and Tetris by Nintendo](doc_images/colorize_multiple_example.png)
33+
34+
## TODO
35+
* [ ] Add prebuilt binaries
36+
* [ ] Add option to use convert images back to palettes (images are already generated as PNG files with 8-bit palette so this should be easy)
37+
* [ ] Add LUA scripting support for palette manipulation because why not
38+
39+
358 KB
Loading
27.7 KB
Loading

doc_images/display_example.png

79.4 KB
Loading

0 commit comments

Comments
 (0)