public static SixenseControllerData GetControllerData(SixenseControllerHand hand) { sixenseControllerRawData rawData; sixenseGetNewestData((int)hand, out rawData); return(new SixenseControllerData(rawData)); }
public SixenseControllerData(sixenseControllerRawData data) { _position = data.Position; _rotationAxis = new RotationAxis(data.RotationX, data.RotationY, data.RotationZ); _joystick = new Joystick(data.JoystickX, data.JoystickY); _trigger = data.Trigger; _buttons = new Buttons(data.Buttons); _rotationQuaternion = data.RotationQuaternion; _isEnabled = data.Enabled == 1 ? true : false; _controllerIndex = data.ControllerIndex; _isDocked = data.IsDocked == 1 ? true : false; _hand = data.WhichHand == 0 ? SixenseControllerHand.LeftHand : SixenseControllerHand.RightHand; }
public SixenseControllerData(sixenseControllerRawData data) { _position = data.Position; _rotationAxis = new RotationAxis(data.RotationX, data.RotationY, data.RotationZ); _joystick = new Joystick(data.JoystickX, data.JoystickY); _trigger = data.Trigger; _buttons = new Buttons(data.Buttons); _rotationQuaternion = data.RotationQuaternion; _isEnabled = data.Enabled == 1 ? true : false; _controllerIndex = data.ControllerIndex; _isDocked = data.IsDocked == 1 ? true : false; _hand = data.WhichHand == 0 ? SixenseControllerHand.LeftHand : SixenseControllerHand.RightHand; }
public static bool IsControllerEnabled(SixenseControllerHand hand) { return(sixenseIsControllerEnabled((int)hand) == 1 ? true : false); }
public static SixenseControllerData GetControllerData(SixenseControllerHand hand) { sixenseControllerRawData rawData; sixenseGetNewestData((int)hand, out rawData); return new SixenseControllerData(rawData); }
public static bool IsControllerEnabled(SixenseControllerHand hand) { return sixenseIsControllerEnabled((int)hand) == 1 ? true : false; }