Nuitrack  1.11.2
3D Skeleton Tracking Middleware
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Properties Events Groups Pages
nuitrack.SkeletonTracker Class Referenceabstract

Represents the interface to the capabilities of the Nuitrack Skeleton Tracker module. More...

Inherits nuitrack.Module.

Public Member Functions

delegate void OnNewUser (SkeletonTracker skeletonTracker, int userID)
 
delegate void OnLostUser (SkeletonTracker skeletonTracker, int userID)
 
delegate void OnSkeletonUpdate (SkeletonData skeletonData)
 
abstract void SetNumActiveUsers (int numUsers)
 Set the maximum number of active users for tracking. More...
 
abstract bool IsAutoTracking ()
 Determines whether autotracking is enabled. More...
 
abstract void SetAutoTracking (bool tracking)
 Set the autotracking. More...
 
abstract bool IsTracking (int userID)
 Determines whether the specified userID is being tracked. More...
 
abstract void StartTracking (int userID)
 Start tracking of a user. More...
 
abstract void StopTracking (int userID)
 Stop tracking of a user. More...
 
virtual SkeletonData GetSkeletonData ()
 Get the skeleton data. More...
 
abstract float GetProcessingTime ()
 Get the processing time of the last skeleton. More...
 
- Public Member Functions inherited from nuitrack.Module
String GetPerformanceInfo ()
 
virtual void Release ()
 
void subscribe ()
 

Static Public Member Functions

static SkeletonTracker Create ()
 Initializes a new instance of the nuitrack.SkeletonTracker class.
 

Protected Member Functions

void SignalOnNewUser (int userID)
 
void SignalOnLostUser (int userID)
 
void SignalOnUpdate (SkeletonData skeletonData)
 
- Protected Member Functions inherited from nuitrack.Module
void unsubscribe ()
 
abstract void subscribeImpl ()
 
abstract void unsubscribeImpl ()
 

Protected Attributes

SkeletonData skeletonData
 
- Protected Attributes inherited from nuitrack.Module
System.IntPtr ptr
 
int usageCount
 
int isSubscribed
 
long lastCall
 

Properties

OnSkeletonUpdate OnSkeletonUpdateEvent
 Raised when the module data is updated.
 
OnNewUser OnNewUserEvent
 Raised when a new user is detected.
 
OnLostUser OnLostUserEvent
 Raised when the user is lost.
 
- Properties inherited from nuitrack.Module
System.IntPtr Ptr [get]
 Gets the native ptr. More...
 

Detailed Description

Represents the interface to the capabilities of the Nuitrack Skeleton Tracker module.

To enable the module, you must create an instance of this class. To create the instance, use the SkeletonTracker Create () method. This instance is called SkeletonTracker module object. To handle events of appearance and disappearance of an active user, use SkeletonTracker::OnNewUserEvent and SkeletonTracker::OnLostUserEvent events.

Member Function Documentation

abstract float nuitrack.SkeletonTracker.GetProcessingTime ( )
pure virtual

Get the processing time of the last skeleton.

Returns
The data processing time of the last skeleton in ms.
virtual SkeletonData nuitrack.SkeletonTracker.GetSkeletonData ( )
inlinevirtual

Get the skeleton data.

Returns
The skeleton data.
abstract bool nuitrack.SkeletonTracker.IsAutoTracking ( )
pure virtual

Determines whether autotracking is enabled.

Returns
True if autotracking is enabled, otherwise, false.
Note
The default value is determined by the Nuitrack config file.
See Also
SetAutoTracking
abstract bool nuitrack.SkeletonTracker.IsTracking ( int  userID)
pure virtual

Determines whether the specified userID is being tracked.

Returns
True if the specified userID is being tracked, otherwise, false.
See Also
StartTracking
StopTracking
abstract void nuitrack.SkeletonTracker.SetAutoTracking ( bool  tracking)
pure virtual

Set the autotracking.

Call SetAutoTracking(true) to enable autotracking. Call SetAutoTracking(false) to disable autotracking.

When autotracking is enabled, tracking of the user's skeleton begins immediately when the user appears in the frame. Otherwise, you must manually start tracking of the user's skeleton.

Parameters
[in]trackingAutotracking to be set.
See Also
StartTracking
IsAutoTracking
abstract void nuitrack.SkeletonTracker.SetNumActiveUsers ( int  numUsers)
pure virtual

Set the maximum number of active users for tracking.

Note
The function supports tracking from 0 to 6 users. By default, the skeleton of 2 users is tracked. Tracking of more than 2 users may lead to performance loss.
Parameters
[in]numUsersMaximum number of active users to be set.
void nuitrack.SkeletonTracker.SignalOnLostUser ( int  userID)
inlineprotected
Warning
For internal use only.
void nuitrack.SkeletonTracker.SignalOnNewUser ( int  userID)
inlineprotected
Warning
For internal use only.
void nuitrack.SkeletonTracker.SignalOnUpdate ( SkeletonData  skeletonData)
inlineprotected
Warning
For internal use only.
abstract void nuitrack.SkeletonTracker.StartTracking ( int  userID)
pure virtual

Start tracking of a user.

Parameters
[in]userIDID of a user, tracking of whom should be started.
See Also
StopTracking
IsTracking
abstract void nuitrack.SkeletonTracker.StopTracking ( int  userID)
pure virtual

Stop tracking of a user.

Parameters
[in]userIDID of user, tracking of whom should be stopped.
See Also
StartTracking
IsTracking

Member Data Documentation

SkeletonData nuitrack.SkeletonTracker.skeletonData
protected
Warning
For internal use only.