This project contains extension methods to ease the use of the Kinect V2 SDK with the help of Rx.
C# PowerShell
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.nuget
Documentation
Face.NET45
Input.NET45
Input.NET451
Input.WinStore81
NET45
NET451
Samples
WinStore81
Kinect.ReactiveV2.sln
README.md

README.md

Kinect.ReactiveV2

This project contains extension methods to ease the use of the Kinect for Windows V2 SDK with the help of Rx.

“This is preliminary software and/or hardware and APIs are preliminary and subject to change”

##NuGet Installation PM> Install-Package Kinect.ReactiveV2

PM> Install-Package Kinect.ReactiveV2.Input

##Samples

###Kinect.ReactiveV2 ####SceneChanges

using System;
using System.Linq;
using System.Reactive;
using Microsoft.Kinect;
using Kinect.ReactiveV2;

var sensor = KinectSensor.Default;
sensor.Open();

sensor.SceneChanges()
      .Subscribe(_ =>
      {
            if (_.SceneChangedType is PersonEnteredScene)
            {
                  Console.WriteLine("Person {0} entered scene", _.SceneChangedType.TrackingId);
            }
            else if (_.SceneChangedType is PersonLeftScene)
            {
                  Console.WriteLine("Person {0} left scene", _.SceneChangedType.TrackingId);
            }
      });

####BodyIndexFrameArrivedObservable

using System.Linq;
using System.Reactive;
using Microsoft.Kinect;
using Kinect.ReactiveV2;

var sensor = KinectSensor.Default;
sensor.Open();

var bodyIndexFrameDescription = sensor.BodyIndexFrameSource.FrameDescription;
var bodyIndexData = new byte[bodyIndexFrameDescription.LengthInPixels];

sensor.BodyIndexFrameArrivedObservable()
      .SelectBodyIndexData(bodyIndexData)
      .Subscribe(data => someBitmap.WritePixels(rect, data, stride, 0));

###Kinect.ReactiveV2.Input