[SDL] Using MSVC Bitmap Resource with SDL_Image
Andreas K. Foerster
list at akfoerster.de
Fri Jul 27 11:01:45 PDT 2007
Am Friday, dem 27. Jul 2007 schrieb Peter Mackay:
> Yet another alternative is to use a program like "bin2c" (quite easy
> to find using Google) to convert your .bmp file to a .c/.h file
> containing a static array of chars (the original file's contents).
>
> Then you can use SDL's RWops function to load the file from memory.
I use that too.
Here is how:
image = SDL_LoadBMP_RW (SDL_RWFromMem (img, imgsize), 1);
--
AKFoerster
More information about the SDL
mailing list