I Need A Convient Way To Load Raw Bmp Images From Memory To Sdl Image


Don Miguel

Certified Guru
Joined
Aug 13, 2002
Messages
322
Age
19
Location
South Urals
Website
famesoft.ru
I need a convient way to load RAW BMP images from memory to SDL Image format...

Is there a simply way?

i'm going to drop SDL usage at all (in the end)
but now i need it for a rush start ^_-
 
Is it raw as in the pixels are sitting there or raw as in the entire file is loaded in memory?

If you just have the pixels, then you can create an SDL surface from the pixels or lock the surface and memcpy the pixels to the surface (assuming the correct pixel format, heh). If the entire file is in memory, probably best use rwops as described in post above.
 
Back
Top