print images to terminal with Kitty terminal graphics protocol
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-08-30 23:24:50 +00:00
src fetch individual env vars rather than the whole map 2026-03-27 10:26:48 +00:00
.build.yml fix typo in .build.yml 2026-03-10 00:44:02 +00:00
.gitignore implement basic functionality 2026-03-07 16:05:07 +00:00
build.zig add shm_open support 2026-03-12 09:44:51 +00:00
build.zig.zon implement basic functionality 2026-03-07 16:05:07 +00:00
LICENSE implement basic functionality 2026-03-07 16:05:07 +00:00
README.md get rid of sourcehut build badge 2026-08-30 23:24:50 +00:00

Simple image printer

Right now it only handles PNGs. Uses the kitty terminal graphics protocol in direct mode to print an image to the console. Honestly, the terminal does most of the work.

The program takes the bytes of the image, base64 encodes them, chunks them, and dumps to stdout with each chunk wrapped in the appropriate escape code.

Todo

  • Use stb_image to decode arbitrary image formats
  • Use shm_open to transfer the image via shared memory rather than dumping base64 encoded binary to the terminal.
  • For the base64 path, make the loop less branchy.
  • Give the project a better (unique) name.