Get Started
dotnet add package Nullean.TerminalImages --version 0.2.2
| Product | Versions |
|---|---|
| .NET |
README
Nullean.TerminalImages

Show images in the terminal with the Kitty, iTerm2 and Sixel protocols, with protocol detection and a half-block fallback. No dependencies, NativeAOT-safe.
Install
dotnet add package Nullean.TerminalImages
Quick start
using Nullean.TerminalImages;
using Nullean.TerminalImages.Detection;
// Reads the environment, then asks the terminal once (macOS/Linux): Kitty, iTerm2, Sixel or half blocks?
var capabilities = await TerminalImageDetector.DetectAsync();
var renderer = new TerminalImageRenderer(capabilities, new TerminalImageRenderOptions { MaxColumns = 60, MaxRows = 20 });
if (!renderer.RenderPng(File.ReadAllBytes("sunset.png"), Console.Out))
Console.WriteLine("(this terminal cannot show images)");

- Zero dependencies. The PNG codec, resampler and all four encoders are managed code: no SkiaSharp, no ImageSharp, no native assets.
- Detection that does not hang. It reads the environment first, then asks the terminal once with a batch of queries that always ends with a Device Attributes request, which every terminal answers.
- Only PNG is decoded; for other formats build an
RgbaImagefrom RGBA bytes yourself. - Redirected output detects as
Noneand nothing is written; force a protocol withTerminalImageDetectionOptions.Protocolto write escape sequences into a file anyway. NULLEAN_TERMINAL_IMAGES=kitty|iterm2|sixel|blocks|none|autooverrides detection without code, andcapabilities.Diagnosticssays why detection chose what it did.- Detection sees through tmux and wraps output in its passthrough; tmux itself must have
allow-passthrough on. - For Spectre.Console, Terminal.Gui or XenoAtom.Terminal use the
Nullean.TerminalImages.<Host>package.
Learn more
- Documentation: https://terminal-images.nullean.net
- Detection: https://terminal-images.nullean.net/detection/
- The protocols: https://terminal-images.nullean.net/protocols/
- Troubleshooting: https://terminal-images.nullean.net/troubleshooting/
- Source and issues: https://github.com/nullean/terminal-images
Downloads by Version
Similar & Alternative Packages
Hand-picked matching NuGet libraries based on tags & ecosystem
Depended On By
Find packages that declare this package as a dependency. NuGet does not provide a reverse-dependency endpoint, so candidates are checked on demand.
Adoption Assessment
Assess this package against its supported frameworks, license, maintenance signals and dependency graph before making it a project standard.
Compatibility metadata lists 1 target framework; confirm the exact target used by your application.
Related Guides & Workflows
Learn how to evaluate, integrate, or audit this package in your .NET project.