Does anyone have a sample code for this? I want to draw an image in memory
into another image using C# and win32 gdi.. if its confusing i'll rephrase
it. I want to draw many images into one image in memory using win32 gdi
(sample using bitblt or any suggested win32 that works the fastest) since the
.NET gdi is very slow in drawing graphics in my own opinion. I would really
appreciate any help. please any smaple code at all would be very much
approciated. Thank You so much in advace.

Stan

Re: win32 in memory by Patrice

Patrice
Tue Apr 11 07:53:41 CDT 2006

Googling for dllImport BitBlt will return pages such as
http://www.codeproject.com/csharp/cscapturescreen1.asp. It should be fairly
easy to start from this...

If not done, I would also post about the first point in case someone would
find something particular in the code that doesn't perform well (stretching
with quality favored over performance ?)...


--

"Rain" <Rain@discussions.microsoft.com> a écrit dans le message de news:
8E2C0612-0E84-42DB-979F-C6BB1647255E@microsoft.com...
> Does anyone have a sample code for this? I want to draw an image in memory
> into another image using C# and win32 gdi.. if its confusing i'll
> rephrase
> it. I want to draw many images into one image in memory using win32 gdi
> (sample using bitblt or any suggested win32 that works the fastest) since
> the
> .NET gdi is very slow in drawing graphics in my own opinion. I would
> really
> appreciate any help. please any smaple code at all would be very much
> approciated. Thank You so much in advace.
>
> Stan



Re: win32 in memory by Rain

Rain
Tue Apr 11 11:00:01 CDT 2006

HI Patrice thanks for the link but i already saw this earlier (been googling
too) but it wasnt of any help of what i wanted to do. I wouldnt be asking in
this forum without having to go through a research first.. hehe Thanks
anyway.

What i was looking for was a win32 gdi version of this code:

Bitmap bmp = new Bitmap(100,100);

using(Graphics g = Graphics.FromImage(bmp))
{
g.Clear(Color.Black);
g.DrawLine(Pens.Red,0,0,99,99);
g.DrawLine(Pens.Blue, 0,99,99,0);
g.DrawImage(@"C:\pic1.jpg", 0, 0, 100, 200); // adds an image to the bmp image
g.Save();
}
.....
return the bmp to the screen

"Patrice" wrote:

> Googling for dllImport BitBlt will return pages such as
> http://www.codeproject.com/csharp/cscapturescreen1.asp. It should be fairly
> easy to start from this...
>
> If not done, I would also post about the first point in case someone would
> find something particular in the code that doesn't perform well (stretching
> with quality favored over performance ?)...
>
>
> --
>
> "Rain" <Rain@discussions.microsoft.com> a écrit dans le message de news:
> 8E2C0612-0E84-42DB-979F-C6BB1647255E@microsoft.com...
> > Does anyone have a sample code for this? I want to draw an image in memory
> > into another image using C# and win32 gdi.. if its confusing i'll
> > rephrase
> > it. I want to draw many images into one image in memory using win32 gdi
> > (sample using bitblt or any suggested win32 that works the fastest) since
> > the
> > .NET gdi is very slow in drawing graphics in my own opinion. I would
> > really
> > appreciate any help. please any smaple code at all would be very much
> > approciated. Thank You so much in advace.
> >
> > Stan
>
>
>