C# Класс DeviceListener

Listen to the Leap Motion device and manage the functions linked to the controller.
Наследование: Listener
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
GetNodeName ( string boneType ) : string
OnConnect ( Controller controller ) : void

Check if the device is well connected

OnDisconnect ( Controller controller ) : void
OnFrame ( Controller controller ) : void

Function called each frame. Overriding it allows to write at the frame rate of the device.

RecordStream ( Frame, frame ) : void
StartRecord ( ) : void
StopRecord ( ) : Scene

Приватные методы

Метод Описание
AddChildBone ( string boneType, Node parentNode ) : Node
AddNewFrame ( Hand hand, Animation anim ) : void

Add a new frame Animation channel

BoneToNode ( Bone bone ) : QuaternionKey>.Tuple
CreateNodeHierarchy ( Hand hand ) : void

Build a Node hierachy into the scene property 'mainScene' from a Hand object

InitNodeAnimChannel ( Hand hand ) : void
RecordHand ( Hand hand ) : void

Take a Hand argument which will be converted and added into one of the animation present in the animList property

SafeWriteLine ( String line ) : void

Lock the current thread to write a message. Temporary function for Debug.

Описание методов

GetNodeName() публичный статический Метод

public static GetNodeName ( string boneType ) : string
boneType string
Результат string

OnConnect() публичный Метод

Check if the device is well connected
public OnConnect ( Controller controller ) : void
controller Controller Controller that represent the device.
Результат void

OnDisconnect() публичный Метод

public OnDisconnect ( Controller controller ) : void
controller Controller
Результат void

OnFrame() публичный Метод

Function called each frame. Overriding it allows to write at the frame rate of the device.
public OnFrame ( Controller controller ) : void
controller Controller Controller that represent the device.
Результат void

RecordStream() публичный Метод

public RecordStream ( Frame, frame ) : void
frame Frame,
Результат void

StartRecord() публичный Метод

public StartRecord ( ) : void
Результат void

StopRecord() публичный Метод

public StopRecord ( ) : Scene
Результат Scene