AnointedAutomation.Imaging 1.0.5

dotnet add package AnointedAutomation.Imaging --version 1.0.5
                    
NuGet\Install-Package AnointedAutomation.Imaging -Version 1.0.5
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="AnointedAutomation.Imaging" Version="1.0.5" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="AnointedAutomation.Imaging" Version="1.0.5" />
                    
Directory.Packages.props
<PackageReference Include="AnointedAutomation.Imaging" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add AnointedAutomation.Imaging --version 1.0.5
                    
#r "nuget: AnointedAutomation.Imaging, 1.0.5"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package AnointedAutomation.Imaging@1.0.5
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=AnointedAutomation.Imaging&version=1.0.5
                    
Install as a Cake Addin
#tool nuget:?package=AnointedAutomation.Imaging&version=1.0.5
                    
Install as a Cake Tool

AnointedAutomation.Imaging

Jesus is King ✝️

Image generation utilities for the AnointedAutomation suite. It renders QR codes produced by AnointedAutomation.Algorithms to SVG or PNG using only the .NET base class library, so there is no third party or native image dependency.

NuGet Downloads

Installation

dotnet add package AnointedAutomation.Imaging

Quick start

using System.IO;
using AnointedAutomation.Algorithms.QrCode;
using AnointedAutomation.Imaging.QrCode;

QrMatrix matrix = QrEncoder.Encode("https://store.anointed.company", QrErrorCorrectionLevel.M);

string svg = QrRenderer.ToSvg(matrix, moduleSize: 8, quietZone: 4);
byte[] png = QrRenderer.ToPng(matrix, moduleSize: 8, quietZone: 4);

File.WriteAllText("qr.svg", svg);
File.WriteAllBytes("qr.png", png);

API overview

Namespace: AnointedAutomation.Imaging.QrCode

Member Returns Description
QrRenderer.ToSvg(QrMatrix matrix, int moduleSize = 8, int quietZone = 4) string An SVG document with a white background and one black rect per dark module, drawn with shape-rendering="crispEdges".
QrRenderer.ToPng(QrMatrix matrix, int moduleSize = 8, int quietZone = 4) byte[] An 8 bit grayscale PNG, compressed with the BCL ZLibStream.

Parameters:

  • moduleSize: pixel size of each module. Must be at least 1.
  • quietZone: width of the light border, in modules. Must be 0 or more; the QR specification recommends 4.
  • The output image is (matrix.Size + 2 * quietZone) * moduleSize pixels square.

Both methods throw ArgumentNullException for a null matrix and ArgumentOutOfRangeException for an invalid moduleSize or quietZone.

Serving a QR code from ASP.NET Core

// Program.cs in an ASP.NET Core project (Microsoft.NET.Sdk.Web)
using AnointedAutomation.Algorithms.QrCode;
using AnointedAutomation.Imaging.QrCode;

WebApplication app = WebApplication.CreateBuilder(args).Build();

app.MapGet("/qr", (string text) =>
{
    QrMatrix matrix = QrEncoder.Encode(text, QrErrorCorrectionLevel.Q);
    return Results.File(QrRenderer.ToPng(matrix), "image/png");
});

app.Run();

License

MIT. See LICENSE. Copyright © Anointed Automation Corporation. Stewarded by Alexander Fields.

Support This Project

This library is free and open source. The best way to support the work is to shop with us:

Found a bug or have a request? Open an issue: https://github.com/AnointedAutomation/AnointedAutomation/issues

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.0.5 86 10/26/2026
1.0.4 108 10/1/2026
1.0.3 109 10/1/2026
1.0.2 108 9/25/2026
1.0.1 133 8/23/2026
1.0.0 149 6/24/2026