1
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

MacでHMDなしVive Trackerを使う

Posted at

Windowsでやれよって話なのだが、
Vive TrackerをHMD無しで使うデモを作るにあたり、
使い慣れているMacの環境でさくっと試したかった。
ただ、Macでやるリファレンスがあまりなかったので、メモ程度に残しておく。

環境

  • OSX 10.14.5(Mojave)
  • Unity 2019.1.8f1
  • SteamVR Unity Plugin v2.3.0

手順

下記を参考にしながら進める

【Unity】ViveのHMDなしにTrackerを使う

VRSettingsを変える

Macの場合、default.vrsettingsのパスは下記(結構深いところにある)

~/Library/Application Support/Steam/steamapps/common/SteamVR/SteamVR.app/Contents/MacOS/runtime/resources/settings/default.vrsettings

Unity側の設定

Player SettingでVirtual Reality Supportedのチェックを外す
が、勝手にチェックが入る

consoleに

[SteamVR Setup] Enabled virtual reality support in Player Settings. (you can disable this by unchecking Assets/SteamVR/SteamVR_Settings.autoEnableVR)

と出ているので、Assets/SteamVR/Scripts/SteamVR_Setting.csautoEnableVRfalseにする
が、まだ勝手にチェックが入る(なぜ?)

あまり深追いせず、取り急ぎ Assets/SteamVR/Editor/SteamVR_AutoEnableVRの54~56行目をコメントアウトする

if (UnityEditor.PlayerSettings.virtualRealitySupported == false)
{
    //UnityEditor.PlayerSettings.virtualRealitySupported = true;
    //enabledVR = true;
    //Debug.Log("<b>[SteamVR Setup]</b> Enabled virtual reality support in Player Settings. (you can disable this by unchecking Assets/SteamVR/SteamVR_Settings.autoEnableVR)");
}

他は参考サイトの通りでトラッキングできた。

参考

【Unity】ViveのHMDなしにTrackerを使う

1
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?