Merges two images according to the specified merge mode.
Syntax
Parameters
- page
- First image to merge. It will contain result image after merging.
- pageToMergeWith
- Second image to merge.
- left
- Left position of the source image on the destination one.
- top
- Top position of the source image on the destination one.
- mode
- Merge mode constant. See ImGearMergeModes enumeration.
Example
// Opens an image and merges it into an already open image.
using (FileStream file = new FileStream("photo.jpg",
FileMode.Open, FileAccess.Read, FileShare.Read))
{
ImGearRasterPage igRasterPageToMerge = (ImGearRasterPage)
ImGearFileFormats.LoadPage(file, 0);
// Subtract the opened image from the existing image.
ImGearRasterProcessing.Merge(igRasterPage, igRasterPageToMerge, 0, 0, ImGearMergeModes.SUB);
}
' Opens an image and merges it into an already open image.
Using file As New FileStream("photo.jpg", FileMode.Open, FileAccess.Read, FileShare.Read)
Dim igRasterPageToMerge As ImGearRasterPage = DirectCast(ImGearFileFormats.LoadPage(file, 0), ImGearRasterPage)
' Subtract the opened image from the existing image.
ImGearRasterProcessing.Merge(igRasterPage, igRasterPageToMerge, 0, 0, ImGearMergeModes.[SUB])
End Using
See Also