Tanoda
Leap.Controller Class Reference

The Controller class is your main interface to the Leap Motion Controller. More...

Inheritance diagram for Leap.Controller:
Leap.IController

Public Types

enum  PolicyFlag {
  POLICY_DEFAULT = 0 , POLICY_BACKGROUND_FRAMES = (1 << 0) , POLICY_IMAGES = (1 << 1) , POLICY_OPTIMIZE_HMD = (1 << 2) ,
  POLICY_ALLOW_PAUSE_RESUME = (1 << 3) , POLICY_MAP_POINTS = (1 << 7) , POLICY_OPTIMIZE_SCREENTOP = (1 << 8)
}
 The supported controller policies. More...
 

Public Member Functions

void Dispose ()
 
 Controller ()
 Constructs a Controller object. More...
 
 Controller (int connectionKey, string serverNamespace=null)
 Constructs a Controller object using the specified connection key. More...
 
void StartConnection ()
 Starts the connection. More...
 
void StopConnection ()
 Stops the connection. More...
 
void SetPolicy (PolicyFlag policy)
 Requests setting a policy. More...
 
void ClearPolicy (PolicyFlag policy)
 Requests clearing a policy. More...
 
bool IsPolicySet (PolicyFlag policy)
 Gets the active setting for a specific policy. More...
 
Frame Frame (int history=0)
 In most cases you should get Frame objects using the LeapProvider.CurrentFrame property. The data in Frame objects taken directly from a Leap.Controller instance is still in the Leap Motion frame of reference and will not match the hands displayed in a Unity scene. More...
 
void Frame (Frame toFill, int history=0)
 Identical to Frame(history) but instead of constructing a new frame and returning it, the user provides a frame object to be filled with data instead. More...
 
long FrameTimestamp (int history=0)
 Returns the timestamp of a recent tracking frame. Use the optional history parameter to specify how many frames in the past to retrieve the timestamp. Leave the history parameter as it's default value to return the timestamp of the most recent tracked frame. More...
 
Frame GetTransformedFrame (LeapTransform trs, int history=0)
 Returns the frame object with all hands transformed by the specified transform matrix. More...
 
Frame GetInterpolatedFrame (Int64 time)
 Returns the Frame at the specified time, interpolating the data between existing frames, if necessary. More...
 
void GetInterpolatedFrame (Frame toFill, Int64 time)
 Fills the Frame with data taken at the specified time, interpolating the data between existing frames, if necessary. More...
 
LEAP_HEAD_POSE_EVENT GetInterpolatedHeadPose (Int64 time)
 Returns the Head pose at the specified time, interpolating the data between existing frames, if necessary. More...
 
void GetInterpolatedHeadPose (ref LEAP_HEAD_POSE_EVENT toFill, Int64 time)
 
void TelemetryProfiling (ref LEAP_TELEMETRY_DATA telemetryData)
 
UInt64 TelemetryGetNow ()
 
void GetPointMapping (ref PointMapping pointMapping)
 
void GetInterpolatedLeftRightTransform (Int64 time, Int64 sourceTime, int leftId, int rightId, out LeapTransform leftTransform, out LeapTransform rightTransform)
 This is a special variant of GetInterpolatedFrameFromTime, for use with special features that only require the position and orientation of the palm positions, and do not care about pose data or any other data. More...
 
void GetInterpolatedFrameFromTime (Frame toFill, Int64 time, Int64 sourceTime)
 
long Now ()
 Returns a timestamp value as close as possible to the current time. Values are in microseconds, as with all the other timestamp values. More...
 
FailedDeviceList FailedDevices ()
 A list of any Leap Motion hardware devices that are physically connected to the client computer, but are not functioning correctly. The list contains FailedDevice objects containing the pnpID and the reason for failure. No other device information is available. More...
 
Frame Frame (int history=0)
 
Frame GetTransformedFrame (LeapTransform trs, int history=0)
 
Frame GetInterpolatedFrame (Int64 time)
 
void SetPolicy (Controller.PolicyFlag policy)
 
void ClearPolicy (Controller.PolicyFlag policy)
 
bool IsPolicySet (Controller.PolicyFlag policy)
 
long Now ()
 

Protected Member Functions

