/// Reads the latest tracking data from the phone. This must be /// called before accessing any of the poses and matrices above. /// /// Multiple invocations per frame are OK: Subsequent calls merely yield the /// cached results of the first call. To minimize latency, it should be first /// called later in the frame (for example, in `LateUpdate`) if possible. public void UpdateState() { if (updatedToFrame != Time.frameCount) { updatedToFrame = Time.frameCount; device.UpdateState(); if (device.profileChanged) { if (distortionCorrection != DistortionCorrectionMethod.Native && device.RequiresNativeDistortionCorrection()) { DistortionCorrection = DistortionCorrectionMethod.Native; } if (stereoScreen != null && device.ShouldRecreateStereoScreen(stereoScreen.width, stereoScreen.height)) { Svr.SvrLog.Log("StereoScreen set to Null"); StereoScreen = null; } } DispatchEvents(); } }
public void UpdateDeviceState() { if (device != null) { device.UpdateState(); } }
/// Reads the latest tracking data from the phone. This must be /// Called before accessing any of the poses and matrices above. /// /// Multiple invocations per frame are OK: Subsequent calls merely yield the /// cached results of the first call. To minimize latency, it should be first /// called later in the frame (for example, in `LateUpdate`) if possible. public void UpdateState() { if (!updated) { device.UpdateState(); updated = true; } }
/// Reads the latest tracking data from the phone. This must be /// called before accessing any of the poses and matrices above. /// /// Multiple invocations per frame are OK: Subsequent calls merely yield the /// cached results of the first call. To minimize latency, it should be first /// called later in the frame (for example, in `LateUpdate`) if possible. public void UpdateState() { if (updatedToFrame != Time.frameCount) { updatedToFrame = Time.frameCount; device.UpdateState(); DispatchEvents(); } }
/// Reads the latest tracking data from the phone. This must be /// called before accessing any of the poses and matrices above. /// /// Multiple invocations per frame are OK: Subsequent calls merely yield the /// cached results of the first call. To minimize latency, it should be first /// called later in the frame (for example, in `LateUpdate`) if possible. public void UpdateState() { if (!updated) { updated = true; device.UpdateState(); DispatchEvents(); } }
/// Reads the latest tracking data from the phone. This must be /// called before accessing any of the poses and matrices above. /// /// Multiple invocations per frame are OK: Subsequent calls merely yield the /// cached results of the first call. To minimize latency, it should be first /// called later in the frame (for example, in `LateUpdate`) if possible. public void UpdateState() { if (updatedToFrame != Time.frameCount) { updatedToFrame = Time.frameCount; device.UpdateState(); if (device.profileChanged && distortionCorrectionEnabled) { DistortionCorrectionEnabled = true; } DispatchEvents(); } }
public void UpdateState() { if (!updated) { device.UpdateState(); if (TapIsTrigger) { if (Input.GetMouseButtonUp(0)) { device.triggered = true; } if (Input.GetKeyUp(KeyCode.Escape)) { device.tilted = true; } } updated = true; } }
/// Reads the latest tracking data from the phone. This must be /// called before accessing any of the poses and matrices above. /// /// Multiple invocations per frame are OK: Subsequent calls merely yield the /// cached results of the first call. To minimize latency, it should be first /// called later in the frame (for example, in `LateUpdate`) if possible. public void UpdateState() { if (updatedToFrame != Time.frameCount) { updatedToFrame = Time.frameCount; device.UpdateState(); if (device.profileChanged) { if (distortionCorrection != DistortionCorrectionMethod.None) { DistortionCorrection = DistortionCorrectionMethod.None; } if (stereoScreen != null && device.ShouldRecreateStereoScreen(stereoScreen.width, stereoScreen.height)) { StereoScreen = null; } } DispatchEvents(); } }