Features
Last updated: 4 months ago • 1 versions | Visibility: Public
Context
This article describes the features provided with the Lynx SDK.
New features are coming progressively with each update of the SDK.
AR/VR
The SDK allows you to enable or disable AR easily with custom features and configuration.
Open custom settings
Under Project Settings > OpenXR > Lynx-R1, you can access the custom settings.
Then, you can customize the settings.
- Start In AR: lets you decide if you want to start the experience in AR (checked) or in VR (unchecked)
- Disable Background in AR: when selected, it will disable your skybox in AR to use the solid color with alpha channel. Otherwise, your skybox will still appear in AR (be careful, using a skybox not able to manage alpha channel will lead to an opaque non AR skybox).
- Only VR Layer: gameobjects having this layer index will only be displayed in VR and are hidden in AR. You should create the matching layer if it does not exist.
- Only AR Layer: gameobjects having this layer index only be displayed in AR and are hidden in VR. You should create the matching layer if it does not exist.
- Visible in Full AR Tag: gameobjects having this tag will still be visible in Full AR. Other objects are disabled.
Enable or disable AR/VR from script
To enable or disable AR/VR at runtime, you can directly call LynxAPI methods.
LynxAPI.IsAR(); // Check if the application is currenlty in AR mode
LynxAPI.IsVR(); // Check if the application is currenlty in VR mode
LynxAPI.SetAR(); // Enable AR mode.
LynxAPI.SetVR(); // Disable AR mode.
LynxAPI.ToggleAR(); // Switch between AR and VR modes.
LynxAPI.SetAROnly(); // Enable AR only mode (disable all objects not having Visible in Full AR tag).
LynxAPI.SetAROnly(false); // Disable AR only mode (re-enable all objects not having Visible in Full AR tag and hiddern by SetAROnly).
LynxAPI.ToggleAROnly(); // Switch between AR and VR modes (based on Visible in Full AR tag)
LynxAPI.GetOpenXRInstance(); //Retrieve the OpenXR instance for more generic OpenXR API calls.
You can also access the event onARVRChanged:
public class TestARVRCallback : MonoBehaviour
{
public GameObject m_objectAR = null;
public GameObject m_objectVR = null;
void Awake()
{
LynxAPI.onARVRChanged += ARVRChanged;
}
public void ARVRChanged(bool isAR)
{
Debug.Log($"ARVR changed. Is AR? {isAR}");
m_objectAR.SetActive(isAR);
m_objectVR.SetActive(!isAR);
}
}
Cameras image recovery
Current version is provided via preview package.
Documentation for Video Capture is available in the Previews.
Environment mesh
(Work in progress)