Exemplo n.º 1
0
        public void PixelBufferApplyMaskWithCropOrNot()
        {
            tlog.Debug(tag, $"PixelBufferApplyMaskWithCropOrNot START");

            var testingTarget = new PixelBuffer(100, 50, PixelFormat.BGR8888);

            Assert.IsNotNull(testingTarget, "Can't create success object PixelData");
            Assert.IsInstanceOf <PixelBuffer>(testingTarget, "Should be an instance of PixelData type.");

            try
            {
                using (PixelBuffer pixelBuffer = new PixelBuffer(50, 100, PixelFormat.A8))
                {
                    testingTarget.ApplyMask(pixelBuffer, 0.5f, true);
                }
            }
            catch (Exception e)
            {
                Assert.Fail("Fail!");
            }

            testingTarget.Dispose();
            tlog.Debug(tag, $"PixelBufferApplyMaskWithCropOrNot END (OK)");
        }