You are an experienced programmer and have a problem with the engine, shaders, or advanced effects? Here you'll get answers. No questions about C++ programming or topics which are answered in the tutorials!
Does anyone have any codelettes to do this?
And yes, it has to be from an HBITMAP, seeing as I'm working with window screenshots. Saving to a BMP just to load it again 500 times a second would be bad for the hard drive.
You can create a texture in irrlicht and then lock it, which gives you a pointer to the pixels array, and then you can load in the HBITMAP pixels (whatever a HBITMAP is...).
JP wrote:You can create a texture in irrlicht and then lock it, which gives you a pointer to the pixels array, and then you can load in the HBITMAP pixels (whatever a HBITMAP is...).
Well HBITMAP is just the Win32 structure to hold bitmap files. Really I don't get at all why this is needed. You could save the picture, keep it in memory, and not have to load it 500 times per second...what exactly are you trying to accomplish because there isn't anything you couldn't do with IImage that you can with HBITMAP.
A) It's a picture that in some cases, WILL change 60 times a second.
B) It's more than just 1 picture, it's about 1-50.
C) It's generated through a Windows API call: A window screenshot.
I don't think I can change how Windows API returns data directly
Oh yeah, i was looking at the HBITMAP struct recently. If you check the msdn then you'll be able to see what the struct actually contains and you'll then be able to load it into irrlicht in the way i suggested.