Skip to content

Texture Edge Bleed — Fix Dark Halos on Transparent Sprites

Bilinear filtering and mipmaps average the colour of transparent texels into your edges. Edge bleed fills those texels with the sprite's own colour, and alpha is never written.

Drop texture maps (PNG keeps exact channel bytes)
Runs in your browser. Files are not uploaded.
Texture Lab: a normal map generated from a CC0 texture, with the OpenGL/DirectX convention shown
The real Texture Lab with a CC0 asset (ambientCG).
Outputs
  • Channel PNGsMeasured· numpy
  • Normal mapMeasured· numpy
  • Packed mask / ORMMeasured· Pillow
  • Engine importUNVERIFIED

What it does

  • RGB pushed outwards 2/4/8/16 px from texels that carry alpha into transparent ones; alpha untouched.
  • Mipmap preview (1/4 … 1/16) with the same box filter a GPU uses, so an undilated edge visibly darkens.
  • Power-of-two resize with a quality resampler (nearest, down, up, fit).
  • Batch export: resize → bleed → encode, bleed last so resizing cannot undo it.

How to do it

  1. Drop the sprite or texture (PNG).
  2. Choose how many pixels to bleed.
  3. Compare the mipmap preview before and after.
  4. Download.

Outputs and how each was checked

"Measured" means the downloaded file was opened again outside the page (Pillow, numpy or an independent parser) and the property was measured. Loading these files in a game engine was not tested.

TargetFilesCheck
Channel PNGs<name>-r/g/b/a.png (8-bit grey)Measured numpyByte-identical per channel, including RGB under fully transparent texels.
Normal mapPNG · OpenGL (+Y) or DirectX (−Y)Measured numpyDecoded vectors are unit length (worst deviation 0.0002); OpenGL and DirectX differ in green only.
Packed mask / ORMUnity HDRP mask · URP metallic · ORM (glTF, Godot)Measured PillowPacked bytes checked: ORM preset over AO 10 / roughness 80 / metallic 220 → (10, 80, 220, 255).
Engine importUnity · Unreal · GodotUNVERIFIEDNot imported in any engine.

Evidence

Channel unpack byte-identical on all four channels (max difference 0), 2048 transparent texels keep their RGB; edge bleed changed 448 texels, all with alpha 0, and no alpha byte; OpenGL ↔ DirectX differ exactly in green (255 − g); converted normals decode to unit vectors.

Limits

  • Exact channel bytes need PNG; JPEG/WebP are decoded by the browser and marked "not byte-exact".
  • Interlaced PNG and 16-bit output are not supported; up to 33.5 million pixels on the exact path.
  • A normal map's convention cannot be detected from its pixels, only converted.
  • Nothing was imported into Unity, Unreal or Godot: channel orders rest on their documentation and engine source.

Questions

Will my transparent areas become visible?

No. Only the colour under alpha 0 changes; in the test 448 texels changed, all of them with alpha 0, and no alpha byte changed.

Is this the same as atlas padding?

No: padding adds space between sprites in an atlas; edge bleed fills the transparent pixels inside an image. Use both for packed atlases.

Is it free, and do I need an account?

Everything on these pages is free and works without an account. There is no watermark and no export that is held back.

Are my sprites uploaded?

No. The Studio decodes, packs and exports in this browser tab. Projects are autosaved in the browser (IndexedDB) and can be saved as a .nerulio file.

Does it need Aseprite or an engine plugin installed?

No. .aseprite files are read and written in the browser, and each engine bundle carries what that engine needs (for Godot, the import settings and scene; for Unity and the Godot TileSet, a small editor script).