Prerequisites
ImageSharp version
2.1.3
Other ImageSharp packages and versions
none
Environment (Operating system, version and so on)
Windows 10
.NET Framework version
.net 6
Description
The attached image produces a IndexOutOfRangeException when mutated with the AdaptiveThresholdProcessor.
It might be because the Image is black and white already?
Steps to Reproduce
- Create a new console application
- Add the attached image as embedded resource
- Put the following code in
Program.cs
using SixLabors.ImageSharp;
using SixLabors.ImageSharp.PixelFormats;
using SixLabors.ImageSharp.Processing;
using SixLabors.ImageSharp.Processing.Processors.Binarization;
Stream? stream = typeof(Program).Assembly.GetManifestResourceStream("ConsoleApp1.TestImage.png");
Image<Rgba32> image = await Image.LoadAsync<Rgba32>(stream);
AdaptiveThresholdProcessor p = new();
image.Mutate(i => i.ApplyProcessor(p));
- Run
Images

Prerequisites
DEBUGandRELEASEmodeImageSharp version
2.1.3
Other ImageSharp packages and versions
none
Environment (Operating system, version and so on)
Windows 10
.NET Framework version
.net 6
Description
The attached image produces a IndexOutOfRangeException when mutated with the AdaptiveThresholdProcessor.
It might be because the Image is black and white already?
Steps to Reproduce
Program.csImages