Expressive 2D graphics library for D
Chitra is an expressive 2D graphics library for the D programming language, designed for creative coding, generative art, animation and document generation.
Above image is generated using Chitra. See here.
Lua Plugin
Easily draw and integrate with other programming languages without recompiling (D).
Rich text support
Render text with font, size, weight, and colour control. Mix styles in a single paragraph using TextStyle. Syntax highlighting is also supported via pygmentize CLI.
Flexible Canvases, Real-World Units
Create canvases by pixel count, paper size, or physical units. Landscape, portrait, custom - all supported.
Multiple Output Formats
Save graphics as PNG, SVG, PDF, GIF, MP4, or WEBM.
Animation
Easily create 2D animation powered by ffmpeg. Chitra generates PNG images for each frame and runs the ffmpeg command with the right arguments to generate the animation.
Built-in QR support
Easily create QR codes with the required color or background. Arrange the QR image on the canvas with pixel-perfect precision.
Grids, Layout Boxes and Tables
Chitra supports creating multiple grids and tables that handle the coordinate arithmetic for you.
And much more..
See features page.
If you use Chitra or are interested in helping this project, a contribution would mean A LOT to me. With your help, continuing my work can be sustainable. Thank you for your continued support!
Chitra is MIT licensed, ©2022-2026 Aravinda VK <aravindavk.in>.