Qualpal
Repositories

qualpal::PaletteAnalysis

C++ · cpp · 4.1.0

struct qualpal::PaletteAnalysis

Holds analysis results for a color palette under a specific vision condition.

Contains:

  • The pairwise color difference matrix for all palette colors.

  • The minimum color distance to any other color for each palette color.

  • The minimum color distance from the background (if provided) to the palette.

All distances are computed using the specified color difference metric and simulated color vision deficiency (CVD) if applicable.

Fields

bg_min_distance

double bg_min_distance = std::numeric_limits<double>::quiet_NaN()

Minimum distance from background to palette, or NaN if no background.

difference_matrix

Matrix<double> difference_matrix

Pairwise color difference matrix [size: n x n].

min_distances

std::vector<double> min_distances

For each color, the minimum distance to any other color [size: n].