virtual void Dispose (bool disposing)
 
virtual void OnInit (object sender, LeapEventArgs eventArgs)
 
virtual void OnConnect (object sender, ConnectionEventArgs eventArgs)
 
virtual void OnDisconnect (object sender, ConnectionLostEventArgs eventArgs)
 

Properties

SynchronizationContext EventContext [get, set]
 The SynchronizationContext used for dispatching events. More...
 
EventHandler< LeapEventArgsInit
 Dispatched when the connection is initialized (but not necessarily connected). More...
 
EventHandler< ConnectionEventArgsConnect
 Dispatched when the connection to the service is established. More...
 
EventHandler< ConnectionLostEventArgsDisconnect
 Dispatched if the connection to the service is lost. More...
 
EventHandler< FrameEventArgsFrameReady
 Dispatched when a tracking frame is ready. More...
 
EventHandler< InternalFrameEventArgsInternalFrameReady
 Dispatched when an internal tracking frame is ready. More...
 
EventHandler< DeviceEventArgsDevice
 Dispatched when a Leap Motion device is connected. More...
 
EventHandler< DeviceEventArgsDeviceLost
 Dispatched when a Leap Motion device is disconnected. More...
 
EventHandler< DeviceFailureEventArgsDeviceFailure
 Dispatched when a Leap device fails to initialize. More...
 
EventHandler< LogEventArgsLogMessage
 Dispatched when the system generates a loggable event. More...
 
EventHandler< PolicyEventArgsPolicyChange
 Dispatched when a policy changes. More...
 
EventHandler< ConfigChangeEventArgsConfigChange
 Dispatched when a configuration setting changes. More...
 
EventHandler< DistortionEventArgsDistortionChange
 Dispatched when the image distortion map changes. The distortion map can change when the Leap device switches orientation, or a new device becomes active. More...
 
EventHandler< DroppedFrameEventArgsDroppedFrame
 Dispatched when the service drops a tracking frame. More...
 
EventHandler< ImageEventArgsImageReady
 Dispatched when an unrequested image is ready. More...
 
Action< BeginProfilingForThreadArgsBeginProfilingForThread
 Dispatched whenever a thread wants to start profiling for a custom thread. The event is always dispatched from the thread itself. More...
 
Action< EndProfilingForThreadArgsEndProfilingForThread
 Dispatched whenever a thread is finished profiling. The event is always dispatched from the thread itself. More...
 
Action< BeginProfilingBlockArgsBeginProfilingBlock
 Dispatched whenever a thread enters a profiling block. The event is always dispatched from the thread itself. More...
 
Action< EndProfilingBlockArgsEndProfilingBlock
 Dispatched whenever a thread ends a profiling block. The event is always dispatched from the thread itself. More...
 
EventHandler< PointMappingChangeEventArgsPointMappingChange
 Dispatched when point mapping change events are generated by the service. More...
 
EventHandler< HeadPoseEventArgsHeadPoseChange
 Dispatched when a new HeadPose is available. More...
 
bool IsServiceConnected [get]
 Reports whether your application has a connection to the Leap Motion daemon/service. Can be true even if the Leap Motion hardware is not available. More...
 
bool IsConnected [get]
 Reports whether this Controller is connected to the Leap Motion service and the Leap Motion hardware is plugged in. More...
 
Config Config [get]
 Returns a Config object, which you can use to query the Leap Motion system for configuration information. More...
 
DeviceList Devices [get]
 The list of currently attached and recognized Leap Motion controller devices. More...
 
- Properties inherited from Leap.IController
bool IsConnected [get]
 
Config Config [get]
 
DeviceList Devices [get]
 

Additional Inherited Members

- Events inherited from Leap.IController
EventHandler< ConnectionEventArgsConnect
 
EventHandler< ConnectionLostEventArgsDisconnect
 
EventHandler< FrameEventArgsFrameReady
 
EventHandler< DeviceEventArgsDevice
 
EventHandler< DeviceEventArgsDeviceLost
 
EventHandler< DeviceFailureEventArgsDeviceFailure
 
EventHandler< LogEventArgsLogMessage
 
EventHandler< PolicyEventArgsPolicyChange
 
EventHandler< ConfigChangeEventArgsConfigChange
 
