The SDL forums have moved to discourse.libsdl.org.
This is just a read-only archive of the previous forums, to keep old links working.


SDL Forum Index
SDL
Simple Directmedia Layer Forums
Displaying raw binary data on SDL screen from memory
Bender


Joined: 19 Oct 2014
Posts: 1
Hi to all,
I've been lately busy writing an emulator for the past few months and currently implementing video support.
Like most implementations mine uses the concept of a buffer where the program can write to. The contents of this
buffer would be displayed on the screen.
Now the problem here is, that the buffer contains raw binary data, which carries no specific format else I could've easily used SDL_RWFromMem. Tried it already IMG_LOAD_RW returns with NULL, with an unrecognisable format message. Think of it as a DOS program writing to video memory, and I'm supposed to display it on a SDL_Surface