検証環境
- Unity:2019.4.2f1
- VisualStudio:2019
- Device:HoloLens2
コード
コードはこちらで回答されていたものです。
using System;
が必要ですので忘れないように。
public void LaunchEyeTracking() { #if WINDOWS_UWP UnityEngine.WSA.Application.InvokeOnUIThread(async () => { bool result = await global::Windows.System.Launcher.LaunchUriAsync(new System.Uri("ms-hololenssetup://EyeTracking")); if (!result) { Debug.LogError("Launching URI failed to launch."); } }, false); #else Debug.LogError("Launching eye tracking not supported Windows UWP"); #endif }
実行すると、キャリブレーションのアプリに遷移します。 キャリブレーションを終えても、元のアプリには遷移できないのであしからず。。