Apply() public method

Apply filter to an image.
The method keeps the source image unchanged and returns the result of image processing filter as new image.
Unsupported pixel format of the source image.
public Apply ( Bitmap image ) : Bitmap
image System.Drawing.Bitmap Source image to apply filter to.
return System.Drawing.Bitmap
Beispiel #1
0
        /// <summary>
        /// Process the filter on the specified image.
        /// </summary>
        ///
        /// <param name="image">Source image data.</param>
        ///
        protected override unsafe void ProcessFilter(UnmanagedImage image)
        {
            // perform opening on the source image
            UnmanagedImage openedImage = opening.Apply(image);

            // subtract opened image from source image
            subtract.UnmanagedOverlayImage = openedImage;
            subtract.ApplyInPlace(image);

            openedImage.Dispose( );
        }