Generate GIFs of chess games from PGN files.
Project description
pgn-to-gif
Generate GIFs of chess games from PGN files.
Installation
pip3 install pgn-to-gif
Usage
usage: pgn-to-gif [-h] --pgn-path PGN_PATH --gif-path GIF_PATH [--add-initial-position {1,t,true,0,f,false}] [--highlight-last-move {1,t,true,0,f,false}] [--orientation {white,black}]
[--size SIZE] [--coordinates {1,t,true,0,f,false}] [--css-path CSS_PATH] [--loop LOOP] [--duration DURATION] [--fps FPS] [--palettesize PALETTESIZE]
[--subrectangles {1,t,true,0,f,false}] [--processes PROCESSES]
optional arguments:
-h, --help show this help message and exit
--pgn-path PGN_PATH path to pgn file to read (default: None)
--gif-path GIF_PATH path to gif file to save (default: None)
--add-initial-position {1,t,true,0,f,false}
add initial position to gif (default: true)
--highlight-last-move {1,t,true,0,f,false}
highlight last move on board (default: true)
--orientation {white,black}
orientation of board (default: white)
--size SIZE size of board (default: 400)
--coordinates {1,t,true,0,f,false}
add board coordinates (default: true)
--css-path CSS_PATH path to css file to style board (default: None)
--loop LOOP number of loops for gif, 0 means infinite (default: 0)
--duration DURATION duration of each frame (in seconds) in gif (default: 1.0)
--fps FPS frame per second of gif (default: 1.0)
--palettesize PALETTESIZE
number of colors to quantize images to (default: 64)
--subrectangles {1,t,true,0,f,false}
optimize gif by storing change (default: true)
--processes PROCESSES
number of processes when converting svgs to pngs (default: 1)
Examples
Please see examples folder.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pgn_to_gif-0.0.3.tar.gz
(5.2 kB
view details)
Built Distribution
File details
Details for the file pgn_to_gif-0.0.3.tar.gz
.
File metadata
- Download URL: pgn_to_gif-0.0.3.tar.gz
- Upload date:
- Size: 5.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.4.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.8.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 37c66393ee232f02ef71a0c0c407b3d879a163c75a2306092bcf46fbd92b4dfa |
|
MD5 | 334441a9a12c29b68d057eae13abe04f |
|
BLAKE2b-256 | 844dcbd28f2305a722d9af1d40578713d7553c678b8492ca6d5190327c2ae23d |
File details
Details for the file pgn_to_gif-0.0.3-py3-none-any.whl
.
File metadata
- Download URL: pgn_to_gif-0.0.3-py3-none-any.whl
- Upload date:
- Size: 6.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.4.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.8.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 18e3a76258ade3799922fbbb107c5fcb7222953aa75946763cc7396457d29cd8 |
|
MD5 | 5b15e51994514cb1e5a83667882dfc55 |
|
BLAKE2b-256 | d98bcae4e13f45a6dd35941636d4c8740b9eda6c2abd3ba606e3be5f6a9ff1ad |