tritanomaly function

Color tritanomaly(
  1. Color color
)

Malfunctioning blue.

Implementation

Color tritanomaly(Color color) {
  final double r =
      (color.red * 0.9667) + (color.green * 0.033) + (color.blue * 0);
  final double g =
      (color.red * 0.0) + (color.green * 0.733) + (color.blue * 0.2667);
  final double b =
      (color.red * 0.0) + (color.green * 0.183) + (color.blue * 0.8167);

  return Color.fromARGB(255, r.round(), g.round(), b.round());
}