prismatica 0.3.0

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

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

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

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

static YLGNBU_PALETTE_COLORS: [[u8; 3]; 9] = [
    [255, 255, 217],
    [237, 248, 177],
    [199, 233, 180],
    [127, 205, 187],
    [65, 182, 196],
    [29, 145, 192],
    [34, 94, 168],
    [37, 52, 148],
    [8, 29, 88],
];