← f_ notebook · Mirrors · Space & Optics

f_lens, live ​

A filmic imperfect lens: radial distortion, chromatic aberration, vignette, ghost images and warm halation glow.

The cell below steps the NumPy mirror that f_lens's tests are written against, in your browser. It is the NumPy mirror, not the Max patch, and it is not claimed to match the patch bit for bit.

f_lens · NumPy mirror (Pyodide) · not the Max patch
Downloads about 15 MB the first time (Python and NumPy).
  • aberration separates the red and blue channels radially (chromatic fringing); negative flips the lead side.
  • distortion bends the image barrel (negative) or pincushion (positive) toward the edges.
  • transmission darkens and warms the edges (vignette); negative overshoots into a bright reverse vignette.
  • ghost adds attenuated, color-fringed offset copies of the source along the distortion vector.
  • halation adds a warm glow around regions brighter than the threshold.
  • halation threshold sets the luma gate point where the glow blooms.
  • Input select: bars shows color fringing and vignette best; rings show distortion and ghosts.

reference doc · idea note · patcher · lens_mirror.py

← DrosteMobius →