0

Hi to all,

i have a little problem with my little application. I create a graphic object where i draw a series of text. I create it with

Graphics gg(hdc)

where hdc in the handle context of the screen ( BeginPaint ). Now i want to save this graphics object in the png image file. I try to create a bitmap file from gg with

Bitmap *b = new (w,h,&g)

end then

b->save(L"c:\\tmp.png", &pngclsid, NULL)

, but don't work...

Anyone have the solution?

Thanks lot

Edited by welcomepro: n/a

1
Contributor
1
Reply
3
Views
7 Years
Discussion Span
Last Post by welcomepro
0

Hi to all,

i have a little problem with my little application. I create a graphic object where i draw a series of text. I create it with

Graphics gg(hdc)

where hdc in the handle context of the screen ( BeginPaint ). Now i want to save this graphics object in the png image file. I try to create a bitmap file from gg with

Bitmap *b = new (w,h,&g)

end then

b->save(L"c:\\tmp.png", &pngclsid, NULL)

, but don't work...

Anyone have the solution?

Thanks lot

The problem is the dimension of the BMP, but now, the file is saved but empty...

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.