tags:

views:

79

answers:

4

Using C language

A: 

The Windows API doesn't really have functions to do that sort of image conversion. You may want to look into a library such as ImageMagick.

Greg Hewgill
+1  A: 

Have a look at the Window Imaging Component API. See there.

Gregory Pakosz
http://en.wikipedia.org/wiki/Windows_Imaging_Component says that's only available in Vista and XP SP3.
Greg Hewgill
msdn says it ships with vista and win7 and is downloadable for win xp
Gregory Pakosz
A: 

libpng to load the PNG. libpng sucks, BTW. The API / interface is just god-awful. Design by committee. I think it will have once you've loaded the PNG ways for you to access the pixelbuffer. That's enough - you then can roll your own BMP generator (it's not difficult - just make sure you get pixels in the correct order - I vaguely recall BMP is BGRA and bottom-to-top).

Blank Xavier
+1  A: 

I have only used it via .NET but the underlying standard Windows lib GDI+ might be what you're after. Here's the MSDN intro page

Jacob O'Reilly
Its worth adding that GdiPlus has a C++ AND a C API.
Chris Becke