Exemplo n.º 1
0
        internal static void Stop(AudioStream *pThis)
        {
            lock (API.StopLock)
            {
                OSStatus status = API.AudioQueueDispose(pThis->Queue, 1);
                API.CheckStatus(status);

                status = API.AudioFileClose(pThis->AudioFile);
                API.CheckStatus(status);

                Marshal.FreeHGlobal((IntPtr)pThis);

                Sound.OnDisposeStream(pThis);
            }
        }