public override void OnDrawFinal(Graphics g, Bitmap bmp) { if (BlurRadius > 1) { Rectangle rect = new Rectangle(0, 0, bmp.Width, bmp.Height); rect.Intersect(Rectangle); using (Bitmap croppedImage = ImageHelpers.CropBitmap(bmp, rect)) { ImageHelpers.BoxBlur(croppedImage, BlurRadius); g.DrawImage(croppedImage, rect); } } }
public override Image Apply(Image img) { ImageHelpers.BoxBlur((Bitmap)img, Radius); return(img); }
public override void ApplyEffect(Bitmap bmp) { ImageHelpers.BoxBlur(bmp, BlurRadius); }
public override Bitmap Apply(Bitmap bmp) { ImageHelpers.BoxBlur(bmp, Radius); return(bmp); }