prismatica 1.0.0

308 scientific colormaps as compile-time Rust constants
Documentation
// Auto-generated by prismatica xtask -- do not edit
use crate::{Colormap, ColormapKind, ColormapMeta, DiscretePalette};

/// Paired -- Qualitative colormap from the colorbrewer collection.
///
/// Author: Cynthia Brewer
/// Perceptually uniform: false
/// CVD friendly: false
///
/// Citation: Brewer, C. A. (2003). ColorBrewer. www.colorbrewer2.org
pub const PAIRED: Colormap = Colormap {
    meta: ColormapMeta {
        name: "Paired",
        collection: "colorbrewer",
        author: "Cynthia Brewer",
        kind: ColormapKind::Qualitative,
        perceptually_uniform: false,
        cvd_friendly: false,
        grayscale_safe: false,
        lut_size: 256,
        citation: "Brewer, C. A. (2003). ColorBrewer. www.colorbrewer2.org",
    },
    lut: &PAIRED_LUT,
};

static PAIRED_LUT: [[u8; 3]; 256] = [
    [166, 206, 227],
    [160, 202, 225],
    [154, 199, 223],
    [149, 195, 221],
    [143, 191, 219],
    [137, 187, 217],
    [131, 184, 215],
    [125, 180, 213],
    [119, 176, 211],
    [114, 173, 209],
    [108, 169, 207],
    [102, 165, 205],
    [96, 161, 203],
    [90, 158, 201],
    [84, 154, 199],
    [79, 150, 197],
    [73, 147, 195],
    [67, 143, 193],
    [61, 139, 191],
    [55, 136, 188],
    [50, 132, 186],
    [44, 128, 184],
    [38, 124, 182],
    [32, 121, 180],
    [36, 124, 179],
    [43, 128, 177],
    [49, 133, 175],
    [55, 137, 173],
    [62, 141, 171],
    [68, 146, 169],
    [74, 150, 168],
    [81, 155, 166],
    [87, 159, 164],
    [93, 164, 162],
    [100, 168, 160],
    [106, 173, 159],
    [112, 177, 157],
    [119, 181, 155],
    [125, 186, 153],
    [131, 190, 151],
    [138, 195, 150],
    [144, 199, 148],
    [150, 204, 146],
    [157, 208, 144],
    [163, 212, 142],
    [169, 217, 140],
    [176, 221, 139],
    [175, 221, 135],
    [169, 219, 131],
    [164, 216, 127],
    [158, 213, 123],
    [153, 210, 119],
    [147, 208, 115],
    [142, 205, 111],
    [136, 202, 107],
    [131, 200, 103],
    [125, 197, 99],
    [120, 194, 95],
    [114, 191, 91],
    [109, 189, 87],
    [103, 186, 83],
    [98, 183, 79],
    [92, 181, 75],
    [87, 178, 71],
    [81, 175, 66],
    [76, 172, 62],
    [70, 170, 58],
    [65, 167, 54],
    [59, 164, 50],
    [54, 161, 46],
    [55, 160, 46],
    [64, 160, 51],
    [72, 159, 56],
    [81, 159, 60],
    [89, 159, 65],
    [98, 159, 70],
    [107, 158, 74],
    [115, 158, 79],
    [124, 158, 84],
    [133, 158, 88],
    [141, 157, 93],
    [150, 157, 98],
    [158, 157, 103],
    [167, 157, 107],
    [176, 156, 112],
    [184, 156, 117],
    [193, 156, 121],
    [202, 155, 126],
    [210, 155, 131],
    [219, 155, 135],
    [227, 155, 140],
    [236, 154, 145],
    [245, 154, 150],
    [251, 152, 152],
    [250, 147, 146],
    [249, 141, 141],
    [248, 136, 135],
    [247, 130, 130],
    [246, 125, 125],
    [245, 119, 119],
    [243, 114, 114],
    [242, 108, 108],
    [241, 103, 103],
    [240, 97, 98],
    [239, 92, 92],
    [238, 86, 87],
    [237, 81, 81],
    [236, 75, 76],
    [235, 70, 71],
    [234, 64, 65],
    [233, 59, 60],
    [232, 53, 54],
    [231, 48, 49],
    [230, 42, 44],
    [229, 37, 38],
    [228, 31, 33],
    [227, 27, 28],
    [228, 34, 32],
    [229, 41, 35],
    [230, 48, 39],
    [232, 55, 43],
    [233, 62, 46],
    [234, 69, 50],
    [235, 76, 53],
    [236, 84, 57],
    [237, 91, 61],
    [238, 98, 64],
    [239, 105, 68],
    [241, 112, 71],
    [242, 119, 75],
    [243, 126, 78],
    [244, 133, 82],
    [245, 141, 86],
    [246, 148, 89],
    [247, 155, 93],
    [248, 162, 96],
    [250, 169, 100],
    [251, 176, 104],
    [252, 183, 107],
    [253, 190, 111],
    [253, 188, 107],
    [253, 186, 102],
    [253, 183, 97],
    [253, 180, 92],
    [253, 177, 87],
    [254, 175, 83],
    [254, 172, 78],
    [254, 169, 73],
    [254, 166, 68],
    [254, 164, 64],
    [254, 161, 59],
    [254, 158, 54],
    [254, 155, 49],
    [254, 153, 44],
    [254, 150, 40],
    [254, 147, 35],
    [254, 144, 30],
    [255, 142, 25],
    [255, 139, 20],
    [255, 136, 16],
    [255, 133, 11],
    [255, 131, 6],
    [255, 128, 1],
    [253, 129, 7],
    [251, 131, 16],
    [249, 133, 25],
    [246, 135, 34],
    [244, 137, 44],
    [242, 140, 53],
    [240, 142, 62],
    [237, 144, 71],
    [235, 146, 81],
    [233, 148, 90],
    [230, 151, 99],
    [228, 153, 108],
    [226, 155, 117],
    [224, 157, 127],
    [221, 159, 136],
    [219, 162, 145],
    [217, 164, 154],
    [214, 166, 164],
    [212, 168, 173],
    [210, 170, 182],
    [208, 173, 191],
    [205, 175, 201],
    [203, 177, 210],
    [200, 175, 213],
    [196, 170, 210],
    [191, 165, 207],
    [187, 160, 205],
    [183, 155, 202],
    [179, 150, 200],
    [175, 145, 197],
    [171, 140, 194],
    [167, 135, 192],
    [162, 130, 189],
    [158, 125, 187],
    [154, 120, 184],
    [150, 115, 182],
    [146, 110, 179],
    [142, 105, 176],
    [138, 100, 174],
    [133, 94, 171],
    [129, 89, 169],
    [125, 84, 166],
    [121, 79, 163],
    [117, 74, 161],
    [113, 69, 158],
    [109, 64, 156],
    [108, 64, 154],
    [115, 72, 154],
    [121, 81, 154],
    [128, 89, 154],
    [134, 98, 154],
    [140, 106, 154],
    [147, 114, 154],
    [153, 123, 154],
    [160, 131, 154],
    [166, 139, 154],
    [173, 148, 154],
    [179, 156, 154],
    [185, 164, 153],
    [192, 173, 153],
    [198, 181, 153],
    [205, 190, 153],
    [211, 198, 153],
    [218, 206, 153],
    [224, 215, 153],
    [230, 223, 153],
    [237, 231, 153],
    [243, 240, 153],
    [250, 248, 153],
    [254, 254, 152],
    [251, 247, 147],
    [248, 239, 142],
    [244, 232, 137],
    [241, 225, 133],
    [238, 218, 128],
    [234, 211, 123],
    [231, 204, 118],
    [227, 196, 113],
    [224, 189, 108],
    [221, 182, 103],
    [217, 175, 98],
    [214, 168, 94],
    [211, 161, 89],
    [207, 153, 84],
    [204, 146, 79],
    [201, 139, 74],
    [197, 132, 69],
    [194, 125, 64],
    [190, 118, 59],
    [187, 110, 55],
    [184, 103, 50],
    [180, 96, 45],
    [177, 89, 40],
];

/// Original 12-color discrete palette.
pub const PAIRED_PALETTE: DiscretePalette = DiscretePalette {
    meta: ColormapMeta {
        name: "Paired",
        collection: "colorbrewer",
        author: "Cynthia Brewer",
        kind: ColormapKind::Qualitative,
        perceptually_uniform: false,
        cvd_friendly: false,
        grayscale_safe: false,
        lut_size: 12,
        citation: "Brewer, C. A. (2003). ColorBrewer. www.colorbrewer2.org",
    },
    colors: &PAIRED_PALETTE_COLORS,
};

static PAIRED_PALETTE_COLORS: [[u8; 3]; 12] = [
    [166, 206, 227],
    [31, 120, 180],
    [178, 223, 138],
    [51, 160, 44],
    [251, 154, 153],
    [227, 26, 28],
    [253, 191, 111],
    [255, 127, 0],
    [202, 178, 214],
    [106, 61, 154],
    [255, 255, 153],
    [177, 89, 40],
];