Wiki Page Content

Differences between revisions 1 and 2
Revision 1 as of 2010-06-07 01:25:43
Size: 914
Editor: SheenaSmith
Comment: create page, add content (Wed Mar 10 ver; changeset 4428)
Revision 2 as of 2010-06-24 20:53:51
Size: 1049
Editor: SheenaSmith
Comment: add content from old wiki
Deletions are marked like this. Additions are marked like this.
Line 6: Line 6:
Use this function to create [[SDL_RWops]] structures from memory. Use this function to create an SDL_RWops structure from memory of a certain size.
<<Color2(green,Currently no SDL_RWops page so no link.)>>
Line 17: Line 18:
||'''mem'''||^a pointer to the memory location containing the information to fill an [[SDL_RWops]] structure with^|| ||'''mem'''||^a pointer to the memory location^||
Line 21: Line 22:
A pointer to the [[SDL_RWops]] structure that is created. A pointer to the SDL_RWops structure that is created, or NULL on failure.
Line 25: Line 26:
You can add your code example here char bitmap[310000];
SDL_RWops *rw;

rw = SDL_RWFromMem(bitmap, sizeof(bitmap));
SDL_SaveBMP_RW(screen, rw, 0);
Line 29: Line 34:
''You can add useful comments here'' If the memory is not writable, use [[SDL_RWFromConstMem]]() instead.
Line 36: Line 41:

DRAFT

SDL_RWFromMem

Use this function to create an SDL_RWops structure from memory of a certain size. green

Syntax

SDL_RWops* SDL_RWFromMem(void* mem,
                         int   size)

Function Parameters

mem

a pointer to the memory location

size

the size of the memory location ???

Return Value

A pointer to the SDL_RWops structure that is created, or NULL on failure.

Code Examples

char bitmap[310000];
SDL_RWops *rw;

rw = SDL_RWFromMem(bitmap, sizeof(bitmap));
SDL_SaveBMP_RW(screen, rw, 0);

Remarks

If the memory is not writable, use SDL_RWFromConstMem() instead.


CategoryAPI, CategoryIO

None: SDL_RWFromMem (last edited 2015-06-20 20:00:06 by PhilippWiesemann)

(Page Info.)
Feedback
Please include your contact information if you'd like to receive a reply.
Submit