EventHandler< DistortionEventArgsDistortionChange
 
EventHandler< ImageEventArgsImageReady
 
EventHandler< PointMappingChangeEventArgsPointMappingChange
 
EventHandler< HeadPoseEventArgsHeadPoseChange
 

Detailed Description

The Controller class is your main interface to the Leap Motion Controller.

Create an instance of this Controller class to access frames of tracking data and configuration information.Frame data can be polled at any time using the Controller.Frame() function.Call frame() or frame(0) to get the most recent frame.Set the history parameter to a positive integer to access previous frames.A controller stores up to 60 frames in its frame history.

Polling is an appropriate strategy for applications which already have an intrinsic update loop, such as a game. You can also subscribe to the FrameReady event to get tracking frames through an event delegate.

If the current thread implements a SynchronizationContext that contains a message loop, events are posted to that threads message loop. Otherwise, events are called on an independent thread and applications must perform any needed synchronization or marshalling of data between threads. Note that Unity3D does not create an appropriate SynchronizationContext object. Typically, event handlers cannot access any Unity objects.

Since
1.0

Definition at line 38 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

Member Enumeration Documentation

◆ PolicyFlag

The supported controller policies.

The supported policy flags are:

POLICY_BACKGROUND_FRAMES – requests that your application receives frames when it is not the foreground application for user input.

The background frames policy determines whether an application receives frames of tracking data while in the background. By default, the Leap Motion software only sends tracking data to the foreground application. Only applications that need this ability should request the background frames policy. The "Allow Background Apps" checkbox must be enabled in the Leap Motion Control Panel or this policy will be denied.

POLICY_OPTIMIZE_HMD – request that the tracking be optimized for head-mounted tracking.

The optimize HMD policy improves tracking in situations where the Leap Motion hardware is attached to a head-mounted display. This policy is not granted for devices that cannot be mounted to an HMD, such as Leap Motion controllers embedded in a laptop or keyboard.

Some policies can be denied if the user has disabled the feature on their Leap Motion control panel.

Since
1.0
Enumerator
POLICY_DEFAULT 

The default policy.

POLICY_BACKGROUND_FRAMES 

Receive background frames.

POLICY_IMAGES 

Allow streaming images.

POLICY_OPTIMIZE_HMD 

Optimize the tracking for head-mounted device.

POLICY_ALLOW_PAUSE_RESUME 

Allow pausing and unpausing of the Leap Motion service.

POLICY_MAP_POINTS 

Allow streaming map point

POLICY_OPTIMIZE_SCREENTOP 

Optimize the tracking for screen-top device.

Since
5.0.0

Definition at line 689 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

Constructor & Destructor Documentation

◆ Controller() [1/2]

Leap.Controller.Controller ( )

Constructs a Controller object.

The default constructor uses a connection key of 0.

Since
1.0

Definition at line 363 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ Controller() [2/2]

Leap.Controller.Controller ( int  connectionKey,
string  serverNamespace = null 
)

Constructs a Controller object using the specified connection key.

All controller instances using the same key will use the same connection to the service. In general, an application should not use more than one connection for all its controllers. Each connection keeps its own cache of frames and images.

Parameters
connectionKeyAn identifier specifying the connection to use. If a connection with the specified key already exists, that connection is used. Otherwise, a new connection is created.
Since
3.0

Definition at line 377 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

Member Function Documentation

◆ ClearPolicy()

void Leap.Controller.ClearPolicy ( PolicyFlag  policy)

Requests clearing a policy.

Policy changes are completed asynchronously and, because they are subject to user approval or system compatibility checks, may not complete successfully. Call Controller.IsPolicySet() after a suitable interval to test whether the change was accepted.

Since
2.1.6

Implements Leap.IController.

Definition at line 449 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ Dispose() [1/2]

void Leap.Controller.Dispose ( )

◆ Dispose() [2/2]

virtual void Leap.Controller.Dispose ( bool  disposing)
protectedvirtual

◆ FailedDevices()

FailedDeviceList Leap.Controller.FailedDevices ( )

A list of any Leap Motion hardware devices that are physically connected to the client computer, but are not functioning correctly. The list contains FailedDevice objects containing the pnpID and the reason for failure. No other device information is available.

