Skip to content

Instantly share code, notes, and snippets.

@scorphus
Created October 11, 2020 22:30
Show Gist options
  • Save scorphus/edba3ad5c615fd9ee0992aa81960110d to your computer and use it in GitHub Desktop.
Save scorphus/edba3ad5c615fd9ee0992aa81960110d to your computer and use it in GitHub Desktop.
All possible combinations of shades and opacities
fn main() {
for shade in 0..242 {
let opacity = 13f32 / (255f32 - shade as f32);
println!("opacity:{:0.3};fill:#{:06x}", opacity, shade * 65793);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment