Kinect For Windows SDK v1.0 - 底座马达移动

放置一个textbox1 一个button,则点击事件为

 private void button1_Click(object sender, RoutedEventArgs e)
        {
            int angle = Convert.ToInt32(textBox1.Text);
            if (angle>=kinectSensorChooser1.Kinect.MinElevationAngle&&angle<=kinectSensorChooser1.Kinect.MaxElevationAngle)
            kinectSensorChooser1.Kinect.ElevationAngle = angle;
        }

其中角度值范围是 [±27]

值得注意的是,微软不推荐在30秒内多次转动,以免烧坏脆弱的马达 偷笑

你可能感兴趣的:(windows,object,button,textbox)