C#

TCD.Kinect

EDIT: If you’re interested in Skeleton tracking and calculating 3D stuff, take a look at TCD.Mathematics too^^ EDIT: There’s a WPF application that I once wrote, featuring SkeletonPainter3D: Kinect Sword. There’s a Youtube video of it (http://youtu.be/2j6GCd4M1bA) and that’s the source code: http://dl.dropbox.com/u/7813771/Blog/CodeSamples/KinectSword.zip   Hello there, I’ve created another UserControl, this time for Kinect and .NET 4.5, which hopefully has the potential to save you a lot of time. It can be used to draw three-dimensional Skeletons and explore the virtual space around them in real-time. A picture may be more appropriate: The control can be constructed in XAML: xmlns:kinect=”clr-namespace:TCD.Kinect.Controls;assembly=TCD.Kinect.Controls” <kinect:SkeletonPainter3D x:Name=”painter” Background=”Black” IsAnaglyphEnabled=”False” CameraFieldOfView=”70″ CameraPosition=”0,0.5,-1″ CameraLookAt=”0,0,2″ /> And populated with Skeletons using painter.Draw(skeletons), where skeletons is an Skeleton[] from inside the SkeletonFrameReady event. You can either get the TCD.Kinect package from NuGet, or refer to the sample implementation: http://code.msdn.microsoft.com/Implementation-of-f175b025 Let me know if you have any questions or suggestions, and by the way: SkeletonPainter3D has an experimental…

Software

TouchInjector

Hello world, Today I proudly present: TouchInjector TouchInjector is a Windows 8 Desktop application that translates TUIO into Windows Touch messages. It’s lightweight, easy to use and does not get in the way. No installation is required and with one click you can customize it to autorun with the system (on logon). As I frequently change my display settings, TouchInjector observes them and reacts accordingly. You can download it here. There are no further software requirements than a Windows 8 system. Just unzip, unblock and run it. (Allow access through the firewall and make sure that no other TUIO clients block the port.) Have fun! ~theCake

C#

Windows 8 TouchInjection with C#

The Windows 8 platform provides an API to inject touch events (WM_TOUCH..) via a C++ API. The API is relatively easy to use, but not available in C#, unless you do DllImport/PInvoke. I found this to be kind of tricky, but finally I succeeded to make a C# library that can be used to use the TouchInjection API from C#. You can find TCD.System.TouchInjection on NuGet, or have a look at the TouchInjection.cs file itself. You may notice that I renamed all the strucs, enums and classes to look nicer than their C++ counterparts. The IntelliSense descriptions are available for almost everything! (I got them from the documentation on msdn..) I’ve made a sample application for the MSDN Code Gallery as well. Here’s a small collection of useful resources regarding the TouchInjection API: C++ sample application C++ TouchInjection API walkthrough

Kinect

KinDrive enhanced – working w/ every game using DirectX input

Last week – on thursday to be precise – I stumbled over a library to send input to the system on DirectX-level, called InputManager (a big different to all the tons of SendKeys()-wrappers out there!!). So great thanks to Shay from Israel for making this awesome library!! As all the rest of the architechture was up and running already, I just made a simple WPF application to show the Skeleton and listen for a gesture as well. The gesture (streching your arms in the air) causes the WASD-input to halt, a press of the F-Key (which I usually use to enter vehicles/use weapons in games..) and finally after 3.5 seconds everything continues as before. Here’s a video of the KinDrive for GTA WPF application: Then of course: GTA IV: And just for fun – Need For Speed Carbon: For those interested in DirectX-level Keyboard/Mouse input: I’ll blog about the InputManager anytime soon. My plan is to open source…

Kinect

KinDrive

Hey everyone, I’m happy to announce that I finally did the re-coding of KinDriver, now called KinDrive. The new version is made with the Beta 2 SDK, is a lot more stable, simpler and faster than the old one. It lacks of speech recognition and remote-controlability, but I splitted the two main features (tracking and keypressing) into separate assemblies, so it’s very easy to build a whole new application out of it! Here comes the code part: (if you aren’t interested in using coding, skip to the last paragraph)   TCD.KinDrive.Tracking.dll In this assembly there are three classes: KinDriveTracker, Point3D and DriveInformation TCD.Mathematics.Point3D is just a helper class for 3D vectors/points with some useful calculation-methods (like calculating the distance etc.) DriveInformation exposes two properties, Throttle and Steer, as well as a constructor that takes a SkeletonFrame as a parameter. Tracking and steer/throttle calculations are done by this very same constructor….

Kinect

Kinect tracking

UPDATE: The’re newer versions and posts about this software – if you want to test it please have a look at: http://blog.mosthege.net/tag/kindriver/   It’s been only 5 days since MS launched the Kinect for Windows SDK and in three of these days I coded KinDriver (and another small tool I’ll write about too). KinDriver is a dynamic Kinect tracker designed to be used with racing/driving games. We’ve seen Kinect trackers designed for the use w/ games already (talking of FAAST at this point), which may work nicely with ego-shooters or adventure games, but have a huge disadvantage when it comes to driving: They only know 1 or 0, just like the real keyboard. But while you can (an do) tip keys many times in a short period of time on your keyboard, doing so with you whole body is even more exhausting than you think! So I made a tracker that…

Software

Simple Launcher 2

As some of you may know, I have done an application called ‘Simple Launcher’. It’s purpose is to provide an easy way to have a multitouch user interface to start other applications. By pressing a small button on one of the controls it switches between container and bar-mode. In container-mode the user can drag’n’drop an application to a different container (or bar) and in bar-mode he can scroll through or launch applications. Empty containers will be remove automatically and new ones can be created via a button on the top. The user may also change the background by selecting a .jpg file. (Backgrounds are stored in ./Backgrounds and the selection is saved.) Here is a video of the application running on a HP Touchsmart notebook: [youtube=http://www.youtube.com/watch?v=BsZMSKe9h2k&w=448&h=252&hd=1] Simple Launcher 2 Demo   As all of the controls used in Simple Launcher are derived from MS Surface you need to install the…

Hardware

Mounting the Kinect

Yes! I’m well-prepared for an the upcoming milestone in human-computer interaction. The expert already knows what I’m talking about. It’s the Kinect SDK. Coming as OpenSource software it will enable some of us (including me ) to make gesture-driven applications. So as a matter of prudence I assembled a mount for my Kinect this morging. Rather than standing below, the camera now sits on its throne on top of the TV screen, so it has the best point of view for one or two persons standing in front of the TV screen and interacting with the computer. Though it was a bit tricky, the ‘throne’ now perfectly fits between the wall and the back of the TV: