📷 A modern, cross-platform, 2D Graphics library for .NET
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.
 
 

38 lines
1.0 KiB

// Copyright (c) Six Labors.
// Licensed under the Six Labors Split License.
using SixLabors.ImageSharp.Processing;
using SixLabors.ImageSharp.Processing.Processors.Convolution;
namespace SixLabors.ImageSharp.Tests.Processing.Convolution;
[Trait("Category", "Processors")]
public class BoxBlurTest : BaseImageOperationsExtensionTest
{
[Fact]
public void BoxBlur_BoxBlurProcessorDefaultsSet()
{
this.operations.BoxBlur();
var processor = this.Verify<BoxBlurProcessor>();
Assert.Equal(7, processor.Radius);
}
[Fact]
public void BoxBlur_amount_BoxBlurProcessorDefaultsSet()
{
this.operations.BoxBlur(34);
var processor = this.Verify<BoxBlurProcessor>();
Assert.Equal(34, processor.Radius);
}
[Fact]
public void BoxBlur_amount_rect_BoxBlurProcessorDefaultsSet()
{
this.operations.BoxBlur(5, this.rect);
var processor = this.Verify<BoxBlurProcessor>(this.rect);
Assert.Equal(5, processor.Radius);
}
}