C# 클래스 AForge.Imaging.Filters.BilateralSmoothing

Bilateral filter implementation - edge preserving smoothing and noise reduction that uses chromatic and spatial factors.

Bilateral filter conducts "selective" Gaussian smoothing of areas of same color (domains) which removes noise and contrast artifacts while preserving sharp edges.

Two major parameters SpatialFactor and ColorFactor define the result of the filter. By changing these parameters you may achieve either only noise reduction with little change to the image or get nice looking effect to the entire image.

Although the filter can use parallel processing large KernelSize values (greater than 25) on high resolution images may decrease speed of processing. Also on high resolution images small KernelSize values (less than 9) may not provide noticeable results.

More details on the algorithm can be found by following this link.

The filter accepts 8 bpp grayscale images and 24/32 bpp color images for processing.

Sample usage:

// create filter BilateralSmoothing filter = new BilateralSmoothing( ); filter.KernelSize = 7; filter.SpatialFactor = 10; filter.ColorFactor = 60; filter.ColorPower = 0.5; // apply the filter filter.ApplyInPlace( image );

Initial image:

Result image:

상속: BaseUsingCopyPartialFilter
파일 보기 프로젝트 열기: holisticware-admin/MonoVersal.AForgeNET 1 사용 예제들

공개 메소드들

메소드 설명
BilateralSmoothing ( ) : System

Initializes a new instance of the BilateralSmoothing class.

보호된 메소드들

메소드 설명
ProcessFilter ( UnmanagedImage source, UnmanagedImage destination, Rectangle rect ) : void

Process the filter on the specified image.

비공개 메소드들

메소드 설명
InitColorFunc ( ) : void
InitFilter ( ) : void
InitSpatialFunc ( ) : void
ProcessWithEdgeChecks ( UnmanagedImage source, UnmanagedImage destination, Rectangle rect ) : void
ProcessWithoutChecks ( UnmanagedImage source, UnmanagedImage destination, Rectangle rect ) : void
ProcessWithoutChecksParallel ( UnmanagedImage source, UnmanagedImage destination, Rectangle rect ) : void

메소드 상세

BilateralSmoothing() 공개 메소드

Initializes a new instance of the BilateralSmoothing class.
public BilateralSmoothing ( ) : System
리턴 System

ProcessFilter() 보호된 메소드

Process the filter on the specified image.
protected ProcessFilter ( UnmanagedImage source, UnmanagedImage destination, Rectangle rect ) : void
source UnmanagedImage Source image data.
destination UnmanagedImage Destination image data.
rect System.Drawing.Rectangle Image rectangle for processing by the filter.
리턴 void