Available

amalgame-image

Decode/encode PNG/JPG/BMP/TGA/GIF/PSD/HDR via stb_image.

amc package add image GitHub ↗ ← Back to the ecosystem

Overview

Wrapper around stb_image.h and stb_image_write.h (public domain). Load and write images in all common formats with no system dependency. RGBA buffer exposed as List<int>.

Features

  • Decode: PNG, JPG, BMP, TGA, GIF, PSD, HDR
  • Encode: PNG, JPG, BMP, TGA
  • Format conversion via double-pass load/save
  • Resize via stb_image_resize
  • Vendored — no external dep

Example

Minimal usage example — copy-paste runnable after install.

amc package add image

let img = Image.Load("input.png")
let small = img.Resize(256, 256)
small.Save("thumb.jpg", quality: 85)

At a glance

Related packages