-
Introduction
-
Tracking modes
-
ArUco markers and marker-based tracking features
-
ArUco markers
-
Marker-based tracking features
-
-
Marker-Based Location Sharing setup
- Setting up Marker-Based Location Sharing
- Creating ArUco markers for Marker-Based Location Sharing
- Aligning the height of a virtual scene using an ArUco marker
- Moving a user to a specific point in a virtual scene
- Setting up Marker-Based Location Sharing with VIVE Business Streaming
- Marker-Based Location Sharing APIs (AIO)
- Marker-Based Location Sharing APIs (PC VR)
-
LBE Mode/LBE Hybrid Mode setup
-
LBE map configuration
-
Marker-Based Drift Prevention setup
-
Marker-Based Advanced Relocation setup
-
Marker-Based Scene Alignment setup
- Setting up Marker-Based Scene Alignment
- Configuring the position of an ArUco marker in a virtual scene (Unity)
- Creating ArUco markers for Marker-Based Scene Alignment
- Setting up Marker-Based Scene Alignment with VIVE Business Streaming
- Marker-Based Scene Alignment APIs (AIO)
- Marker-Based Scene Alignment APIs (PC VR)
-
Simulator VR Mode setup
- Setting up Simulator VR Mode
- Pairing wrist trackers with a headset
- Installing an anchor controller or tracker in a VR simulator
- Coordinate alignment
- Anchor controller and tracker origin points
- Aligning VR and anchor coordinate systems using a VR controller
- Aligning VR and anchor coordinate systems using an ArUco marker
- Simulator VR Mode FAQs
-
Other services
-
Additional features
Aligning VR and anchor coordinate systems using an ArUco marker
-
Marker-Based Location Sharing must be set up to use this feature. For details, see Marker-Based Location Sharing setup.
-
Test the APIs before operating your VR simulator to make sure the coordinate systems work as expected.
-
Define the offset of the VR and anchor coordinate systems.
The offset must be defined before the VR and anchor coordinate systems can be aligned. Use the string key ClearRecenterXform to define the offset:
Controller
string key = "ClearRecenterXform"; Interop.WVR_SetParameters (WVR_DeviceType.WVR_DeviceType_HMD, Marshal.StringToHGlobalAnsi(key)); Interop.WVR_SetParameters (WVR_DeviceType.WVR_DeviceType_Controller_Right, Marshal.StringToHGlobalAnsi(key)); Interop.WVR_SetParameters (WVR_DeviceType.WVR_DeviceType_Controller_Left, Marshal.StringToHGlobalAnsi(key));
Wrist tracker
string key = "ClearRecenterXform"; Interop.WVR_SetParameters(WVR_DeviceType.WVR_DeviceType_HMD, Marshal.StringToHGlobalAnsi(key)); key = "ClearRecenterXformTR"; Interop.WVR_SetParameters(WVR_DeviceType.WVR_DeviceType_HMD, Marshal.StringToHGlobalAnsi(key));
-
Configure the string key used to align the VR and anchor coordinate systems.
The string key PLAYER01InCarOrg is used to align the VR and anchor coordinate systems. Configure this string key by using the parameters of your ArUco markers.
In the following illustration, the anchor coordinate system is based on the position and orientation of the ArUco markers, following the left-hand rule.
-
Modify
PLAYER01InCarOrg using the values
marker position,
marker orientation,
marker ID, and
marker size.
AIO
string key = "PLAYER00InCarOrg=0.0,0.0,0.0,0.0,0.0,0.0,1.0,1,0.2";// Tx, Ty, Tz, qx, qy, qz, qw, marker id, marker size uint RETURN_SIZE = 256; IntPtr value = Marshal.AllocHGlobal(new IntPtr(RETURN_SIZE)); Interop.WVR_GetParameters(WVR_DeviceType.WVR_DeviceType_HMD, Marshal.StringToHGlobalAnsi(key), value, RETURN_SIZE); string polling_value = Marshal.PtrToStringAnsi(value); Marshal.FreeCoTaskMem(value); if(string.Compare(polling_value, "InitMAErr") == 0) // initialization failed, should check config string { // write your error handling code here }
PC VR
string key = "PLAYER00InCarOrg="; string setting = "-0.4,0.9,-0.4,0.0,0.0,0.0,1.0,1,0.2"; // Tx,Ty,Tz,qx,qy,qz,qw,id,size key += setting; string result = SendRequestMessage(DeviceType.HMD, key); if (string.Compare(result, "InitMAErr") == 0) { // write your error handling code here }
-
Scan the marker.
AIO
// Start string key = "PLAYER00StartScan"; uint RETURN_SIZE = 256; IntPtr value = Marshal.AllocHGlobal(new IntPtr(RETURN_SIZE)); Interop.WVR_GetParameters(WVR_DeviceType.WVR_DeviceType_HMD, Marshal.StringToHGlobalAnsi(key), value, RETURN_SIZE); Marshal.FreeCoTaskMem(value); // Stop string key = "PLAYER00StopScan"; uint RETURN_SIZE = 256; IntPtr value = Marshal.AllocHGlobal(new IntPtr(RETURN_SIZE)); Interop.WVR_GetParameters(WVR_DeviceType.WVR_DeviceType_HMD, Marshal.StringToHGlobalAnsi(key), value, RETURN_SIZE); Marshal.FreeCoTaskMem(value);
PC VR
// Start string key = "PLAYER00StartScan"; SendRequestMessage(DeviceType.HMD, key); // Stop string key = "PLAYER00StopScan"; SendRequestMessage(DeviceType.HMD, key);
-
Optional: Check the scan status.
AIO
// Check scan string key = "PLAYER00CheckMA"; uint RETURN_SIZE = 256; IntPtr value = Marshal.AllocHGlobal(new IntPtr(RETURN_SIZE)); Interop.WVR_GetParameters(WVR_DeviceType.WVR_DeviceType_HMD, Marshal.StringToHGlobaltrToStringAnsi(value); Ansi(key), value, RETURN_SIZE); string polling_value = Marshal.PtrToStringAnsi(value); Marshal.FreeCoTaskMem(value); if (string.Compare(polling_value, "CTdone") == 0) // 2 markers scanned { //handling with 2nd marker scanned } else if (string.Compare(polling_value, "CTpass") == 0) // 1 marker scanned { //handling with first marker scanned }
PC VR
string key = "PLAYER00CheckMA"; string result = SendRequestMessage(DeviceType.HMD, key); if (string.Compare(result, "CTdone") == 0) { // handling with the second marker scanned } else if (string.Compare(result, "CTpass") == 0) { // handling with the first marker scanned }
-
Optional: Compensate for mechanical vibration using a low-pass filter.
You can use the string key PLAYER01PUM_HW_LPF_LEVEL to minimize mechanical vibration. Specify a filter level between 0 and 2. Adjust the filter level according to your needs.
AIO
string key = "PLAYER01PUM_HW_LPF_LEVEL=2"; Interop.WVR_SetParameters(WVR_DeviceType.WVR_DeviceType_HMD, Marshal.StringToHGlobalAnsi(key));
PC VR
string key = " PLAYER01PUM_HW_LPF_LEVEL="; string setting = "2"; key += setting; string result = SendRequestMessage(DeviceType.Controller_Left, key);