IrrKlang

BlitzMax Forums/Brucey's Modules/IrrKlang

Stu_ovine(Posted 2008) [#1]
Using the IrrKlangaudio (BRL.Audio module).

There is an issue with the engine not being able to reference an already loaded sample. i.e. if the sample is already loaded and you issue a loadsound again elsewhere in the app, it returns a NULL instead of the already loaded sample.

Easy to illustrate


Local sound:TSound = LoadSound("../../irrklang.mod/examples/media/getout.ogg", SOUND_LOOP)
Local sound2:TSound = LoadSound("../../irrklang.mod/examples/media/getout.ogg", SOUND_LOOP)

PlaySound(sound)
PlaySound(sound2)   ' <<<< error as sound2 = NULL



Tis only a suggestion to return the already loaded sample reference. Im doing it in code - just nice if it were already int he wrapper :)


Brucey(Posted 2008) [#2]
Sorted in the irrKlang module. You'll get a "new" TSound object, but the internal reference will point to the same sound source. Should work for both the file-based and memory (incbin::) based sounds.

Check out SVN for the update. (I'm going to package up irrKlang 1.1.0 before I do a full release.)