mirror of https://github.com/SixLabors/ImageSharp
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
34 lines
1.3 KiB
34 lines
1.3 KiB
// <copyright file="IQuantizer.cs" company="James Jackson-South">
|
|
// Copyright (c) James Jackson-South and contributors.
|
|
// Licensed under the Apache License, Version 2.0.
|
|
// </copyright>
|
|
|
|
namespace ImageProcessorCore.Quantizers
|
|
{
|
|
/// <summary>
|
|
/// Provides methods for allowing quantization of images pixels.
|
|
/// </summary>
|
|
/// <typeparam name="TColor">The pixel format.</typeparam>
|
|
/// <typeparam name="TPacked">The packed format. <example>uint, long, float.</example></typeparam>
|
|
public interface IQuantizer<TColor, TPacked> : IQuantizer
|
|
where TColor : IPackedVector<TPacked>
|
|
where TPacked : struct
|
|
{
|
|
/// <summary>
|
|
/// Quantize an image and return the resulting output pixels.
|
|
/// </summary>
|
|
/// <param name="image">The image to quantize.</param>
|
|
/// <param name="maxColors">The maximum number of colors to return.</param>
|
|
/// <returns>
|
|
/// A <see cref="T:QuantizedImage"/> representing a quantized version of the image pixels.
|
|
/// </returns>
|
|
QuantizedImage<TColor, TPacked> Quantize(ImageBase<TColor, TPacked> image, int maxColors);
|
|
}
|
|
|
|
/// <summary>
|
|
/// Provides methods for allowing quantization of images pixels.
|
|
/// </summary>
|
|
public interface IQuantizer
|
|
{
|
|
}
|
|
}
|
|
|