public AudioIn_KinectXbox(FIFOStream stream) { mStream = stream; mSrc = new KinectAudioSource(); mSrc.SystemMode = SystemMode.OptibeamArrayOnly; mThread = new Thread(new ThreadStart(KinectThreadProc)); mRunningEvent = new ManualResetEvent(false); mRunning = false; }
public AudioOut(FIFOStream stream) { mStream = stream; mStream.DataAvailable += mStream_DataAvailable; WaveFormat fmt = new WaveFormat(16000, 16, 1); mBuffOut = new BufferedWaveProvider(fmt); mBuffOut.DiscardOnBufferOverflow = true; mWaveOut = new WaveOutEvent(); mWaveOut.Init(mBuffOut); mPlaying = false; //start player thread mPlayEvent = new ManualResetEvent(false); mPlayer = new Thread(new ThreadStart(ThreadProc)); mPlayer.Priority = ThreadPriority.AboveNormal; mPlayer.Start(); }