• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C# Toolkit.KinectSensorChooser类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中Microsoft.Kinect.Toolkit.KinectSensorChooser的典型用法代码示例。如果您正苦于以下问题:C# KinectSensorChooser类的具体用法?C# KinectSensorChooser怎么用?C# KinectSensorChooser使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



KinectSensorChooser类属于Microsoft.Kinect.Toolkit命名空间,在下文中一共展示了KinectSensorChooser类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: MainWindow

        /// <summary>
        /// Initializes a new instance of the <see cref="MainWindow"/> class. 
        /// </summary>
        public MainWindow()
        {
            this.InitializeComponent();

            // initialize the sensor chooser and UI
            this.sensorChooser = new KinectSensorChooser();
            this.sensorChooser.KinectChanged += SensorChooserOnKinectChanged;
            this.sensorChooserUi.KinectSensorChooser = this.sensorChooser;
            this.sensorChooser.Start();

            // Bind the sensor chooser's current sensor to the KinectRegion
            var regionSensorBinding = new Binding("Kinect") { Source = this.sensorChooser };
            BindingOperations.SetBinding(this.kinectRegion, KinectRegion.KinectSensorProperty, regionSensorBinding);

            // Clear out placeholder content
            this.wrapPanel.Children.Clear();

            // Add in display content
            for (var index = 0; index < 300; ++index)
            {
                var button = new KinectTileButton { Label = (index + 1).ToString(CultureInfo.CurrentCulture) };
                this.wrapPanel.Children.Add(button);
            }

            // Bind listener to scroll viewer scroll position change, and check scroll viewer position
            this.UpdatePagingButtonState();
            scrollViewer.ScrollChanged += (o, e) => this.UpdatePagingButtonState();
        }
开发者ID:flyfj,项目名称:KinectStudio,代码行数:31,代码来源:MainWindow.xaml.cs


示例2: ApplesGameConfigPage

 public ApplesGameConfigPage(string itemId, KinectSensorChooser kinectSensor)
 {
     InitializeComponent();
     _kinectSensor = kinectSensor;
     Config = new ApplesGameConfig();
     DataContext = Config;
 }
开发者ID:guozanhua,项目名称:KinectMiniGames,代码行数:7,代码来源:ApplesGameConfigPage.xaml.cs


示例3: LettersGameConfigPage

 public LettersGameConfigPage(string itemId, KinectSensorChooser sensorChooser)
 {
     InitializeComponent();
     SensorChooser = sensorChooser;
     Config = new LettersGameConfig();
     DataContext = Config;
 }
开发者ID:guozanhua,项目名称:KinectMiniGames,代码行数:7,代码来源:LettersGameConfigPage.xaml.cs


示例4: MainMenu

        public MainMenu()
        {
            InitializeComponent();

            // initialize the sensor chooser and UI
            if (Generics.GlobalKinectSensorChooser == null)
            {
                this.sensorChooser = new KinectSensorChooser();
                this.sensorChooser.KinectChanged += SensorChooserOnKinectChanged;
                this.sensorChooserUi.KinectSensorChooser = this.sensorChooser;
                this.sensorChooser.Start();
                Generics.GlobalKinectSensorChooser = this.sensorChooser;
            }
            else
            {
                this.sensorChooser = new KinectSensorChooser();
                this.sensorChooser = Generics.GlobalKinectSensorChooser;
                this.sensorChooser.KinectChanged += SensorChooserOnKinectChanged;
                this.sensorChooserUi.KinectSensorChooser = sensorChooser;
            }

            // Bind the sensor chooser's current sensor to the KinectRegion
            var regionSensorBinding = new Binding("Kinect") { Source = this.sensorChooser };
            BindingOperations.SetBinding(this.kinectRegion, KinectRegion.KinectSensorProperty, regionSensorBinding);
        }
开发者ID:jiaoyang813,项目名称:MediaHomeCenter,代码行数:25,代码来源:MainMenu.xaml.cs


示例5: initKinectInteraction

 public void initKinectInteraction()
 {
     this.sensorChooser = new KinectSensorChooser();
     this.sensorChooser.KinectChanged += SensorChooserOnKinectChanged;
     this.sensorChooserUi.KinectSensorChooser = this.sensorChooser;
     this.sensorChooser.Start();
 }
开发者ID:Minimata,项目名称:MainProjectIntegrationP1,代码行数:7,代码来源:MainWindow.xaml.cs


示例6: LevelOne

 public LevelOne(KinectSensorChooser sensorChooser)
 {
     InitializeComponent();
     sensorChooser = this.sensorChooser;
     Loaded += OnLoaded;
     long playerpos = Convert.ToInt64(player.GetValue(Canvas.LeftProperty));
 }
开发者ID:IzzyAhmad,项目名称:esilk_kinect,代码行数:7,代码来源:LevelOne.xaml.cs


示例7: StatesScreen

 public StatesScreen(Window MainWindow, KinectSensorChooser SensorChooser, Constants.TimeZones TimeZone)
 {
     // Get the main window and sensor objects
     this.mainWindow = MainWindow;
     this.sensorChooser = SensorChooser;
     // Populate the states based on TimeZone parameter
     this.timeZone = TimeZone;
     this.states = PopulateStates(TimeZone);
     #if (DEBUG)
     Console.WriteLine(TimeZone.ToString() + " states loading...");
     foreach (Utilities.State s in this.states)
     {
         Console.WriteLine(s);
     }
     Console.WriteLine("..." + TimeZone.ToString() + " states loaded!");
     #endif
     // Initialize display containers
     CreateContentGrid();
     CreateKinectRegion();
     CreateInfoGrid();
     CreateKinectScrollViewer();
     // Set up the display
     Grid.SetColumn(this.infoGrid, 0);
     Grid.SetRow(this.infoGrid, 0);
     this.content.Children.Add(this.infoGrid);
     this.kRegion.Content = this.statesKSV;
     Grid.SetColumn(this.kRegion, 0);
     Grid.SetRow(this.kRegion, 1);
     this.content.Children.Add(this.kRegion);
     // Bind the Kinect sensor
     //var regionSensorBinding = new Binding("Kinect") { Source = SensorChooser };
     this.regionSensorBinding = new Binding("Kinect") { Source = SensorChooser };
     BindingOperations.SetBinding(this.kRegion, KinectRegion.KinectSensorProperty, this.regionSensorBinding);
 }
开发者ID:Tribeman,项目名称:CS422,代码行数:34,代码来源:StatesScreen.cs


示例8: Kinecterface

 public Kinecterface(KinectSensorChooser chooser)
 {
     this.chooser = chooser;
     this.chooser.KinectChanged += KinectChanged;
     this.DataRecieved = (skels, depth, colors) => { };
     this.ErrorWhileRecivingData = (s, d, c) => { };
 }
开发者ID:TheSpikesKinectors,项目名称:SecondGame2016,代码行数:7,代码来源:Kinecterface.cs


示例9: OnLoaded

 private void OnLoaded(object sender, RoutedEventArgs routedEventArgs)
 {
     this.sensorChooser = new KinectSensorChooser();
     this.sensorChooser.KinectChanged += SensorChooserOnKinectChanged;
     this.sensorChooserUi.KinectSensorChooser = this.sensorChooser;
     this.sensorChooser.Start();
 }
开发者ID:IzzyAhmad,项目名称:esilk_kinect,代码行数:7,代码来源:Learn.xaml.cs


示例10: Window_Loaded_1

 private void Window_Loaded_1(object sender, RoutedEventArgs e)
 {
     miKinect = new KinectSensorChooser();
     miKinect.KinectChanged += miKinect_KinectChanged;
     sensorChooserUI.KinectSensorChooser = miKinect;
     miKinect.Start();
 }
开发者ID:egaleano,项目名称:Kinect,代码行数:7,代码来源:MainWindow.xaml.cs


示例11: MainWindow

 public MainWindow()
 {
     #if (DEBUG)
     Console.WriteLine("Starting Crash Fatality Inspector");
     #endif
     InitializeComponent();
     //
     //this.WindowState = System.Windows.WindowState.Maximized;
     this.Closing += MainWindow_Closing;
     //
     string exePath = System.Reflection.Assembly.GetExecutingAssembly().Location;
     string appPath = System.IO.Path.GetDirectoryName(exePath);
     #if (DEBUG)
     Console.WriteLine("Executable Path: " + exePath);
     Console.WriteLine("Application Path: " + appPath);
     #endif
     //
     Utilities.Data.LoadData(appPath);
     //
     #if (DEBUG)
     Console.WriteLine("Starting the Kinect sensor...");
     #endif
     this.sensorChooser = new KinectSensorChooser();
     this.sensorChooser.KinectChanged += SensorChooserOnKinectChanged;
     this.sensorChooser.Start();
     #if (DEBUG)
     Console.WriteLine("...Kinect started!");
     #endif
     //
     Views.TitleScreen titleScreen = new Views.TitleScreen(this, this.sensorChooser);
     titleScreen.Show();
 }
开发者ID:Tribeman,项目名称:CS422,代码行数:32,代码来源:MainWindow.xaml.cs


示例12: MainWindow

        public MainWindow()
        {
            InitializeComponent();

            KinectInit init = new KinectInit();

            init.initialize();

            serial.Init();

            this.sensorChooser = new KinectSensorChooser();

            this.sensorChooser.KinectChanged += SensorChooserOnKinectChanged;

            this.sensorChooserUi.KinectSensorChooser = this.sensorChooser;

            this.sensorChooser.Start();

            var regionSensorBinding = new Binding("Kinect") { Source = this.sensorChooser };

            BindingOperations.SetBinding(this.kinectRegion, KinectRegion.KinectSensorProperty, regionSensorBinding);

            SkeletonTracking trackAngle = new SkeletonTracking();

            trackAngle.InitializeSkeleton();

            trackAngle.SkeletonLoading();
        }
开发者ID:kinect-robotics,项目名称:mainhub,代码行数:28,代码来源:MainWindow.xaml.cs


示例13: OnLoaded

 private void OnLoaded(object sender, RoutedEventArgs routedEventArgs)
 {
     _sensorChooser = new KinectSensorChooser();
     _sensorChooser.KinectChanged += SensorChooserOnKinectChanged;
     KinectSensorChooserUi.KinectSensorChooser = _sensorChooser;
     _sensorChooser.Start();
     SetGameField();
 }
开发者ID:guozanhua,项目名称:KinectMiniGames,代码行数:8,代码来源:FirstLevelView.xaml.cs


示例14: DrawingGameConfigPage

 public DrawingGameConfigPage(string itemId, KinectSensorChooser kinectSensor)
 {
    
     this.InitializeComponent();
     this.kinectSensor = kinectSensor;
     config = new DrawingGameConfig();                                 
     this.DataContext = Config;
 }
开发者ID:guozanhua,项目名称:KinectMiniGames,代码行数:8,代码来源:DrawingGameConfigPage.xaml.cs


示例15: SongPlayer

 public SongPlayer(string s,KinectSensorChooser w)
     : this()
 {
     this.songName = s;
     this._sensor = w.Kinect;
     MoviePlayer.Source = new Uri(@"F:\KinectTest\KinectTest\KinectTest\Musics\" + songName + ".MP3", UriKind.Absolute);
     MoviePlayer.Play();
 }
开发者ID:jiaoyang813,项目名称:MediaHomeCenter,代码行数:8,代码来源:SongPlayer.xaml.cs


示例16: Asimov

 public Asimov(ICreateController create)
     : this(create, null)
 {
     // Find the Kinect and subscribe to changes in the sensor
     KinectSensorChooser sensorChooser = new KinectSensorChooser();
     sensorChooser.KinectChanged += this.KinectSensorChanged;
     sensorChooser.Start();
 }
开发者ID:shanet,项目名称:Asimov,代码行数:8,代码来源:Asimov.cs


示例17: Player

 public Player(string s, KinectSensorChooser w)
     : this()
 {
     this.movieName = s;
     this._sensor = w.Kinect;
     MoviePlayer.Source = new Uri(@"F:\KinectTest\KinectTest\KinectTest\Movies\" + movieName + ".MP4", UriKind.RelativeOrAbsolute);
     MoviePlayer.Play();
 }
开发者ID:jiaoyang813,项目名称:MediaHomeCenter,代码行数:8,代码来源:Player.xaml.cs


示例18: MainWindow

 public MainWindow()
 {
     InitializeComponent();
     myChooser = new KinectSensorChooser();
     myChooser.KinectChanged += new EventHandler<KinectChangedEventArgs>(myChooser_KinectChanged);
     this.SensorChooserUI.KinectSensorChooser = myChooser;
     myChooser.Start();
 }
开发者ID:kinectNao,项目名称:bluenao,代码行数:8,代码来源:MainWindow.xaml.cs


示例19: Window_Loaded_1

 private void Window_Loaded_1(object sender, RoutedEventArgs e)
 {
     Console.WriteLine("Main Windows Loading...");
     //Kinect Event Handler Register
     KinectSensor = new KinectSensorChooser();
     KinectSensor.KinectChanged += KinectSensor_KinectChanged;
     sensorChooserUI.KinectSensorChooser = KinectSensor;
     KinectSensor.Start();
 }
开发者ID:donnaknew,项目名称:programmingProject,代码行数:9,代码来源:MainWindow.xaml.cs


示例20: KinectManager

 public KinectManager(MainManager manager, KinectSensorChooserUI sensorUi)
 {
     this.mainManager = manager;
     //initialize the sensor chooser UI
     this.sensorChooser = new KinectSensorChooser();
     this.sensorChooser.KinectChanged += SensorChooserOnKinectChanged;
     sensorUi.KinectSensorChooser = this.sensorChooser;
     this.sensorChooser.Start();
 }
开发者ID:vincent61,项目名称:WordsInteractions,代码行数:9,代码来源:KinectManager.cs



注:本文中的Microsoft.Kinect.Toolkit.KinectSensorChooser类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# Live.LiveAuthClient类代码示例发布时间:2022-05-26
下一篇:
C# Toolkit.KinectChangedEventArgs类代码示例发布时间:2022-05-26
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap