AutoCrop Class

Removes a border around an image in the automatic mode.

Namespace: Aurigma.GraphicsMill.Transforms
Assembly: Aurigma.GraphicsMill (in Aurigma.GraphicsMill.dll)

Syntax

C#
public sealed class AutoCrop : Transform

Remarks

This transform supports two settings:

  • BorderColor The color of the border to remove.
  • Threshold The sensitivity of the auto crop. The higher the value the more color will be cropped.

Examples

C#
using (var bitmap = new Bitmap(@"Images\in.jpg"))
using (var autoCrop = new AutoCrop(RgbColor.Brown))
{
    autoCrop.Threshold = 0.7f;
    using (var result = autoCrop.Apply(bitmap))
        result.Save(@"Images\Output\out.jpg");
}

Inheritance Hierarchy

System.Object

See Also

Reference