| SDL_mixer: loops and fade out don't play together |
| SDL_mixer: loops and fade out don't play together |
|
Aki Koskinen
Guest
|
Aki Koskinen wrote:
As I got no immediate response to this I went on and assumed that I'm using the mixer library correctly and there is a bug. So I made a change to mixer.c to about line 192 and added mix_channel[i].looping = 0; to the code that is executed when the fade out is completed. This seemed to make the mixer behave as I was expecting. The patch to mixer.c looks like this --- SDL_mixer-1.2.8.orig/mixer.c 2007-07-21 09:37:59.000000000 +0300 +++ SDL_mixer-1.2.8/mixer.c 2008-07-30 18:23:21.000000000 +0300 @@ -186,6 +186,7 @@ if( ticks > mix_channel[i].fade_length ) { if( mix_channel[i].fading == MIX_FADING_OUT ) { mix_channel[i].playing = 0; + mix_channel[i].looping = 0; mix_channel[i].expire = 0; Mix_Volume(i, mix_channel[i].fade_volume); /* Restore the volume */ _Mix_channel_done_playing(i); As can be seen I'm not using the latest svn version but mixer.c hasn't changed that much from my version. I would still like to hear a second opinion about all this. Cheers, - Aki - |
|||||||||||||
|
|
||||||||||||||
| SDL_mixer: loops and fade out don't play together |
|
Aki Koskinen
Guest
|
Aki Koskinen wrote:
I found out that the same problem is present also in a few other locations in mixer.c. The current patch that I have is attached.
This still applies though. - Aki - -------------- next part -------------- A non-text attachment was scrubbed... Name: SDL_mixer-1.2.8-set_looping_to_zero.patch Type: text/x-patch Size: 1321 bytes Desc: not available URL: <http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20080804/f2688de5/attachment.bin> |
|||||||||||||||||
|
|
||||||||||||||||||

