Examples
Library Examples
Generate a palette from HSL color space.
qualpal::Qualpal qp;
qp.;
auto hsl_pal = qp.;
Select colors considering color vision deficiency:
qp..;
auto cvd_pal = qp.;
Here we design a CVD-friendly version of the "ColorBrewer:Set2" palette for a black background, selecting 3 colors.
qp.
.
.
.;
Generate a palette from custom RGB colors:
qp.;
auto rgb_pal = qp.;
Generate a palette using a predefined palette:
qp.;
auto palette = qp.;
Command Line Examples
Generate 5 colors from HSL color space:
Select 2 colors from hex values:
Output palette as comma-delimited values:
#ff0000,#0000ff,#00ff00,#ffff00
Analyze a palette for color difference:
Color Difference Matrix (ciede2000 metric):
Colors analyzed: 3
Colors:
Idx Hex MinDist
0 #ff0000 52.88
1 #00ff00 83.19
2 #0000ff 52.88
Color Difference Matrix:
0 1 2
0 0.00 86.61 52.88
1 86.61 0.00 83.19
2 52.88 83.19 0.00
Generate palette for a dark background
Simulate color vision deficiency (CVD)
Improve an existing palette and select subset
A soothing pastel palette, generated from a HSL color space:
Extend an existing palette:
