Corona-Studio / ColorThief.ImageSharp

ColorThief Library for ImageSharp
MIT License
6 stars 0 forks source link
color color-palette color-thief colors csharp dotnet imagesharp sixlabors-organization

ColorThief.ImageSharp

The library to resolve color palette for SixLabors.ImageSharp images.

This is a ported project of Color Thief

How to use

Get the dominant color from an image

var colorThief = new ColorThief();
colorThief.GetColor(sourceImage);

Build a color palette from an image

In this example, we build an 8 color palette.

var colorThief = new ColorThief();
colorThief.GetPalette(sourceImage, 8);

You can see more examples for loading an image and get the palette of it in ColorThief.ImageSharp.Test