Beispiel #1
0
        /// <summary>
        /// Process the filter on the specified image.
        /// </summary>
        ///
        /// <param name="image">Source image data.</param>
        /// <param name="rect">Image rectangle for processing by the filter.</param>
        ///
        protected override unsafe void ProcessFilter(UnmanagedImage image, Rectangle rect)
        {
            // calculate threshold
            thresholdFilter.ThresholdValue = CalculateThreshold(image, rect);

            // thresholding
            thresholdFilter.ApplyInPlace(image, rect);
        }