//
// Copyright (c) James Jackson-South and contributors.
// Licensed under the Apache License, Version 2.0.
//
namespace ImageSharp.Dithering
{
using System;
///
/// Encapsulates properties and methods required to perfom diffused error dithering on an image.
///
public interface IErrorDiffuser
{
///
/// Gets the dithering matrix
///
byte[][] Matrix { get; }
///
/// Transforms the image applying the dither matrix. This method alters the input pixels array
///
/// The pixel accessor
/// The source pixel
/// The transformed pixel
/// The column index.
/// The row index.
/// The image width.
/// The image height.
/// The pixel format.
void Dither(PixelAccessor pixels, TColor source, TColor transformed, int x, int y, int width, int height)
where TColor : struct, IPackedPixel, IEquatable;
}
}