/mlaa

MorphoLogical AntiAliasing for monchromatic models

Primary LanguageC++GNU General Public License v3.0GPL-3.0

MLAA

MorphoLogical AntiAliasing for monchromatic models based on Reshetov A. 2009. Morphological Antialiasing, in Proceedings of the Conference on High Performance Graphics 2009

Use

A simple proof of concept for smoothing syntethic models in a hope to alleviate the "staircase effect." Note that horizontal and vertical edges are kept as-is, while only slopes are anti-aliased by "hallucinating" edges/faux supersampling.

Before:
alt text

After:
alt text

Limitations

Currently only Z-shapes are fully supported. U shapes are implemented, but some bugs are present.

Edge classifications

  1. ▏ (1) left
  2. ▕ (2) right
  3. ▁ (4) bottom
  4. ▔ (8) top

Shape classifications

Row shapes

  1. └┐ (2)
  2. ┌┘ (4)
  3. └┘ (8)
  4. ┌┐ (16)
  5. ─┘ (32)
  6. ─┐ (64)
  7. └─ (128)
  8. ┌─ (256)

Column shapes

  1. ┐ (3)
  2. ┌ (5)
  3. ┐ (9)
  4. ┌ (17)
  5. │ (33)
  6. │ (65)
  7. ┐ (129)
  8. ┌ (257)