Assembly: AForge.Imaging (in AForge.Imaging.dll) Version: 126.96.36.199 (188.8.131.52)
public class OilPainting : BaseUsingCopyPartialFilter
Processing source image the filter changes each pixels' value to the value of pixel with the most frequent intensity within window of the specified size. Going through the window the filters finds which intensity of pixels is the most frequent. Then it updates value of the pixel in the center of the window to the value with the most frequent intensity. The update procedure creates the effect of oil painting.
The filter accepts 8 bpp grayscale images and 24/32 color images for processing.
// create filter OilPainting filter = new OilPainting( 15 ); // apply the filter filter.ApplyInPlace( image );