Since
3.0

Definition at line 657 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ Frame() [1/2]

void Leap.Controller.Frame ( Frame  toFill,
int  history = 0 
)

Identical to Frame(history) but instead of constructing a new frame and returning it, the user provides a frame object to be filled with data instead.

Definition at line 500 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ Frame() [2/2]

Frame Leap.Controller.Frame ( int  history = 0)

In most cases you should get Frame objects using the LeapProvider.CurrentFrame property. The data in Frame objects taken directly from a Leap.Controller instance is still in the Leap Motion frame of reference and will not match the hands displayed in a Unity scene.

Returns a frame of tracking data from the Leap Motion software. Use the optional history parameter to specify which frame to retrieve. Call frame() or frame(0) to access the most recent frame; call frame(1) to access the previous frame, and so on. If you use a history value greater than the number of stored frames, then the controller returns an empty frame.

Parameters
historyThe age of the frame to return, counting backwards from the most recent frame (0) into the past and up to the maximum age (59).
Returns
The specified frame; or, if no history parameter is specified, the newest frame. If a frame is not available at the specified history position, an invalid Frame is returned.
Since
1.0

Implements Leap.IController.

Definition at line 490 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ FrameTimestamp()

long Leap.Controller.FrameTimestamp ( int  history = 0)

Returns the timestamp of a recent tracking frame. Use the optional history parameter to specify how many frames in the past to retrieve the timestamp. Leave the history parameter as it's default value to return the timestamp of the most recent tracked frame.

Definition at line 513 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ GetInterpolatedFrame() [1/2]

void Leap.Controller.GetInterpolatedFrame ( Frame  toFill,
Int64  time 
)

Fills the Frame with data taken at the specified time, interpolating the data between existing frames, if necessary.

Definition at line 537 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ GetInterpolatedFrame() [2/2]

Frame Leap.Controller.GetInterpolatedFrame ( Int64  time)

Returns the Frame at the specified time, interpolating the data between existing frames, if necessary.

Implements Leap.IController.

Definition at line 530 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ GetInterpolatedFrameFromTime()

void Leap.Controller.GetInterpolatedFrameFromTime ( Frame  toFill,
Int64  time,
Int64  sourceTime 
)

◆ GetInterpolatedHeadPose() [1/2]

LEAP_HEAD_POSE_EVENT Leap.Controller.GetInterpolatedHeadPose ( Int64  time)

Returns the Head pose at the specified time, interpolating the data between existing frames, if necessary.

Definition at line 544 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ GetInterpolatedHeadPose() [2/2]

void Leap.Controller.GetInterpolatedHeadPose ( ref LEAP_HEAD_POSE_EVENT  toFill,
Int64  time 
)

◆ GetInterpolatedLeftRightTransform()

void Leap.Controller.GetInterpolatedLeftRightTransform ( Int64  time,
Int64  sourceTime,
int  leftId,
int  rightId,
out LeapTransform  leftTransform,
out LeapTransform  rightTransform 
)

This is a special variant of GetInterpolatedFrameFromTime, for use with special features that only require the position and orientation of the palm positions, and do not care about pose data or any other data.

You must specify the id of the hand that you wish to get a transform for. If you specify an id that is not present in the interpolated frame, the output transform will be the identity transform.

Definition at line 573 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ GetPointMapping()

void Leap.Controller.GetPointMapping ( ref PointMapping  pointMapping)

◆ GetTransformedFrame()

Frame Leap.Controller.GetTransformedFrame ( LeapTransform  trs,
int  history = 0 
)

Returns the frame object with all hands transformed by the specified transform matrix.

Implements Leap.IController.

Definition at line 523 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ IsPolicySet()

bool Leap.Controller.IsPolicySet ( PolicyFlag  policy)

Gets the active setting for a specific policy.

Keep in mind that setting a policy flag is asynchronous, so changes are not effective immediately after calling setPolicyFlag(). In addition, a policy request can be declined by the user. You should always set the policy flags required by your application at startup and check that the policy change request was successful after an appropriate interval.

If the controller object is not connected to the Leap Motion software, then the default state for the selected policy is returned.

Since
2.1.6

Implements Leap.IController.

Definition at line 467 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ Now()

