palettes.gle
Library with additional palettes for Graphics Layout Engine.
Palettes ported by Francois Tonneau (2005).
SUBROUTINE NAMES
inferno z
inferno_text z
magma z
magma_text z
plasma z
plasma_text z
viridis z
viridis_text z
cividis z
cividis_text z
davos z
davos_text z
devon z
devon_text z
oslo z
oslo_text z
SUBROUTINE DETAILS
Pairs of subroutines return the background color and the text color (i.e.,
either black or white, depending on background lightness) for a position z
ranging from 0.0 to 1.0 along the ramp.
PALETTE INFORMATION
For inferno, magma, plasma, and viridis, see:
https://github.com/BIDS/colormap
For cividis, see:
https://github.com/pnnl/cmaputil
For davos, devon, and oslo, see:
http://www.fabiocrameri.ch/colourmaps.php
Palette node definitions.
Each palette involves 18 nodes of rgb values.
inferno
magma
plasma
viridis
cividis
davos
devon
oslo
Computation of each rgb component for z ranging from 0.0 to 1.0.
The values for r, g, b are computed by linear interpolation in RGB space.
Computation of colored background and black/white text foreground.
Convenient wrapper routines for each palette.