public void DarkenFunction <TPixel>(TestPixel <TPixel> back, TestPixel <TPixel> source, float amount, TestPixel <TPixel> expected)
            where TPixel : struct, IPixel <TPixel>
        {
            TPixel actual = PorterDuffFunctions.DarkenSrcOver(back.AsPixel(), source.AsPixel(), amount);

            VectorAssert.Equal(expected.AsPixel(), actual, 2);
        }
Exemplo n.º 2
0
        public void DarkenFunction(TestVector4 back, TestVector4 source, float amount, TestVector4 expected)
        {
            Vector4 actual = PorterDuffFunctions.DarkenSrcOver((Vector4)back, source, amount);

            VectorAssert.Equal(expected, actual, 5);
        }