HowTo: Upgrade Kinect Audio Positioning code from older Beta SDK
Exploring the Kinect SDK v1.8 Developer Toolkit Browser application, I noticed some audio positioning visualizations at various samples (specifically at Audio Basics, Audio Explorer and Kinect Explorer samples), but I kept on looking for some simpler/cleaner sample code to return audio positioning info that would be easier to reuse.
So I can across http://kinectaudioposition.codeplex.comthat looked like a good candidate, since it was defining a reusable KinectMicArray class to return the BeamAngle and SoundSourceAngle’s of a KinectAudioSource. There was also some sample code on how to use that KinectMicArray class at http://channel9.msdn.com/coding4fun/kinect/Kinect-Audio-Positioning
However, after downloading it, I realized it was written (hadn’t seen the notice it had on its page) for an older Kinect Beta SDK version. So I decided to port that code to Kinect SDK v1.8 (which is the latest Kinect SDK version to support Kinect for Windows v1.0 and Kinect for Xbox 360 sensors, since the newer Kinect SDK supports KfW v2.0 and Kinect for Xbox One – in fact KfW v2.0 is now “merged” with the Kinect for Xbox One product via the use of an external adapter with the later to connect to a PC).
During that code porting to Kinect SDK v1.8 I noticed the following issues that had to be addressed. At the older Kinect Beta SDK:one could instantiate a KinectAudioSource class directly instead of having to get it from a started KinectSensor, plus the object was disposable so one could place it in "using" clause one could do audioSource.SystemMode = SystemMode.OptibeamArrayOnly (that property doesn’t seem to be available anymore to set) audioSource.BeamAngleChanged was called BeamChanged audioSource.SoundSourceAngleChanged probably didn’t exist (have seen older code use a BackgroundWorker and do polling) audioSource.SoundSourceAngleConfidence was called SoundSourcePositionConfidence audioSource.SoundSourceAngle was called SoundSourcePosition audioSource.BeamAngle and audioSource.SoundSourceAngle (then called SoundSourcePosition) were returning radians instead of degrees (so one usually had to convert to degrees using 180.0 * rad / Math.PI)
I took the chance to cleanup and refactor the original code and XAML and since the original codeplex site just had a single download and not any source code in the repository to fork, I uploaded the whole thing ZIPed under their source code / patches area.
- 3Apache自带 ab压测工具 Windows配置使用说明
- 4【iOS干货】☞ 定位
- 9“前”方有坑，绕道而行（一）-- H5+CSS