https://github.com/nilqed/cl-sixel
Sixel graphics in Common Lisp
https://github.com/nilqed/cl-sixel
common-lisp sixel sixel-graphics
Last synced: 4 months ago
JSON representation
Sixel graphics in Common Lisp
- Host: GitHub
- URL: https://github.com/nilqed/cl-sixel
- Owner: nilqed
- License: mit
- Created: 2025-02-28T16:12:47.000Z (4 months ago)
- Default Branch: main
- Last Pushed: 2025-02-28T20:36:59.000Z (4 months ago)
- Last Synced: 2025-02-28T21:57:37.522Z (4 months ago)
- Topics: common-lisp, sixel, sixel-graphics
- Language: Common Lisp
- Homepage:
- Size: 583 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# cl-sixel
Sixel graphics in Common Lisp:warning: work in progress :construction:
This is a proof of concpet only at the moment. The goal is to have routines
to emit sixel graphics from CL without any externals on the one hand and
to interface CL to Hayaki Saito's awesome `libsixel` (see link below) on the
other. Using FFI seems to be unnecessary for the latter purpose because
running `img2sixel` with `UIOP` works fine.The main reason for this is PP in `cl-weyl`[^2].
## Sixel
* https://en.wikipedia.org/wiki/Sixel
* https://github.com/saitoha
* https://www.vt100.net/docs/vt3xx-gp/chapter14.html## Prerequisites
To run `sixel.lisp`:
A sixel capable terminal (xterm, mlterm ...)
https://www.arewesixelyet.com/* **xterm** (sixel by default, ReGIS optional)
https://github.com/xterm-x11/xterm.dev
https://invisible-island.net/xterm/xterm.html
* **mlterm** (sixel by default) excellent when configured!)https://github.com/arakiken/mlterm
* more ==> https://github.com/saitoha/libsixel#terminal-requirements
To run `libsixel.lisp`:
latex and dvipng
libsixel ==> https://github.com/saitoha/libsixel#install
img2sixel (incldued) ==> https://github.com/saitoha/libsixel#img2sixel)
CLs tested so far: sbcl, npt, ecl, abcl.
[GnuPlot](http://www.gnuplot.info/) supports sixel as well (quick check):
```
gnuplot> set terminal sixelTerminal type is now 'sixelgd'
Options are 'notruecolor nocrop enhanced butt anchor size 640,480 font "arial,12.0" '
gnuplot>
gnuplot> test
```
If your terminal is lucky then ...
## src/sixel.lisp
The following tests were made with(display-sixel-data (test1))
in `sixel.lisp`. The format is very simple in principle (also see header there).### mlterm
### xterm
### domterm
## src/libsixel.lisp
The following is more or less a tranlsation of `latex2sixel`[^1] to CL.


## Default parameters

[^1]:https://github.com/nilqed/latex2sixel
[^2]:https://github.com/nilqed/cl-weyl:date: