GdPicture image identifier.
Height, in pixel, to remove from the top of a GdPicture image.
Example





In This Topic

CropTop Method (GdPictureImaging)

In This Topic
Crops the top of a GdPicture image.
Syntax
'Declaration
 
Public Function CropTop( _
   ByVal ImageID As Integer, _
   ByVal Lines As Integer _
) As GdPictureStatus
public GdPictureStatus CropTop( 
   int ImageID,
   int Lines
)
public function CropTop( 
    ImageID: Integer;
    Lines: Integer
): GdPictureStatus; 
public function CropTop( 
   ImageID : int,
   Lines : int
) : GdPictureStatus;
public: GdPictureStatus CropTop( 
   int ImageID,
   int Lines
) 
public:
GdPictureStatus CropTop( 
   int ImageID,
   int Lines
) 

Parameters

ImageID
GdPicture image identifier.
Lines
Height, in pixel, to remove from the top of a GdPicture image.

Return Value

A member of the GdPictureStatus enumeration.
Example
Cropping 10 lines from the top of the image.
using (GdPictureImaging gdpictureImaging = new GdPictureImaging())
{
    int imageID = gdpictureImaging.CreateGdPictureImageFromFile("image.jpg");
 
    // Crop 10 lines from the top of the image.
    gdpictureImaging.CropTop(imageID, 10);
 
    gdpictureImaging.SaveAsPNG(imageID, "output.png");
 
    gdpictureImaging.ReleaseGdPictureImage(imageID);
}
See Also