chroma

2026-11-29

System for colour representation, conversion, and operation.

Upstream URL

shinmera.com/projects/chroma

Author

Yukari Hafner <shinmera@tymoon.eu>

Maintainer

Yukari Hafner <shinmera@tymoon.eu>

License

zlib
README
## About Chroma This is a library for representing and mapping colours between their various spaces. It currently does not support ICC colour space conversions from colour profile files. This is however planned for a future release. If there are other mappings missing that you need, please file an issue. Note: previously this library was named "Colored," but was renamed to Chroma on 2026.4.4. ## How To For the purposes of this tutorial we assume the package ``org.shirakumo.alloy.chroma`` is nicknamed ``chroma``. Primarily, colours are constructed using ``color`` or one of the specific colour space constructors (``rgb``, ``srgb``, ``hsv``, ``hsl``, ``hsi``, ``cmyk``, ``lab``, ``xyz``). You can also de/serialise colours from direct integer format using the ``encode`` and ``decode`` functions. Colours are immutable. As such they can and will be cached wherever possible. Nevertheless, it is not guaranteed that two colours with the same channel values will be ``eq``. To compare colours, use ``color=`` and ``color-equal``. ::common lisp (chroma:color= (chroma:color 1 0 0) (chroma:decode #xFF0000)) ; => T :: In order to convert colours between different colour spaces, use the ``convert`` function. ## Constants Chroma offers a database of standard colours with their associated colour values. You can find these in the ``org.shirakumo.alloy.chroma.colors`` package. You can also define new colours using ``define-color``.

Dependencies (2)

  • documentation-utils
  • parachute

Dependents (0)

    • GitHub
    • Quicklisp