Merging images

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

Is it possible to create a new image from two images where the one is merged
onto the other.
 
Jesper,

Yes, it is, but how do you want to perform the merge? In other words,
given one pixel from one image, and one pixel from another image (both at
the same location in the images), how should the resulting pixel look?
 
Hi Nicholas (and thank you for answering so many of my previous questions!)

The two pixel colors shall not be blended. Pixels from, say img1, shall be
overridden with pixels from img2. I.e. img1 will appear to be behind img2.
Img2 must be able to have transparent pixels as img2 not will be rectangular.

I need this becasue I have some different icons for different type of
information nodes in a tree view. For all of these (around 4) different
images, I need to show five different status values, i.e. I'll need to draw
20 different images.

Nicholas Paldino said:
Jesper,

Yes, it is, but how do you want to perform the merge? In other words,
given one pixel from one image, and one pixel from another image (both at
the same location in the images), how should the resulting pixel look?


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

Jesper said:
Hi,

Is it possible to create a new image from two images where the one is
merged
onto the other.
 
In that case, you create an image large enough to hold the largest of the 2
images, draw the first image on it, and then draw the second image on it.

--
HTH,

Kevin Spencer
Microsoft MVP

Printing Components, Email Components,
FTP Client Classes, Enhanced Data Controls, much more.
DSI PrintManager, Miradyne Component Libraries:
http://www.miradyne.net

Jesper said:
Hi Nicholas (and thank you for answering so many of my previous
questions!)

The two pixel colors shall not be blended. Pixels from, say img1, shall be
overridden with pixels from img2. I.e. img1 will appear to be behind img2.
Img2 must be able to have transparent pixels as img2 not will be
rectangular.

I need this becasue I have some different icons for different type of
information nodes in a tree view. For all of these (around 4) different
images, I need to show five different status values, i.e. I'll need to
draw
20 different images.

Nicholas Paldino said:
Jesper,

Yes, it is, but how do you want to perform the merge? In other
words,
given one pixel from one image, and one pixel from another image (both at
the same location in the images), how should the resulting pixel look?


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

message
Hi,

Is it possible to create a new image from two images where the one is
merged
onto the other.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top