Leak which causes sounds to play after program is closed...

Post your questions, suggestions and experiences regarding game design, integration of external libraries here. For irrEdit, irrXML and irrKlang, see the
ambiera forums
Post Reply
Dances
Posts: 454
Joined: Sat Jul 02, 2005 1:45 am
Location: Canada
Contact:

Leak which causes sounds to play after program is closed...

Post by Dances »

I am using both Irrlicht and IrrKlang in my program. When someone closes the program with the quit button the music stops playing, but if they use the 'x' button the music continues to play until you stop it with task manager.

I am using ESOD_WIN_MM (though removing this makes no difference) and calling or not calling update() seems to have no effect
The issue was not appearant without irrKlang (when the program was just Irrlicht, as I could compile after running without using taskman to kill the exe).

It may be of consequence I am using main not winmain...
niko
Site Admin
Posts: 1759
Joined: Fri Aug 22, 2003 4:44 am
Location: Vienna, Austria
Contact:

Post by niko »

If you don't shut down the engine (usually done calling engine->drop()) it will continue to play. And it looks like you don't call this when the user presses the 'x' button :)
Dances
Posts: 454
Joined: Sat Jul 02, 2005 1:45 am
Location: Canada
Contact:

Post by Dances »

Right; I had no idea how to do that because I am clueless when it comes to windows programming, but I seem to have found a tutorial.
Thanks, Niko.
I didn't think the problem was on your end ^.^
Post Reply