added all remaining formats

This commit is contained in:
2026-04-03 18:45:37 +02:00
parent 473da90b01
commit 9a367b4d10
20 changed files with 589 additions and 193 deletions
+5
View File
@@ -85,6 +85,11 @@ pub const DEFAULT_PALETTE: [(u8, u8, u8); 12] = [
(106, 28, 138), // Violet
];
/// Look up a PEC palette color by index, clamping to valid range.
pub fn pec_color(idx: u8) -> (u8, u8, u8) {
PEC_PALETTE[(idx as usize).min(PEC_PALETTE.len() - 1)]
}
/// Build a color list for `n` thread slots by cycling through `DEFAULT_PALETTE`.
pub fn default_colors(n: usize) -> Vec<(u8, u8, u8)> {
(0..n)