Show / Hide Table of Contents

Class MagicLeapControllerFunctionLibrary

Magic Leap Controller Function Library

Inheritance
System.Object
UObject
BlueprintFunctionLibrary
MagicLeapControllerFunctionLibrary
Inherited Members
UObject.TransientPackage
UObject.CastTo<T>(UObject)
UObject.CastTo(UObject, Type)
UObject.RemoveObject(UObject)
UObject.MakeObjectArrayField<T>(NativeArray*)
UObject.NotImplemented<T>()
UObject.Construct()
UObject.GetHashCode()
UObject.GetName()
UObject.ToString()
UObject.Name
UObject._None
UObject.None
UObject.ObjPointer
UObject.LoadObjectFromClass(Class, UObject, String, String, LoadFlags, PackageMap, Boolean)
UObject.LoadClass(Class, UObject, String, String, LoadFlags, PackageMap)
UObject.GetPropertyFor<T>(Name)
UObject.ExecuteUbergraph
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
Namespace: UE4.MagicLeapController
Assembly: UE4DotNet.dll
Syntax
public class MagicLeapControllerFunctionLibrary : BlueprintFunctionLibrary

Properties

| Improve this Doc View Source

DefaultObject

Get UE4 Default Object for this Class

Declaration
public static MagicLeapControllerFunctionLibrary DefaultObject { get; }
Property Value
Type Description
MagicLeapControllerFunctionLibrary
| Improve this Doc View Source

StaticClass

Get UE4 Class

Declaration
public static Class StaticClass { get; }
Property Value
Type Description
Class

Methods

| Improve this Doc View Source

GetControllerMapping(Int32)

Returns the hand to which given controller index has been mapped to in the device backend.

Declaration
public static (EControllerHand, bool) GetControllerMapping(int ControllerIndex)
Parameters
Type Name Description
System.Int32 ControllerIndex
Returns
Type Description
System.ValueTuple<EControllerHand, System.Boolean>
Remarks

The native api does not have a concept of left vs right controller. They deal with indices. The first connected controller is index 0 and so on. By default, index 0 is mapped to the right hand in Unreal. You can invert these mappings by calling InvertControllerMapping() function. @param ControllerIndex Zero based controller index to get the hand mapping for. Should be less than MaxSupportedMagicLeapControllers(). @param Hand Output parameter which is the hand the given index maps to. Valid only if the function returns true. @return true of the controller index maps to a valid hand, false otherwise

| Improve this Doc View Source

GetControllerTrackingMode()

Get controller tracking mode.

Declaration
public static EMLControllerTrackingMode GetControllerTrackingMode()
Returns
Type Description
EMLControllerTrackingMode
Remarks

@return Controller tracking mode.

| Improve this Doc View Source

GetMLControllerType(EControllerHand)

Type of ML device being tracking the given hand.

Declaration
public static EMLControllerType GetMLControllerType(EControllerHand Hand)
Parameters
Type Name Description
EControllerHand Hand
Returns
Type Description
EMLControllerType
Remarks

@param Hand Controller hand to query. @return Type of ML device which maps to given Unreal controller hand.

| Improve this Doc View Source

InvertControllerMapping()

Inverts the controller mapping i.

Declaration
public static void InvertControllerMapping()
Remarks

e. keys mapped to left hand controller will now be treated as right hand and vice-versa. @see GetControllerMapping()

| Improve this Doc View Source

MaxSupportedMagicLeapControllers()

Gets the maximum number of Magic Leap controllers supported at a time.

Declaration
public static int MaxSupportedMagicLeapControllers()
Returns
Type Description
System.Int32
Remarks

@return the maximum number of Magic Leap controllers supported at a time.

| Improve this Doc View Source

New(UObject, Name)

Spawn an object of this class

Declaration
public static MagicLeapControllerFunctionLibrary New(UObject obj = null, Name name = default(Name))
Parameters
Type Name Description
UObject obj
Name name
Returns
Type Description
MagicLeapControllerFunctionLibrary
| Improve this Doc View Source

