Sample 16 - Merging with a transparent Image. Merging 2 images
> Merge.vbs
>     Dim im
>     Set im = CreateObject("ActiveImage.Images.1")
>     im.SetImageType 1
>     im.ReadFromFile "C:\AI\rose.jpg"
>     wrose = im.GetWidth
>     hrose = im.GetHeight

>     im.SetImage 1
>     im.SetImageType 3
>     im.ReadFromFile "C:\AI\target.gif"
>     w = im.GetWidth
>     h = im.GetHeight
>     x1 = wrose/2 - w/2
>     y1 = hrose/2 - h/2
>     im.CopyImageMerge 0,1,CInt(x1),CInt(y1),0,0,w,h,100

>     im.SetImage 0
>     im.SetImageType 1
>     im.WriteToFile "C:\AI\merge.jpg"
>     im.DestroyImage
>     im.SetImage 1
>     im.DestroyImage

>     Set im = Nothing
> Picture 1. rose.jpg (size - 7 Kb) | Picture 2. target.gif (transparent, size - 4 Kb)
> Picture 3. megre.jpg (size - 9 Kb) |
If you have any questions or bug reports, write to active.image@tonec.com for technical support.
| © 2000-2001 All Rights Reserved Tonec Inc., 16835 Algonquin Street #400, Huntington Beach, CA, 92649, fax: (509) 752-1450, e-mail: info@tonec.com