Skip to content

Instantly share code, notes, and snippets.

@GOROman
Last active August 29, 2015 14:04
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save GOROman/642b4705c58d3b25f13d to your computer and use it in GitHub Desktop.
Save GOROman/642b4705c58d3b25f13d to your computer and use it in GitHub Desktop.
[Unity] Oculus Rift DK2(SDK 0.4.0) でポジショントラッキング有効範囲か?判別
// Tracking State を得る
OVR.ovrTrackingState ts = OVRDevice.HMD.GetTrackingState();
// ポジショントラッキング されているか?
if ( (ts.StatusFlags & (uint)OVR.ovrStatusBits.ovrStatus_PositionTracked ) != 0 ) {
// ポジショントラッキング範囲内
print( "Tracking!" );
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment