//
// Copyright (c) James Jackson-South and contributors.
// Licensed under the Apache License, Version 2.0.
//
namespace ImageSharp.Tests.Processing.Processors.Transforms
{
using ImageSharp.PixelFormats;
using Xunit;
public class SkewTest : FileTestBase
{
public static readonly TheoryData SkewValues
= new TheoryData
{
{ 20, 10 },
{ -20, -10 }
};
[Theory]
[WithFileCollection(nameof(DefaultFiles), nameof(SkewValues), DefaultPixelType)]
public void ImageShouldSkew(TestImageProvider provider, float x, float y)
where TPixel : struct, IPixel
{
using (Image image = provider.GetImage())
{
image.Mutate(i => i.Skew(x, y));
image.DebugSave(provider, string.Join("_", x, y));
}
}
}
}