Locked Common Audio Problems and FAQ

Locked

  • Thursday, June 16, 2011 7:56 AM
    Owner
     
     

    This is a listing of answers to Frequently Asked Questions and workarounds for common problems.

     

    1. Problem: COM exception when using KinectAudioSource
    Characteristics: Most commonly seen in Visual Basic as a COM casting error, but can also be seen in multithreaded C# applications.
    Solution: Make sure thread is marked with [MTAThread] attribute and not [STAThread] attribute, since underlying COM object only supports multi-threaded apartments. Note that Visual Basic threads are STA by default and C# threads are MTA by default.

    2. Problem: Audio processing fails when using Acoustic Echo Cancellation
    Characteristics: Can be seen in MicArrayEchoCancellation sample as an error returned by IMediaObject->ProcessOutput
    Solution: Make sure speakers are producing sound by, e.g.: playing a tune on Windows Media (r) Player before running the application. This is necessary because AEC algorithm takes speaker output as input in order to cancel interfering sounds.

    3. Question: What is the difference between SoundSourcePosition and MicArrayBeamAngle?
    Answer: SoundSourcePosition is the current best guess for the direction of sound source, whereas MicArrayBeamAngle is the direction at which the Kinect is actually listening. They are not the same because the beamforming algorithm only has 11 beam directions predefined at regular 10 degree intervals.