Aurigma Graphics Mill 5.5 for .NET
Semiautomatic Red-Eye Removal
Red-Eye Removal is able to remove red-eye effect in semiautomatic mode. It means that it is enough to specify the face and algorithm automatically will find red eyes and fix color there. This is much more convenient than clicking to the eye, especially when the photo is significant zoomed (e.g. in web interface) and it is difficult to click the eye precisely.
To use Red-Eye Removal in semiautomatic mode, you should:
- Create the Aurigma.GraphicsMill.Transforms.RedEyeRemoval class instance.
- Set the RedEyeRemoval.Mode property to RedEyeRemovalMode.Semiautomatic.
- Put the rectangle which specifies the area occupied with a face into the RedEyeRemoval.FaceRegion property.
- Apply the transform with a help of the ApplyTransform method.
The simplest way to give the user possibility to select a face is to add a rectangle rubberband to your application.
Here is a code demonstrating this:
Visual Basic
Dim redEyeRemoval As New Aurigma.GraphicsMill.Transforms.RedEyeRemoval redEyeRemoval.Mode = Aurigma.GraphicsMill.Transforms.RedEyeRemovalMode.Semiautomatic redEyeRemoval.FaceRegion = faceRect redEyeRemoval.ApplyTransform(sourceBitmap)
C#
Aurigma.GraphicsMill.Transforms.RedEyeRemoval redEyeRemoval =
new Aurigma.GraphicsMill.Transforms.RedEyeRemoval();
redEyeRemoval.Mode = Aurigma.GraphicsMill.Transforms.RedEyeRemovalMode.Semiautomatic;
redEyeRemoval.FaceRegion = faceRect;
redEyeRemoval.ApplyTransform(sourceBitmap);