GdPicture.NET.14.API
GdPicture14 Namespace / GdPictureImaging Class / FxDespeckle Method
GdPicture image identifier.
Example





In This Topic
FxDespeckle Method (GdPictureImaging)
In This Topic
Performs a 3x3 despeckle filter (also known as median filter) on a GdPicture image or on an area of a GdPicture image defined by SetROI() method. It works as a noise removal filter, for Salt-And-Pepper like-noise, or varied dots around a document. It can remove black noise pixels from white backgrounds and visa versa. It also can remove random noise from multicolored backgrounds.
Syntax
'Declaration
 
Public Function FxDespeckle( _
   ByVal ImageID As Integer _
) As GdPictureStatus
public GdPictureStatus FxDespeckle( 
   int ImageID
)
public function FxDespeckle( 
    ImageID: Integer
): GdPictureStatus; 
public function FxDespeckle( 
   ImageID : int
) : GdPictureStatus;
public: GdPictureStatus FxDespeckle( 
   int ImageID
) 
public:
GdPictureStatus FxDespeckle( 
   int ImageID
) 

Parameters

ImageID
GdPicture image identifier.

Return Value

A member of the GdPictureStatus enumeration.
Remarks
This method is used in the "Image Processing" Demo.
Example
Applying a despeckle filter an a jpeg image.
using (GdPictureImaging gdpictureImaging = new GdPictureImaging())
{
    int imageID = gdpictureImaging.CreateGdPictureImageFromFile("image.jpg", false);
    gdpictureImaging.FxDespeckle(imageID);
    gdpictureImaging.SaveAsJPEG(imageID, "processed_image.jpg");
    gdpictureImaging.ReleaseGdPictureImage(imageID);
}
See Also