|
-
January 31st, 2003, 01:48 PM
#1
Bitmap / Image Concat'ing
Could someone tell me how, using the Bitmap or Image classes, I can take a bitmap and append on to the end of another bitmap. Also, the bitmap's will have the same width. I just need to append another image to the end of the previous one in memory. I noticed there is an Image.FromStream function but I'm still lost as to how to append it onto another image...
Thanks,
- J
-
January 31st, 2003, 03:40 PM
#2
[FONT=arial][SIZE=3]
2 Ways
[SIZE=1]
Method 1:
Create a new bitmap and copy from 2 bitmap pixel wise pixel.
(make sure you check for processing speed)
Method 2 :
render the two bitmap halves onto another bitmap
for example,
Bitmap dstBitmap = new Bitmap(width, height);
using(Graphics g = Graphics.FromImage(dstBitmap))
{
g.DrawImage(srcBitmap1,dstX1,dstY1,scrRect1,GraphicsUnit.Pixel);
g.DrawImage(srcBitmap2,dstX2,dstY2,scrRect2,GraphicsUnit.Pixel);
}
IMO this should work more elegant
let me know if this works for you
Paresh
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|