public void EnableInputSender(AirVRInputSender sender) { if (senders.ContainsKey(sender.name) == false) { senders.Add(sender.name, sender); if (initialized) { sender.OnRegistered(onairvr_RegisterInputSender(sender.name)); } } }
public void DisableInputSender(AirVRInputSender sender) { if (senders.ContainsKey(sender.name)) { if (sender.isRegistered) { onairvr_UnregisterInputSender((byte)sender.deviceID); sender.OnUnregistered(); } senders.Remove(sender.name); } }
public void PendState(AirVRInputSender sender, byte control, byte state) { PendStateImpl(sender.id, control, state); }
public void UnregisterInputSender(AirVRInputSender sender) { senders.Remove(sender.id); }
public void RegisterInputSender(AirVRInputSender sender) { senders[sender.id] = sender; }
public void PendRaycastHit(AirVRInputSender sender, byte control, Vector3 origin, Vector3 hitPosition, Vector3 hitNormal) { PendRaycastHitImpl(sender.id, control, origin, hitPosition, hitNormal); }
public void PendPose(AirVRInputSender sender, byte control, Vector3 position, Quaternion rotation) { PendPoseImpl(sender.id, control, position, rotation); }
public void PendQuaternion(AirVRInputSender sender, byte controlID, Quaternion value) { Assert.IsTrue(sender.isRegistered); PendInputFloat4Impl((byte)sender.deviceID, controlID, new Vector4(value.x, value.y, value.z, value.w), (byte)SendingPolicy.Always); }
public void PendAxis(AirVRInputSender sender, byte control, float axis) { PendAxisImpl(sender.id, control, axis); }
public void PendTrackedDeviceFeedback(AirVRInputSender sender, byte controlID, Vector3 rayOrigin, Vector3 hitPosition, Vector3 hitNormal) { Assert.IsTrue(sender.isRegistered); PendTrackedDeviceFeedbackImpl((byte)sender.deviceID, controlID, rayOrigin, hitPosition, hitNormal, (byte)SendingPolicy.NonzeroAlwaysZeroOnce); }
public void PendTransform(AirVRInputSender sender, byte controlID, Vector3 position, Quaternion orientation) { Assert.IsTrue(sender.isRegistered); PendInputTransformImpl((byte)sender.deviceID, controlID, position, orientation, (byte)SendingPolicy.Always); }
public void PendButton(AirVRInputSender sender, byte controlID, bool value) { PendAxis(sender, controlID, value ? 1.0f : 0.0f); }
public void PendButton(AirVRInputSender sender, byte controlID, float value) { PendAxis(sender, controlID, value); }
public void PendAxis(AirVRInputSender sender, byte controlID, float value) { Assert.IsTrue(sender.isRegistered); PendInputFloatImpl((byte)sender.deviceID, controlID, value, (byte)SendingPolicy.NonzeroAlwaysZeroOnce); }
public void PendVector2D(AirVRInputSender sender, byte controlID, Vector2 value) { Assert.IsTrue(sender.isRegistered); PendInputFloat2Impl((byte)sender.deviceID, controlID, value, (byte)SendingPolicy.Always); }
public bool CheckIfInputSenderAvailable(AirVRInputSender sender) { return(senders.ContainsValue(sender) && sender.isRegistered); }
public void PendAxis2D(AirVRInputSender sender, byte control, Vector2 axis2D) { PendAxis2DImpl(sender.id, control, axis2D); }
public void PendTouch(AirVRInputSender sender, byte controlID, Vector2 position, bool touch) { Assert.IsTrue(sender.isRegistered); PendInputTouchImpl((byte)sender.deviceID, controlID, position, touch ? 1.0f : 0.0f, (byte)SendingPolicy.NonzeroAlwaysZeroOnce); }