Tab

ASPxImageGallery.CustomImageProcessing Event

Enables you to custom process an image, e.g., add a watermark, when ASPxImageGallery is bound to a folder or to binary data.

Namespace: DevExpress.Web

Assembly: DevExpress.Web.v21.1.dll

Declaration

public event ImageGalleryCustomImageProcessingEventHandler CustomImageProcessing

Event Data

The CustomImageProcessing event's data class is ImageGalleryCustomImageProcessingEventArgs. The following properties provide information specific to this event:

Property Description
Graphics Provides methods for drawing objects over an image.
Image Provides access to a Bitmap object that is the processed image.
ImageLocation Gets the value specifying the location of the processed image.

Remarks

The CustomImageProcessing event occurs only when the ASPxImageGallery is bound to a folder or to binary data. The event is raised for each image three times (for a thumbnail, a fullscreen viewer image and a fullscreen viewer thumbnail), and enables you to custom process it. For instance, you can handle this event to add a watermark.

The event parameter’s properties allow you to access the processed image (ImageGalleryCustomImageProcessingEventArgs.Image) and to identify the processed image location within the gallery (ImageGalleryCustomImageProcessingEventArgs.ImageLocation). The ImageGalleryCustomImageProcessingEventArgs.Graphics property provides methods for drawing over the image.

See Also