This is simple util, to render .ppm images in your terminal.
Using RGB colors by using terminal control character like this:
printf("\e[48;2;%d;%d;%dm ", colors[r][c].red, colors[r][c].green, colors[r][c].blue);No third-party libraries are used.
You can build this with build.sh.
chmod +x build.sh
./build.sh
Interactive mode
./renderer
CLI mode
./renderer <filename.ppm> [--width N] [--height N] [--no-proportions] [--inter]
| Argument | Description |
|---|---|
| filename.ppm | Path to PPM file (P6 binary format) |
| --width N | Width in ASCII char |
| --height N | Height in ASCII char |
| --no-proportions | Off original proportions of image |
| --inter | Enable interpolation (smoothing) |
| Without interpolation | With interpolation |
|---|---|
![]() |
![]() |
| ./renderer test.ppm | ./renderer test.ppm --inter |
Terminal with 24-bit color support (I use iTerm2 — great btw)
macOS / Linux (Windows WSL should work)
MIT © 2026 Andrew Shevtsov

