CombineExt method (ILEADRasterProcess)

Visual Basic example

Visual C++ 5.0 example

 

Syntax

short CombineExt(ILEADRaster *pRasterDst, float fLeft, float fTop, float fWidth, float fHeight, ILEADRaster *pRasterSrc, float fSrcLeft, float fSrcTop, CombineConstants Flags);

Overview

Refer to Combining Images.

Remarks

Combines image data from two bitmaps, letting you specify the areas to be combined and the operations to be performed when combining the data, and which color planes (R or G or B or R, G, and B) are used.

For example, suppose you use the SpatialFilter method to apply an edge detection filter. You can then use this method to combine the resulting bitmap with the original one to produce an image with hard edges.

This method combines the data pixel-by-pixel. The two images can be any color resolution. Images that are 24-bits per pixel are the easiest and fastest to combine. This method uses Windows-style coordinates (with a top-left origin) to specify the areas to be combined.

If the channel setting for one of the bitmaps is the master channel (CB_SRC_MASTER, CB_DST_MASTER, CB_RES_MASTER) the settings for all the bitmaps will be set to master.

For a simple paste, use CB_OP_ADD and CB_DST_0 as the flags.

If a region is defined for the either the source or destination bitmap, or both bitmaps, the combine applies only to the intersection of the regions.

For example, assume CB_SRC_RED is passed for the source bitmap, CB_DST_BLUE is passed for the destination bitmap and CB_RES_GREEN is passed for the resulting bitmap. In this case, the green channel of the resulting bitmap is calculated as the result of the operations applied to the red channel of the source bitmap and the blue channel of the destination bitmap. The other channels of the resulting bitmap are unchanged.

This method supports 12 and 16-bit grayscale images and 48 and 64-bit color images. Support for 12 and 16-bit grayscale images and 48 and 64-bit color images is available only in the Document/Medical toolkits.

This method does not support signed data images. It returns the error code ERROR_SIGNED_DATA_NOT_SUPPORTED if a signed data image is passed to this method.

See Also

Elements:

Underlay method, Combine method

Topics:

Raster Images: Copying Images

 

Raster Images: Combining Images

 

Implementing Transparency

 

Examining and Altering Bitmaps

 

Removing Noise

 

Detecting and Enhancing Edges and Lines