call method

Color call(
  1. Color color,
  2. List args
)

Magic method that allows instances of ColorFilter to be called as functions. The filter itself should be called as a function, rather than calling this method directly.

Implementation

Color call(Color color, List args) {
  Type startingColorSpace = color.runtimeType;
  color = color._convert(this.baseType);
  color = this.filterFunction(color, args);
  color = color._convert(startingColorSpace);
  return color;
}