lol, LoadImage & LoadBitmap don't work for me either I don't know how to use resources!?
Benny thanks for that, I will take a look at it. The CreateFile, CreateFileMapping and MapViewOfFile do exactly (I think) , the same thing, -returns a pointer to the start of the file, except with this, windows looks after the memory management etc.
I was having a problem trying to get to the Header files, how to read them,- where are they? but I think I've got it now.
Do you have to do the SetDIBits part? My book "Graphics programming in C++" (for windows) -Mark Walmsley, doesn't have that in it at all, it does say though, that the last two params of CreateDiBSection, "cause the file image bits to be incorporated into the new bitmap".- I presume that would mean the file you have just loaded?
In case you might find it useful CreateDiBSection() allows you to get a pointer to the actual pixels, so you can change them/do things with them.
On the subject of loading/reading files, does this mean you could do something similar with any type of file? I got really confused with the whole bit, but being able to read files like this could be quite useful. Have you any tips on the best ways to do it.