long Leap.Controller.Now ( )

Returns a timestamp value as close as possible to the current time. Values are in microseconds, as with all the other timestamp values.

Since
2.2.7

Implements Leap.IController.

Definition at line 592 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ OnConnect()

virtual void Leap.Controller.OnConnect ( object  sender,
ConnectionEventArgs  eventArgs 
)
protectedvirtual

◆ OnDisconnect()

virtual void Leap.Controller.OnDisconnect ( object  sender,
ConnectionLostEventArgs  eventArgs 
)
protectedvirtual

◆ OnInit()

virtual void Leap.Controller.OnInit ( object  sender,
LeapEventArgs  eventArgs 
)
protectedvirtual

◆ SetPolicy()

void Leap.Controller.SetPolicy ( PolicyFlag  policy)

Requests setting a policy.

A request to change a policy is subject to user approval and a policy can be changed by the user at any time (using the Leap Motion settings dialog). The desired policy flags must be set every time an application runs.

Policy changes are completed asynchronously and, because they are subject to user approval or system compatibility checks, may not complete successfully. Call Controller.IsPolicySet() after a suitable interval to test whether the change was accepted.

Since
2.1.6

Implements Leap.IController.

Definition at line 436 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ StartConnection()

void Leap.Controller.StartConnection ( )

Starts the connection.

A connection starts automatically when created, but you can use this function to restart the connection after stopping it.

Since
3.0

Definition at line 396 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ StopConnection()

void Leap.Controller.StopConnection ( )

Stops the connection.

No more frames or other events are received from a stopped connection. You can restart with StartConnection().

Since
3.0

Definition at line 408 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ TelemetryGetNow()

UInt64 Leap.Controller.TelemetryGetNow ( )

◆ TelemetryProfiling()

void Leap.Controller.TelemetryProfiling ( ref LEAP_TELEMETRY_DATA  telemetryData)

Property Documentation

◆ BeginProfilingBlock

Action<BeginProfilingBlockArgs> Leap.Controller.BeginProfilingBlock
addremove

Dispatched whenever a thread enters a profiling block. The event is always dispatched from the thread itself.

The event data will contain the name of the profiling block.

Since
4.0

Definition at line 291 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ BeginProfilingForThread

Action<BeginProfilingForThreadArgs> Leap.Controller.BeginProfilingForThread
addremove

Dispatched whenever a thread wants to start profiling for a custom thread. The event is always dispatched from the thread itself.

The event data will contain the name of the thread, as well as an array of all possible profiling blocks that could be entered on that thread.

Since
4.0

Definition at line 259 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ Config

Config Leap.Controller.Config
get

Returns a Config object, which you can use to query the Leap Motion system for configuration information.

Since
1.0

Implements Leap.IController.

Definition at line 623 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ ConfigChange

EventHandler<ConfigChangeEventArgs> Leap.Controller.ConfigChange
addremove

Dispatched when a configuration setting changes.

Since
3.0

Implements Leap.IController.

Definition at line 201 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ Connect

EventHandler<ConnectionEventArgs> Leap.Controller.Connect
addremove

Dispatched when the connection to the service is established.

Since
3.0

Implements Leap.IController.

Definition at line 81 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ Device

EventHandler<DeviceEventArgs> Leap.Controller.Device
addremove

Dispatched when a Leap Motion device is connected.

Since
3.0

Implements Leap.IController.

Definition at line 136 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ DeviceFailure

EventHandler<DeviceFailureEventArgs> Leap.Controller.DeviceFailure
addremove

Dispatched when a Leap device fails to initialize.

Since
3.0

Implements Leap.IController.

Definition at line 162 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ DeviceLost

EventHandler<DeviceEventArgs> Leap.Controller.DeviceLost
addremove

Dispatched when a Leap Motion device is disconnected.

Since
3.0

Implements Leap.IController.

Definition at line 149 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ Devices

DeviceList Leap.Controller.Devices
get

The list of currently attached and recognized Leap Motion controller devices.

The Device objects in the list describe information such as the range and tracking volume.

Currently, the Leap Motion Controller only allows a single active device at a time, however there may be multiple devices physically attached and listed here. Any active device(s) are guaranteed to be listed first, however order is not determined beyond that.

