Skip to content

RoepStoep/lidraughts-boardimage

 
 

Repository files navigation

lidraughts-boardimage

An HTTP service that renders draughts board images, used for lidraughts.org

It includes a minimal implementation of the python-chess library for draughts (only piece/board representation and svg).

It uses the same API as web-boardimage, where move notation and FEN strings are replaced by their draughts counterparts. See the adapted installation and usage instructions below.

Usage

python3 server.py [--port 8080] [--bind 127.0.0.1] [--css default.css]

Installation

Requires Python 3.4+.

sudo apt-get install python3-dev libffi-dev libxml2-dev libxslt1-dev libcairo2

pip install -r requirements.txt

HTTP API

GET /board.svg render an SVG

name type default description
fen string required FEN of the position with at least the board part
boardSize string 10 The width and height of the board, e.g. 10 or 8
orientation string white white or black
size int 360 The width and height of the image
lastMove string (none) The last move to highlight, e.g. 0510
arrows string (none) Draw arrows and circles, e.g. 0622,44

GET /board.png render a PNG

About

An HTTP service that renders draughts board images

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 98.1%
  • CSS 1.9%