anchor.diff:          await image.toByteData(format: ui.ImageByteFormat.rawRgba);
       final Iterable<Color> pixels =
           _getImagePixels(imageData, image.width, image.height, region: region);
  -    final Map<Color, int> hist = <Color, int>{};
  +    final _ColorHistogram hist = _ColorHistogram();
  +    Color currentColor;
  +    _ColorCount currentColorCount;
  +
       for (Color pixel in pixels) {
         // Update the histogram, but only for non-zero alpha values, and for the
         // ones we do add, make their alphas opaque so that we can use a Color as
  
positive.code:     _fitMinimumBox();
    }
  
    final Map<Color, int> histogram;
    final List<Color> colors;
  
    // The lower and upper index are inclusive.
  
negative.code:     colors.replaceRange(_lowerIndex, _upperIndex + 1, colorSubset);
      final int median = (_population / 2).round();
      for (int i = 0, count = 0; i <= colorSubset.length; i++) {
        count += histogram[colorSubset[i]].value;
        if (count >= median) {
          // We never want to split on the upperIndex, as this will result in the
          // same box.
  