dispatchFull method

  1. @override
Uint8List dispatchFull(
  1. Uint8List data,
  2. int width,
  3. int height
)
override

Implementation

@override
Uint8List dispatchFull(Uint8List data, int width, int height) {
  final random = math.Random();
  final rand = random.nextDouble() / 2 + 0.4;
  for (int i = 0; i < width * height; i++) {
    data[i] = (255 * math.pow(data[i] / 255, rand)).toInt();
  }
  return data;
}