[openal] noise glitch upon execution of alcDestroyContext function

Damon Curry damon.curry at whirlwind3d.com
Sun Jan 11 10:24:49 EST 2015


I have noticed an audio anomaly using OpenAL Soft 1.16. The problem is a 
"chook" sound (a short chirp of a sort) that occurs as a program using 
OpenAL Soft terminates. The problem can be duplicated easily, as 
described below.

I slightly modified the example "alstream.c" program (delivered in the 
"examples" directory of OpenAL Soft 1.15, though I am testing with 
OpenAL Soft 1.16). My only modification was to hardcode the path and 
name of an audio file to play, rather than accepting that info as an 
argument to the executable program. The slightly modified program works 
as expected and plays the audio file just fine. However, as the program 
terminates, an extra noise burst, a "chook" sound, comes from the 
speakers. By comparison, playing the same audio file with WinAmp sounds 
the same except there is no "chook" at the end.

"alstream.c", just before terminating, calls "CloseAL()" and that's when 
the unexpected sound (noise) occurs. Using breakpoints and stepping 
through the CloseAL() function, I found that the strange "chook" sound 
happens upon execution of "alcDestroyContext(ctx)". This can be verified 
easily by setting a breakpoint at that function call, in which case the 
audio file will play to completion (without the "chook" sound) and then 
when the breakpoint is passed (perhaps many seconds or minutes later), 
alcDestroyContext will execute and the speakers will spurt out the 
"chook" sound.

I tested with a very short audio clip from the fantastic movie, "The Day 
The Earth Stood Still." The clip is labeled "Peace" and is available 
online at http://www.wavsource.com/movies/day_earth_stood_still.htm

Playing the WAV file listed above in an OpenAL Soft program should 
reveal the audio glitch that I've described. I'm hoping that this 
information will be useful to OpenAL Soft developers.



More information about the openal mailing list