Since
1.0

Implements Leap.IController.

Definition at line 643 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ Disconnect

EventHandler<ConnectionLostEventArgs> Leap.Controller.Disconnect
addremove

Dispatched if the connection to the service is lost.

Since
3.0

Implements Leap.IController.

Definition at line 97 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ DistortionChange

EventHandler<DistortionEventArgs> Leap.Controller.DistortionChange
addremove

Dispatched when the image distortion map changes. The distortion map can change when the Leap device switches orientation, or a new device becomes active.

Since
3.0

Implements Leap.IController.

Definition at line 216 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ DroppedFrame

EventHandler<DroppedFrameEventArgs> Leap.Controller.DroppedFrame
addremove

Dispatched when the service drops a tracking frame.

Definition at line 228 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ EndProfilingBlock

Action<EndProfilingBlockArgs> Leap.Controller.EndProfilingBlock
addremove

Dispatched whenever a thread ends a profiling block. The event is always dispatched from the thread itself.

The event data will contain the name of the profiling block.

Since
4.0

Definition at line 308 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ EndProfilingForThread

Action<EndProfilingForThreadArgs> Leap.Controller.EndProfilingForThread
addremove

Dispatched whenever a thread is finished profiling. The event is always dispatched from the thread itself.

Since
4.0

Definition at line 274 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ EventContext

SynchronizationContext Leap.Controller.EventContext
getset

The SynchronizationContext used for dispatching events.

By default the synchronization context of the thread creating the controller instance is used. You can change the context if desired.

Definition at line 50 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ FrameReady

EventHandler<FrameEventArgs> Leap.Controller.FrameReady
addremove

Dispatched when a tracking frame is ready.

Since
3.0

Implements Leap.IController.

Definition at line 110 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ HeadPoseChange

EventHandler<HeadPoseEventArgs> Leap.Controller.HeadPoseChange
addremove

Dispatched when a new HeadPose is available.

Implements Leap.IController.

Definition at line 333 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ ImageReady

EventHandler<ImageEventArgs> Leap.Controller.ImageReady
addremove

Dispatched when an unrequested image is ready.

Since
4.0

Implements Leap.IController.

Definition at line 241 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ Init

EventHandler<LeapEventArgs> Leap.Controller.Init
addremove

Dispatched when the connection is initialized (but not necessarily connected).

Can be dispatched more than once, if connection is restarted.

Since
3.0

Definition at line 65 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ InternalFrameReady

EventHandler<InternalFrameEventArgs> Leap.Controller.InternalFrameReady
addremove

Dispatched when an internal tracking frame is ready.

Since
3.0

Definition at line 123 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ IsConnected

bool Leap.Controller.IsConnected
get

Reports whether this Controller is connected to the Leap Motion service and the Leap Motion hardware is plugged in.

When you first create a Controller object, isConnected() returns false. After the controller finishes initializing and connects to the Leap Motion software and if the Leap Motion hardware is plugged in, isConnected() returns true.

You can either handle the onConnect event using a Listener instance or poll the isConnected() function if you need to wait for your application to be connected to the Leap Motion software before performing some other operation.

Since
1.0

Implements Leap.IController.

Definition at line 611 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ IsServiceConnected

bool Leap.Controller.IsServiceConnected
get

Reports whether your application has a connection to the Leap Motion daemon/service. Can be true even if the Leap Motion hardware is not available.

Since
1.2

Definition at line 417 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ LogMessage

EventHandler<LogEventArgs> Leap.Controller.LogMessage
addremove

Dispatched when the system generates a loggable event.

Since
3.0

Implements Leap.IController.

Definition at line 175 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ PointMappingChange

EventHandler<PointMappingChangeEventArgs> Leap.Controller.PointMappingChange
addremove

Dispatched when point mapping change events are generated by the service.

Since
4.0

Implements Leap.IController.

Definition at line 321 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.

◆ PolicyChange

EventHandler<PolicyEventArgs> Leap.Controller.PolicyChange
addremove

Dispatched when a policy changes.

Since
3.0

Implements Leap.IController.

Definition at line 188 of file Plugins/LeapMotion/Core/Plugins/LeapCSharp/Controller.cs.


The documentation for this class was generated from the following file: