This repository has been archived on 2024-06-04. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
thesis-src/Ocr/Ocr.Tesseract.Screenshots/Threshold/ThresholdAdaptiveProcessor.cs
T
2023-11-14 14:52:19 +01:00

20 lines
498 B
C#

using ImageMagick;
using Ocr.Tesseract.Extensions;
namespace Ocr.Tesseract.Screenshots.Threshold;
public class ThresholdAdaptiveProcessor : SingleImageProcessor
{
private readonly int _width;
private readonly int _height;
public ThresholdAdaptiveProcessor(int width, int height)
{
_width = width;
_height = height;
}
/// <inheritdoc />
protected override MagickImage Process(MagickImage image) => image
.ThresholdAdaptive(_width, _height);
}