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





In This Topic
KeepBlueComponent Method (GdPictureImaging)
In This Topic
Keeps only the blue color component of a GdPicture image or of an area of a GdPicture image defined by SetROI() method.
Syntax
'Declaration
 
Public Function KeepBlueComponent( _
   ByVal ImageID As Integer _
) As GdPictureStatus
public GdPictureStatus KeepBlueComponent( 
   int ImageID
)
public function KeepBlueComponent( 
    ImageID: Integer
): GdPictureStatus; 
public function KeepBlueComponent( 
   ImageID : int
) : GdPictureStatus;
public: GdPictureStatus KeepBlueComponent( 
   int ImageID
) 
public:
GdPictureStatus KeepBlueComponent( 
   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
Filtering a jpeg image so only the blue component is kept.
using (GdPictureImaging gdpictureImaging = new GdPictureImaging())
{
    int imageID = gdpictureImaging.CreateGdPictureImageFromFile("image.jpg", false);
 
    // Keep only the blue color component.
    gdpictureImaging.KeepBlueComponent(imageID);
    gdpictureImaging.SaveAsJPEG(imageID, "image.jpg", 75);
    gdpictureImaging.ReleaseGdPictureImage(imageID);
}
See Also