audFreeMusic

Frees a loaded music stream from memory. Takes music (music handle from audLoadMusic). Returns nothing.

Audio

Parameters & Returns

Parameters

music Int

Returns

Void

Quick Summary

Frees a loaded music stream from memory. Takes music (music handle from audLoadMusic). Returns nothing.

Technical Exegesis...

Releases the resources used by a music stream loaded with audLoadMusic. The music handle becomes invalid after this call.

Does nothing if the music handle is invalid or <= 0. Always free music when finished to prevent resource leaks. This only frees the music data structure, not any active playback channels.

Example

Example.bam
Local music:Int = audLoadMusic(\"music.ogg\")
Local channel:Int = audPlayMusic(music)

audStopMusic(channel)
audFreeMusic(music)