PlayControllerHapticFeedback(EControllerHand, EMLControllerHapticPattern, EMLControllerHapticIntensity)

Play haptic feedback on the controller.

Declaration
public static bool PlayControllerHapticFeedback(EControllerHand Hand, EMLControllerHapticPattern HapticPattern, EMLControllerHapticIntensity Intensity)
Parameters
Type Name Description
EControllerHand Hand
EMLControllerHapticPattern HapticPattern
EMLControllerHapticIntensity Intensity
Returns
Type Description
System.Boolean
Remarks

@param Hand Controller to play the haptic feedback on. @param HapticPattern Pattern to play on the controller. @param Intensity Intensity to play on the controller. @return True if the command to play the haptic feedback was successfully sent to the controller, false otherwise.

| Improve this Doc View Source

PlayControllerLED(EControllerHand, EMLControllerLEDPattern, EMLControllerLEDColor, Single)

Light up the LED on the Magic Leap Controller in the given pattern for the specified duration.

Declaration
public static bool PlayControllerLED(EControllerHand Hand, EMLControllerLEDPattern LEDPattern, EMLControllerLEDColor LEDColor, float DurationInSec)
Parameters
Type Name Description
EControllerHand Hand
EMLControllerLEDPattern LEDPattern
EMLControllerLEDColor LEDColor
System.Single DurationInSec
Returns
Type Description
System.Boolean
Remarks

@param Hand Controller to play the LED pattern on. @param LEDPattern Pattern to play on the controller. @param LEDColor Color of the LED. @param DurationInSec Duration (in seconds) to play the LED pattern. @return True if the command to play the LED pattern was successfully sent to the controller, false otherwise.

| Improve this Doc View Source

PlayControllerLEDEffect(EControllerHand, EMLControllerLEDEffect, EMLControllerLEDSpeed, EMLControllerLEDPattern, EMLControllerLEDColor, Single)

Starts a LED feedback effect using the specified pattern on the specified controller.

Declaration
public static bool PlayControllerLEDEffect(EControllerHand Hand, EMLControllerLEDEffect LEDEffect, EMLControllerLEDSpeed LEDSpeed, EMLControllerLEDPattern LEDPattern, EMLControllerLEDColor LEDColor, float DurationInSec)
Parameters
Type Name Description
EControllerHand Hand
EMLControllerLEDEffect LEDEffect
EMLControllerLEDSpeed LEDSpeed
EMLControllerLEDPattern LEDPattern
EMLControllerLEDColor LEDColor
System.Single DurationInSec
Returns
Type Description
System.Boolean
Remarks

@param Hand Controller to play the LED pattern on. @param LEDEffect Effect to play on the controller. @param LEDSpeed Effect speed. @param LEDPattern Pattern to play on the controller. @param LEDColor Color of the LED. @param DurationInSec Duration (in seconds) to play the LED pattern. @return True if the command to play the LED effect was successfully sent to the controller, false otherwise.

| Improve this Doc View Source

SetControllerTrackingMode(EMLControllerTrackingMode)

Set controller tracking mode.

Declaration
public static bool SetControllerTrackingMode(EMLControllerTrackingMode TrackingMode)
Parameters
Type Name Description
EMLControllerTrackingMode TrackingMode
Returns
Type Description
System.Boolean
Remarks

@param TrackingMode Controller tracking mode. @return True if the command to set the tracking mode was successfully sent to the controller, false otherwise.

Operators

| Improve this Doc View Source

Implicit(IntPtr to MagicLeapControllerFunctionLibrary)

Convert from IntPtr to UObject

Declaration
public static implicit operator MagicLeapControllerFunctionLibrary(IntPtr p)
Parameters
Type Name Description
System.IntPtr p
Returns
Type Description
MagicLeapControllerFunctionLibrary
  • Improve this Doc
  • View Source
Back to top Generated by DocFX