SDL Wiki
(This function is part of SDL_mixer, a separate library from SDL.)


Load a WAV file from memory as quickly as possible.

Header File

Defined in <SDL_mixer.h>


Mix_Chunk * Mix_QuickLoad_WAV(Uint8 *mem);

Function Parameters

Uint8 * mem memory buffer containing of a WAV file.

Return Value

(Mix_Chunk *) Returns a new chunk, or NULL on error.


Unlike Mix_LoadWAV_RW, this function has several requirements, and unless you control all your audio data and know what you're doing, you should consider this function unsafe and not use it.

This function will do NO error checking! Be extremely careful here!

(Seriously, use Mix_LoadWAV_RW instead.)

If this function is successful, the provided memory buffer must remain available until Mix_FreeChunk() is called on the returned chunk.


This function is available since SDL_mixer 2.0.0.

See Also

CategoryAPI, CategoryAPIFunction

[ edit | delete | history | feedback | raw ]

[ front page | index | search | recent changes | git repo | offline html ]

All wiki content is licensed under Creative Commons Attribution 4.0 International (CC BY 4.0).
Wiki powered by ghwikipp.