This forum contains outdated content and is available for reading only. Please contact technical support if you have any questions.

Notification

Icon
Error

Options
Go to last post Go to first unread
san  
#1 Posted : Tuesday, September 12, 2006 4:54:36 AM(UTC)
san

Rank: Member

Groups: Guest
Joined: 8/1/2006(UTC)
Posts: 33

Dear Alex,

Is this possible to display two iamge in single bitmap viewer.

and i m also unable to set the back color property to Transparent.

Is it possible or this is not possible in this version.

still my problem is not solved to combine two image into a single template ,

for ref. PLease take a template iage having two area to insert the two image and two diff image and try to merge this two image into the Template,

PLZ Reply as soon as Possible,

THANX

san

Alex Kon  
#2 Posted : Tuesday, September 12, 2006 8:01:47 PM(UTC)
Alex Kon

Rank: Advanced Member

Groups: Guest
Joined: 1/31/2005(UTC)
Posts: 458

Was thanked: 5 time(s) in 5 post(s)
Hello San,

No, it is not possible to display two images at the same time in BitmapViewer or set background color of the control to transparent color.

Following code sample shows how to merge two photos into one background using mask. See attached files for source and result images.

Code:
'Source images
Dim photo0 As New Aurigma.GraphicsMill.Bitmap("Y:\FramesSample\photo0.jpg")
Dim photo1 As New Aurigma.GraphicsMill.Bitmap("Y:\FramesSample\photo1.jpg")
Dim mask As New Aurigma.GraphicsMill.Bitmap("Y:\FramesSample\mask.jpg")
Dim background As New Aurigma.GraphicsMill.Bitmap("Y:\FramesSample\background.jpg")
			
'Placeholder coordinates
Dim point0, point1 As System.Drawing.Point
point0 = New System.Drawing.Point(170, 140)
point1 = New System.Drawing.Point(600, 400)
			
'Combine with first image
Dim combiner As New Aurigma.GraphicsMill.Transforms.Combiner
combiner.CombineMode = Aurigma.GraphicsMill.Transforms.CombineMode.Copy
combiner.SourceBitmap = photo0
combiner.SourceRectangle = New System.Drawing.RectangleF(0, 0, photo0.Width, photo0.Height)
combiner.DestinationRectangle = New System.Drawing.RectangleF(point0.X - photo0.Width / 2, point0.Y - photo0.Height / 2, photo0.Width, photo0.Height)
combiner.ApplyMaskTransform(background, mask)
			
'Combine with second image
combiner.SourceBitmap = photo1
combiner.SourceRectangle = New System.Drawing.RectangleF(0, 0, photo1.Width, photo1.Height)
combiner.DestinationRectangle = New System.Drawing.RectangleF(point1.X - photo1.Width / 2, point1.Y - photo1.Height / 2, photo1.Width, photo1.Height)
combiner.ApplyMaskTransform(background, mask)
			
background.Save("Y:\FramesSample\Result.jpg")

Edited by user Wednesday, December 19, 2007 2:48:19 PM(UTC)  | Reason: Not specified

Alex Kon attached the following image(s):
background.jpg
mask.jpg
photo0.jpg
photo1.jpg
Result.jpg
Users browsing this topic
Guest (2)
Similar Topics
Clear bitmap viewer (Discussions – Graphics Mill)
by NormanL 9/7/2012 12:46:20 AM(UTC)
Rotating a zoomed image in bitmap Viewer (Discussions – Graphics Mill)
by erwinrichard 1/7/2009 4:43:30 AM(UTC)
Hosting the bitmap viewer user control in IE. (Discussions – Graphics Mill)
by joeshearn 3/19/2008 7:43:27 PM(UTC)
Bitmap viewer (Discussions – Graphics Mill)
by san 9/1/2006 8:06:29 PM(UTC)
Bitmap Viewer (Discussions – Graphics Mill)
by san 9/1/2006 4:31:49 PM(UTC)
Bitmap Viewer (Discussions – Graphics Mill)
by san 8/29/2006 2:17:29 PM(UTC)
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.