/******************************************************************************* Copyright © 2015-2022 PICO Technology Co., Ltd.All rights reserved. NOTICE:All information contained herein is, and remains the property of PICO Technology Co., Ltd. The intellectual and technical concepts contained herein are proprietary to PICO Technology Co., Ltd. and may be covered by patents, patents in process, and are protected by trade secret or copyright law. Dissemination of this information or reproduction of this material is strictly forbidden unless prior written permission is obtained from PICO Technology Co., Ltd. *******************************************************************************/ using System; using System.Collections.Generic; using UnityEngine.XR; namespace Unity.XR.PICO.TOBSupport { /** * Enterprise APIs are only supported by enterprise devices, including PICO Neo2, Neo2 Eye, Neo3 Pro、Neo3 Pro Eye, G2 4K/4K E/4K Plus (system version 4.0.3 or later), and PICO 4 Enterprise. * Do not use them on consumer devices. */ public class PXR_Enterprise { /// /// Initializes the enterprise service for a specified object. Must be called before calling other enterprise APIs. /// /// Whether the enterprise service has been initialized: /// * `true`: success /// * `false`: failure /// @note OpenXR does not support the returns. The returns belong to EasyAR initialization. public static bool InitEnterpriseService() { PXR_EnterpriseTools.Instance.StartUp(); bool result = PXR_EnterprisePlugin.UPxr_InitEnterpriseService(); return result; } /// /// Binds the enterprise service. Must be called before calling other system related functions. /// /// /// Service-binding result callback that allows for bool values: /// * `true`: success /// * `false`: failure /// If no callback is specified, the parameter will default to null. /// public static void BindEnterpriseService(Action callback=null) { PXR_EnterprisePlugin.UPxr_BindEnterpriseService(callback); } /// /// Unbinds the enterprise service. /// public static void UnBindEnterpriseService() { PXR_EnterprisePlugin.UPxr_UnBindEnterpriseService(); } /// /// Gets the specified type of device information. /// /// The target information type. Enumerations: /// * `ELECTRIC_QUANTITY`: battery /// * `PUI_VERSION`: system version /// * `EQUIPMENT_MODEL`: device model /// * `EQUIPMENT_SN`: device SN code /// * `CUSTOMER_SN`: customer SN code /// * `INTERNAL_STORAGE_SPACE_OF_THE_DEVICE`: device storage /// * `DEVICE_BLUETOOTH_STATUS`: bluetooth status /// * `BLUETOOTH_NAME_CONNECTED`: bluetooth name /// * `BLUETOOTH_MAC_ADDRESS`: bluetooth MAC address /// * `DEVICE_WIFI_STATUS`: Wi-Fi connection status /// * `WIFI_NAME_CONNECTED`: connected Wi-Fi name /// * `WLAN_MAC_ADDRESS`: WLAN MAC address /// * `DEVICE_IP`: device IP address /// * `CHARGING_STATUS`: device charging status /// /// The specified type of device information. For `CHARGING_STATUS`, an int value will be returned: `2`-charging; `3`-not charging. public static string StateGetDeviceInfo(SystemInfoEnum type) { return PXR_EnterprisePlugin.UPxr_StateGetDeviceInfo(type); } /// /// Shuts down or reboots the device. /// @note This is a protected API. You need to add `` /// to the app's AndroidManifest.xml file for calling this API, after which the app is unable to be published on the PICO Store. /// /// Device action. Enumerations: /// * `DEVICE_CONTROL_REBOOT` /// * `DEVICE_CONTROL_SHUTDOWN` /// /// Callback: /// * `1`: failed to shut down or reboot the device /// * `2`: no permission to perform this operation /// public static void ControlSetDeviceAction(DeviceControlEnum deviceControl, Action callback) { PXR_EnterprisePlugin.UPxr_ControlSetDeviceAction(deviceControl, callback); } /// /// Installs or uninstalls app silently. /// @note This is a protected API. You need to add `` /// to the app's AndroidManifest.xml file for calling this API, after which the app is unable to be published on the PICO Store. /// /// The action. Enumerations: /// * `PACKAGE_SILENCE_INSTALL`: silent installation /// * `PACKAGE_SILENCE_UNINSTALL`: silent uninstallation /// /// The path to the app package for silent installation or the name of the app package for silent uninstallation. /// Callback: /// * `0`: success /// * `1`: failure /// * `2`: no permission to perform this operation /// public static void ControlAPPManager(PackageControlEnum packageControl, string path, Action callback) { PXR_EnterprisePlugin.UPxr_ControlAPPManager(packageControl, path, callback); } /// /// Sets a Wi-Fi that the device is automatically connected to. /// /// Wi-Fi name. /// Wi-Fi password. /// Callback: /// * `true`: connected /// * `false`: failed to connect /// public static void ControlSetAutoConnectWIFI(string ssid, string pwd, Action callback) { PXR_EnterprisePlugin.UPxr_ControlSetAutoConnectWIFI(ssid, pwd, callback); } /// /// Removes the Wi-Fi that the device is automatically connected to. /// /// Callback: /// * `true`: removed /// * `false`: failed to remove /// public static void ControlClearAutoConnectWIFI(Action callback) { PXR_EnterprisePlugin.UPxr_ControlClearAutoConnectWIFI(callback); } /// /// Sets the Home button event. /// /// Target event. Enumerations: /// * `SINGLE_CLICK`: single-click /// * `DOUBLE_CLICK`: double-click /// * `LONG_PRESS`: long press /// * `SINGLE_CLICK_RIGHT_CTL`: single-click on the right controller's Home button /// * `DOUBLE_CLICK_RIGHT_CTL`: double-click on the right controller's Home button /// * `LONG_PRESS_RIGHT_CTL`: long press on the right controller's Home button /// * `SINGLE_CLICK_LEFT_CTL`: single-click on the left controller's Home button /// * `DOUBLE_CLICK_LEFT_CTL`: double-click on the left controller's Home button /// * `LONG_PRESS_LEFT_CTL`: long press on the left controller's Home button /// * `SINGLE_CLICK_HMD`: single-click on the HMD's Home button /// * `DOUBLE_CLICK_HMD`: double-click on the HMD's Home button /// * `LONG_PRESS_HMD`: long press on the HMD's Home button /// /// The function of the event. Enumerations: /// * `VALUE_HOME_GO_TO_SETTING`: go to Settings /// * `VALUE_HOME_BACK`: back (only supported by PICO G2 4K) /// * `VALUE_HOME_RECENTER`: recenter the screen /// * `VALUE_HOME_OPEN_APP`: open a specified app /// * `VALUE_HOME_DISABLE`: disable the Home button /// * `VALUE_HOME_GO_TO_HOME`: open the launcher /// * `VALUE_HOME_SEND_BROADCAST`: send Home-button-click broadcast /// * `VALUE_HOME_CLEAN_MEMORY`: clear background apps /// * `VALUE_HOME_QUICK_SETTING`: enable quick settings /// * `VALUE_HOME_SCREEN_CAP`: enable screen capture /// * `VALUE_HOME_SCREEN_RECORD`: enable screen recording /// /// Callback: /// * `true`: success /// * `false`: failure /// public static void PropertySetHomeKey(HomeEventEnum eventEnum, HomeFunctionEnum function, Action callback) { PXR_EnterprisePlugin.UPxr_PropertySetHomeKey(eventEnum, function, callback); } /// /// Sets extended settings for the Home button. /// /// Target event. Enumerations: /// * `SINGLE_CLICK_RIGHT_CTL`: single-click on the right controller's Home button /// * `DOUBLE_CLICK_RIGHT_CTL`: double-click on the right controller's Home button /// * `LONG_PRESS_RIGHT_CTL`: long press on the right controller's Home button /// * `SINGLE_CLICK_LEFT_CTL`: single-click on the left controller's Home button /// * `DOUBLE_CLICK_LEFT_CTL`: double-click on the left controller's Home button /// * `LONG_PRESS_LEFT_CTL`: long press on the left controller's Home button /// * `SINGLE_CLICK_HMD`: single-click on the HMD's Home button /// * `DOUBLE_CLICK_HMD`: double-click on the HMD's Home button /// * `LONG_PRESS_HMD`: long press on the HMD's Home button /// /// The function of the event. Enumerations: /// * `VALUE_HOME_GO_TO_SETTING`: go to Settings /// * `VALUE_HOME_BACK`: back (only supported by PICO G2 4K) /// * `VALUE_HOME_RECENTER`: recenter the screen /// * `VALUE_HOME_OPEN_APP`: open a specified app /// * `VALUE_HOME_DISABLE`: disable the Home button /// * `VALUE_HOME_GO_TO_HOME`: open the launcher /// * `VALUE_HOME_SEND_BROADCAST`: send Home-key-click broadcast /// * `VALUE_HOME_CLEAN_MEMORY`: clear background apps /// * `VALUE_HOME_QUICK_SETTING`: enable quick settings /// * `VALUE_HOME_SCREEN_CAP`: enable screen capture /// * `VALUE_HOME_SCREEN_RECORD`: enable screen recording /// /// The interval of key pressing is set only if there is the double click event or long pressing event. When shortly pressing the Home button, pass `0`. /// Pass `null`. /// Pass `null`. /// Callback: /// * `true`: set /// * `false`: failed to set /// public static void PropertySetHomeKeyAll(HomeEventEnum eventEnum, HomeFunctionEnum function, int timesetup, string pkg, string className, Action callback) { PXR_EnterprisePlugin.UPxr_PropertySetHomeKeyAll(eventEnum, function, timesetup, pkg, className, callback); } /// /// Sets the Power button's event. /// /// Whether it is a single click event: /// * `true`: single-click event /// * `false`: long-press event /// /// Enable or disable the Power button: /// * `true`: enable /// * `false`: disable /// /// Callback: /// * `0`: set /// * `1`: failed to set /// public static void PropertyDisablePowerKey(bool isSingleTap, bool enable, Action callback) { PXR_EnterprisePlugin.UPxr_PropertyDisablePowerKey(isSingleTap, enable, callback); } /// /// Sets the time the screen turns off when the device is not in use. /// /// Screen off timeout. Enumerations: /// * `Never`: never off /// * `THREE`: 3s (only supported by PICO G2 4K) /// * `TEN`: 10s (only supported by PICO G2 4K) /// * `THIRTY`: 30s /// * `SIXTY`: 60s /// * `THREE_HUNDRED`: 5 mins /// * `SIX_HUNDRED`: 10 mins /// /// Callback: /// * `0`: set /// * `1`: failed to set /// * `10`: the screen off timeout should not be longer than the system sleep timeout /// public static void PropertySetScreenOffDelay(ScreenOffDelayTimeEnum timeEnum, Action callback) { PXR_EnterprisePlugin.UPxr_PropertySetScreenOffDelay(timeEnum, callback); } /// /// Sets the time the system sleeps when the device is not in use. /// /// System sleep timeout. Enumerations: /// * `Never`: never sleep /// * `FIFTEEN`: 15s (only supported by PICO G2 4K) /// * `THIRTY`: 30s (only supported by PICO G2 4K) /// * `SIXTY`: 60s (only supported by PICO G2 4K) /// * `THREE_HUNDRED`: 5 mins /// * `SIX_HUNDRED`: 10 mins /// * `ONE_THOUSAND_AND_EIGHT_HUNDRED`: 30 mins /// public static void PropertySetSleepDelay(SleepDelayTimeEnum timeEnum) { PXR_EnterprisePlugin.UPxr_PropertySetSleepDelay(timeEnum); } /// /// Switches specified system function on/off. /// /// Function name. Enumerations: /// * `SFS_USB`: USB debugging /// * `SFS_AUTOSLEEP`: auto sleep /// * `SFS_SCREENON_CHARGING`: screen-on charging /// * `SFS_OTG_CHARGING`: OTG charging (supported by G2 devices) /// * `SFS_RETURN_MENU_IN_2DMODE`: display the Return icon on the 2D screen /// * `SFS_COMBINATION_KEY`: combination key /// * `SFS_CALIBRATION_WITH_POWER_ON`: calibration with power on /// * `SFS_SYSTEM_UPDATE`: system update (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_CAST_SERVICE`: phone casting service /// * `SFS_EYE_PROTECTION`: eye-protection mode /// * `SFS_SECURITY_ZONE_PERMANENTLY`: permanently disable the 6DoF play area (supported by PICO Neo2 devices) /// * `SFS_GLOBAL_CALIBRATION`: global calibration (supported by PICO G2 devices) /// * `SFS_Auto_Calibration`: auto calibration /// * `SFS_USB_BOOT`: USB plug-in boot /// * `SFS_VOLUME_UI`: global volume UI (need to restart the device to make the setting take effect) /// * `SFS_CONTROLLER_UI`: global controller connected UI /// * `SFS_NAVGATION_SWITCH`: navigation bar /// * `SFS_SHORTCUT_SHOW_RECORD_UI`: screen recording button UI /// * `SFS_SHORTCUT_SHOW_FIT_UI`: PICO fit UI /// * `SFS_SHORTCUT_SHOW_CAST_UI`: screencast button UI /// * `SFS_SHORTCUT_SHOW_CAPTURE_UI`: screenshot button UI /// * `SFS_USB_FORCE_HOST`: set the Neo3 Pro/Pro Eye device as the host device /// * `SFS_SET_DEFAULT_SAFETY_ZONE`: set a default play area for PICO Neo3 and PICO 4 series devices /// * `SFS_ALLOW_RESET_BOUNDARY`: allow to reset customized boundary for PICO Neo3 series devices /// * `SFS_BOUNDARY_CONFIRMATION_SCREEN`: whether to display the boundary confirmation screen for PICO Neo3 and PICO 4 series devices /// * `SFS_LONG_PRESS_HOME_TO_RECENTER`: long press the Home button to recenter for PICO Neo3 and PICO 4 series devices /// * `SFS_POWER_CTRL_WIFI_ENABLE`: stay connected to the network when the device sleeps/turns off (supported by PICO Neo3 Pro with system version 4.8.0 or later and PICO 4 Enterprise with system version OTA-5.2.8 or later) /// * `SFS_WIFI_DISABLE`: disable Wi-Fi (supported by PICO Neo3 Pro with system version 4.8.0 or later and PICO 4 Enterprise with system version OTA-5.2.8 or later) /// * `SFS_SIX_DOF_SWITCH`: 6DoF position tracking for PICO Neo3 and PICO 4 series devices /// * `SFS_INVERSE_DISPERSION`: anti-dispersion (supported by PICO Neo3 Pro with system version 4.8.0 or later and PICO 4 Enterprise with system version OTA0-5.2.8 or later) /// * `SFS_LOGCAT`: system log switch (/data/logs) (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_PSENSOR`: PSensor switch (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SYSTEM_UPDATE_OTA`: OTA upgrade (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SYSTEM_UPDATE_APP`: app upgrade and update (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SHORTCUT_SHOW_WLAN_UI`: quickly set whether to show the WLAN button (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SHORTCUT_SHOW_BOUNDARY_UI`: quickly set whether to show the boundary button (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SHORTCUT_SHOW_BLUETOOTH_UI`: quickly set whether to show the bluetooth button (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SHORTCUT_SHOW_CLEAN_TASK_UI`: quickly set whether to show the one-click clear button (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SHORTCUT_SHOW_IPD_ADJUSTMENT_UI`: quickly set whether to show the IPD adjustment button (supported by PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SHORTCUT_SHOW_POWER_UI`: quickly set whether to show the power button (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SHORTCUT_SHOW_EDIT_UI`: quickly set whether to show the edit button (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_BASIC_SETTING_APP_LIBRARY_UI`: the button for customizing the app library (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_BASIC_SETTING_SHORTCUT_UI`: the button for customizing quick settings (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_LED_FLASHING_WHEN_SCREEN_OFF`: whether to keep the LED indicator light on when the device's screen is off and the battery is below 20% (supported by PICO G3 devices) /// * `SFS_BASIC_SETTING_CUSTOMIZE_SETTING_UI`: customize settings item to show or hide in basic settings /// * `SFS_BASIC_SETTING_SHOW_APP_QUIT_CONFIRM_DIALOG`: whether to show the app-quit dialog box when switching to a new app /// * `SFS_BASIC_SETTING_KILL_BACKGROUND_VR_APP`: whether to kill background VR apps (`1`: kill, and this is the default setting; `2`: do not kill) /// * `SFS_BASIC_SETTING_SHOW_CAST_NOTIFICATION`: whether to show a blue icon when casting the screen. The icon is displayed by default, and you can set the value to `0` to hide it. /// * `SFS_AUTOMATIC_IPD`: auto IPD switch (supported by PICO Neo3 series and PICO 4 Enterprise with system version 5.7.0 or later) /// * `SFS_QUICK_SEETHROUGH_MODE`: quick seethrough mode switch (supported by PICO Neo3 series and PICO 4 Enterprise with system version 5.7.0 or later) /// * `SFS_HIGN_REFERSH_MODE`: high refresh mode switch (supported by PICO Neo3 series and PICO 4 Enterprise with system version 5.7.0 or later) /// * `SFS_SEETHROUGH_APP_KEEP_RUNNING`: set whether to keep the app running under the seethrough mode (supported by PICO Neo3 series and PICO 4 Enterprise with system version 5.8.0 or later) /// * `SFS_OUTDOOR_TRACKING_ENHANCEMENT`: enhance outdoor position tracking (supported by PICO Neo3 series and PICO 4 Enterprise with system version 5.8.0 or later) /// * `SFS_AUTOIPD_AUTO_COMFIRM`: quick auto-IPD (supported by PICO 4 Enterprise with system version 5.8.0 or later) /// * `SFS_LAUNCH_AUTOIPD_IF_GLASSES_WEARED`: set whether to launch auto-IPD after wearing the headset (supported by PICO 4 Enterprise with system version 5.8.0 or later) /// * `SFS_GESTURE_RECOGNITION_HOME_ENABLE`: Home gesture switch (supported by PICO Neo3 series and PICO 4 Enterprise with system version 5.8.0 or later) /// * `SFS_GESTURE_RECOGNITION_RESET_ENABLE`: enable/disable the Reset gesture (supported by PICO Neo3 series and PICO 4 Enterprise with system version 5.8.0 or later) /// * `SFS_AUTO_COPY_FILES_FROM_USB_DEVICE`: automatically import OTG resources (supported by PICO Neo3 series and PICO 4 Enterprise with system version 5.8.0 or later) /// /// Whether to switch the function on/off: /// * `S_ON`: switch on /// * `S_OFF`: switch off /// public static void SwitchSystemFunction(SystemFunctionSwitchEnum systemFunction, SwitchEnum switchEnum) { PXR_EnterprisePlugin.UPxr_SwitchSystemFunction(systemFunction, switchEnum); } /// /// Sets the USB configuration mode. /// /// USB configuration mode. Enumerations: /// * `MTP`: MTP mode /// * `CHARGE`: charging mode /// public static void SwitchSetUsbConfigurationOption(USBConfigModeEnum uSBConfigModeEnum) { PXR_EnterprisePlugin.UPxr_SwitchSetUsbConfigurationOption(uSBConfigModeEnum); } /// /// Sets the duration after which the controllers enter the pairing mode. /// @note Supported by PICO Neo3 Pro (system version 5.4.0 or later) and PICO 4 Enterprise (system version 5.2.8 or later) /// /// Duration enumerations: /// * `SIX`: 6 seconds /// * `FIFTEEN`: 15 seconds /// * `SIXTY`: 60 seconds /// * `ONE_HUNDRED_AND_TWENTY`: 120 seconds (2 minutes) /// * `SIX_HUNDRED`: 600 seconds (5 minutes) /// * `NEVER`: never enter the pairing mode /// /// Returns the result: /// * `0`: failure /// * `1`: success /// public static void SetControllerPairTime(ControllerPairTimeEnum timeEnum, Action callback) { PXR_EnterprisePlugin.UPxr_SetControllerPairTime(timeEnum, callback); } /// /// Gets the duration after which the controllers enter the pairing mode. /// @note Supported by PICO Neo3 Pro (system version 5.4.0 or later) and PICO 4 Enterprise (system version 5.2.8 or later) /// /// Returns a duration enumeration from the following: /// * `SIX`: 6 seconds /// * `FIFTEEN`: 15 seconds /// * `SIXTY`: 60 seconds /// * `ONE_HUNDRED_AND_TWENTY`: 120 seconds (2 minutes) /// * `SIX_HUNDRED`: 600 seconds (5 minutes) /// * `NEVER`: never enter the pairing mode /// public static void GetControllerPairTime(Action callback) { PXR_EnterprisePlugin.UPxr_GetControllerPairTime(callback); } /// /// Turns the screen on. /// @note This is a protected API. You need to add `` /// to the app's AndroidManifest.xml file for calling this API, after which the app is unable to be published on the PICO Store. /// public static void ScreenOn() { PXR_EnterprisePlugin.UPxr_ScreenOn(); } /// /// Turns the screen off. /// @note This is a protected API. You need to add `` /// to the app's AndroidManifest.xml file for calling this API, after which the app is unable to be published on the PICO Store. /// public static void ScreenOff() { PXR_EnterprisePlugin.UPxr_ScreenOff(); } /// /// Acquires the wake lock. /// public static void AcquireWakeLock() { PXR_EnterprisePlugin.UPxr_AcquireWakeLock(); } /// /// Releases the wake lock. /// public static void ReleaseWakeLock() { PXR_EnterprisePlugin.UPxr_ReleaseWakeLock(); } /// /// Enables the Confirm button. /// public static void EnableEnterKey() { PXR_EnterprisePlugin.UPxr_EnableEnterKey(); } /// /// Disables the Confirm button. /// public static void DisableEnterKey() { PXR_EnterprisePlugin.UPxr_DisableEnterKey(); } /// /// Enables the Volume button. /// public static void EnableVolumeKey() { PXR_EnterprisePlugin.UPxr_EnableVolumeKey(); } /// /// Disables the Volume button. /// public static void DisableVolumeKey() { PXR_EnterprisePlugin.UPxr_DisableVolumeKey(); } /// /// Enables the Back button. /// public static void EnableBackKey() { PXR_EnterprisePlugin.UPxr_EnableBackKey(); } /// /// Disables the Back button. /// public static void DisableBackKey() { PXR_EnterprisePlugin.UPxr_DisableBackKey(); } /// /// Resets all buttons to default configuration. /// /// Whether all keys have been successfully reset to default configuration: /// * `true`: reset /// * `false`: failed to reset /// public static void ResetAllKeyToDefault(Action callback) { PXR_EnterprisePlugin.UPxr_ResetAllKeyToDefault(callback); } /// /// Sets an app as the launcher app. Need to restart the device to make the setting work. /// /// (deprecated) /// The app's package name. public static void SetAPPAsHome(SwitchEnum switchEnum, string packageName) { PXR_EnterprisePlugin.UPxr_SetAPPAsHome(switchEnum, packageName); } /// /// Force quits app(s) by passing app PID or package name. /// @note This is a protected API. You need to add `` /// to the app's AndroidManifest.xml file for calling this API, after which the app is unable to be published on the PICO Store. /// /// An array of app PID(s). /// An array of package name(s). public static void KillAppsByPidOrPackageName(int[] pids, string[] packageNames) { PXR_EnterprisePlugin.UPxr_KillAppsByPidOrPackageName(pids, packageNames); } /// /// Force quits background app(s) expect those in the allowlist. /// @note This is a protected API. You need to add `` /// to the app's AndroidManifest.xml file for calling this API, after which the app is unable to be published on the PICO Store. /// /// An array of package name(s) to be added to the allowlist. The corresponding app(s) in the allowlist will not be force quit. public static void KillBackgroundAppsWithWhiteList(string[] packageNames) { PXR_EnterprisePlugin.UPxr_KillBackgroundAppsWithWhiteList(packageNames); } /// /// Freezes the screen to the front. The screen will turn around with the HMD. /// @note Supported by G2 4K and Neo2 devices. /// /// Whether to freeze the screen: /// * `true`: freeze /// * `false`: stop freezing /// public static void FreezeScreen(bool freeze) { PXR_EnterprisePlugin.UPxr_FreezeScreen(freeze); } /// /// Turns on the screencast function. /// public static void OpenMiracast() { PXR_EnterprisePlugin.UPxr_OpenMiracast(); } /// /// Gets the status of the screencast function. /// /// The status of the screencast function: /// * `true`: on /// * `false`: off /// public static bool IsMiracastOn() { return PXR_EnterprisePlugin.UPxr_IsMiracastOn(); } /// /// Turns off the screencast function. /// public static void CloseMiracast() { PXR_EnterprisePlugin.UPxr_CloseMiracast(); } /// /// Starts looking for devices that can be used for screen casting. /// public static void StartScan() { PXR_EnterprisePlugin.UPxr_StartScan(); } /// /// Stops looking for devices that can be used for screen casting. /// public static void StopScan() { PXR_EnterprisePlugin.UPxr_StopScan(); } /// /// Casts the screen to the specified device. /// /// A modelJson structure containing the following fields: /// * `deviceAddress` /// * `deviceName` /// * `isAvailable` (`true`-device available; `false`-device not available) /// public static void ConnectWifiDisplay(string modelJson) { PXR_EnterprisePlugin.UPxr_ConnectWifiDisplay(modelJson); } /// /// Stops casting the screen to the current device. /// public static void DisConnectWifiDisplay() { PXR_EnterprisePlugin.UPxr_DisConnectWifiDisplay(); } /// /// Forgets the device that have been connected for screencast. /// /// Device address. public static void ForgetWifiDisplay(string address) { PXR_EnterprisePlugin.UPxr_ForgetWifiDisplay(address); } /// /// Renames the device connected for screencast. The name is only for local storage. /// /// The MAC address of the device. /// The new device name. public static void RenameWifiDisplay(string address, string newName) { PXR_EnterprisePlugin.UPxr_RenameWifiDisplay(address, newName); } /// /// Sets the callback for the scanning result, which returns `List` that contains the devices previously connected for screencast and the devices currently found for screencast. /// /// /// Returns `List` that contains the currently scanned device. /// public static void SetWDModelsCallback(Action> models) { PXR_EnterprisePlugin.UPxr_SetWDModelsCallback(models); } /// /// Sets the callback for the scanning result, which returns the JSON string that contains the devices previously connected for screencast and the devices currently found for screencast. /// /// /// Returns a JSON string that contains the currently scanned device. /// public static void SetWDJsonCallback(Action callback) { PXR_EnterprisePlugin.UPxr_SetWDJsonCallback(callback); } /// /// Manually updates the list of devices for screencast. /// public static void UpdateWifiDisplays() { PXR_EnterprisePlugin.UPxr_UpdateWifiDisplays(); } /// /// Gets the information of the currently connected device. /// /// The information of the currently connected device. public static string GetConnectedWD() { return PXR_EnterprisePlugin.UPxr_GetConnectedWD(); } /// /// Switches the large space scene on. /// @note Supported by 6Dof devices. /// /// Whether to switch the large space scene on: /// * `true`: switch on /// * `false`: not to switch on /// /// Callback: /// * `true`: success /// * `false`: failure /// public static void SwitchLargeSpaceScene(bool open, Action callback) { PXR_EnterprisePlugin.UPxr_SwitchLargeSpaceScene(open, callback); } /// /// Gets the status of the large space scene. /// @note Supported by 6Dof devices. /// /// Returns the status of large space: /// * `0`: switched off /// * `1`: switched on /// public static void GetSwitchLargeSpaceStatus(Action callback) { PXR_EnterprisePlugin.UPxr_GetSwitchLargeSpaceStatus(callback); } /// /// Saves the large space map. /// @note Supported by 6Dof devices. /// /// Whether the large space map has been saved: /// * `true`: saved /// * `false`: failed to save /// public static bool SaveLargeSpaceMaps() { return PXR_EnterprisePlugin.UPxr_SaveLargeSpaceMaps(); } /// /// Exports maps. The exported maps are stored in the /maps/export file. /// @note Supported by 6Dof devices. /// /// Returns the result: /// * `true`: exported /// * `false`: failed to export /// public static void ExportMaps(Action callback) { PXR_EnterprisePlugin.UPxr_ExportMaps(callback); } /// /// Imports maps. Need to copy maps to the /maps folder. /// @note Supported by 6Dof devices. /// /// Returns the result: /// * `true`: imported /// * `false`: failed to import /// public static void ImportMaps(Action callback) { PXR_EnterprisePlugin.UPxr_ImportMaps(callback); } /// /// Gets each CPU's utilization for the current device. /// /// An array of CPU utilization info. public static float[] GetCpuUsages() { return PXR_EnterprisePlugin.UPxr_GetCpuUsages(); } /// /// Gets device temperature in Celsius. /// /// The requested type of device temperature: /// * `DEVICE_TEMPERATURE_CPU`: CPU temperature /// * `DEVICE_TEMPERATURE_GPU`: GPU temperature /// * `DEVICE_TEMPERATURE_BATTERY`: battery temperature /// * `DEVICE_TEMPERATURE_SKIN`: surface temperature /// /// The requested source of device temperature: /// * `TEMPERATURE_CURRENT`: current temperature /// * `TEMPERATURE_THROTTLING`: temperature threshold for throttling /// * `TEMPERATURE_SHUTDOWN`: temperature threshold for shutdown /// * `TEMPERATURE_THROTTLING_BELOW_VR_MIN`: temperature threshold for throttling. If the actual temperature is higher than the threshold, the lowest clock frequency for VR mode will not be met /// /// An array of requested float device temperatures in Celsius. public static float[] GetDeviceTemperatures(int type, int source) { return PXR_EnterprisePlugin.UPxr_GetDeviceTemperatures(type, source); } /// /// Captures the current screen. /// @note Not supported by G2 4K devices. /// public static void Capture() { PXR_EnterprisePlugin.UPxr_Capture(); } /// /// Records the screen. Call this function again to stop recording. /// @note Not supported by G2 4K devices. /// public static void Record() { PXR_EnterprisePlugin.UPxr_Record(); } /// /// Connects the device to a specified Wi-Fi. /// /// Wi-Fi name. /// Wi-Fi password. /// Reserved parameter, pass `0` by default. /// The callback for indicating whether the Wi-Fi connection is successful: /// * `0`: connected /// * `1`: password error /// * `2`: unknown error /// public static void ControlSetAutoConnectWIFIWithErrorCodeCallback(String ssid, String pwd, int ext, Action callback) { PXR_EnterprisePlugin.UPxr_ControlSetAutoConnectWIFIWithErrorCodeCallback(ssid, pwd, ext, callback); } /// /// Keeps an app active. In other words, improves the priority of an app, thereby making the system not to force quit the app. /// @note Supported by PICO Neo3 Pro (system version 4.8.0 or later) and PICO 4 Enterprise (system version OTA-5.2.8 or later). /// /// App package name. /// Whether to keep the app active (i.e., whether to enhance the priority of the app): /// * `true`: keep /// * `false`: not keep /// /// Reserved parameter, pass `0`. public static void AppKeepAlive(String appPackageName, bool keepAlive, int ext) { PXR_EnterprisePlugin.UPxr_AppKeepAlive(appPackageName, keepAlive, ext); } /// /// Schedules auto startup for the device. /// @note Supported by PICO Neo3 Pro (system version 4.8.0 or later) and PICO 4 Enterprise (system version OTA-5.2.8 or later). /// /// Year, for example, `2022`. /// Month, for example, `2`. /// Day, for example, `22`. /// Hour, for example, `22`. /// Minute, for example, `22`. /// Whether to enable scheduled auto startup for the device: /// * `true`: enable /// * `false`: disable /// public static void TimingStartup(int year, int month, int day, int hour, int minute, bool open) { PXR_EnterprisePlugin.UPxr_TimingStartup(year, month, day, hour, minute, open); } /// /// Schedules auto shutdown for the device. /// @note Supported by PICO Neo3 Pro (system version 4.8.0 or later) and PICO 4 Enterprise (system version 5.4.0 or later). /// /// Year, for example, `2022`. /// Month, for example, `2`. /// Day, for example, `22`. /// Hour, for example, `22`. /// Minute, for example, `22`. /// Whether to enable scheduled auto shutdown for the device: /// * `true`: enable /// * `false`: disable /// public static void TimingShutdown(int year, int month, int day, int hour, int minute, bool open) { PXR_EnterprisePlugin.UPxr_TimingShutdown(year, month, day, hour, minute, open); } /// /// Displays a specified settings screen. /// @note Supported by PICO Neo3 Pro (system version 4.8.0 or later) and PICO 4 Enterprise (system version OTA-5.2.8 or later). /// /// The enumerations of settings screen: /// * `START_VR_SETTINGS_ITEM_WIFI`: the Wi-Fi settings screen; /// * `START_VR_SETTINGS_ITEM_BLUETOOTH`: the bluetooth settings screen; /// * `START_VR_SETTINGS_ITEM_CONTROLLER`: the controller settings screen; /// * `START_VR_SETTINGS_ITEM_LAB`: the lab settings screen; /// * `START_VR_SETTINGS_ITEM_BRIGHTNESS`: the brightness settings screen; /// * `START_VR_SETTINGS_ITEM_GENERAL)`: the general settings screen; /// * `START_VR_SETTINGS_ITEM_NOTIFICATION`: the notification settings screen. /// /// Whether to display the selected settings screen: /// * `true`: display /// * `false`: hide /// /// Reserved parameter, pass `0`. public static void StartVrSettingsItem(StartVRSettingsEnum settingsEnum, bool hideOtherItem, int ext) { PXR_EnterprisePlugin.UPxr_StartVrSettingsItem(settingsEnum, hideOtherItem, ext); } /// /// Changes the Volume button's function to that of the Home and Enter button's, or restores the volume adjustment function to the Volume button. /// @note Supported by PICO 4 Enterprise with system version OTA-5.2.8 or later. /// /// Whether to change the Volume button's function: /// * `S_ON`: change /// * `S_OFF`: do not change /// /// Reserved parameter, pass `0`. public static void SwitchVolumeToHomeAndEnter(SwitchEnum switchEnum, int ext) { PXR_EnterprisePlugin.UPxr_SwitchVolumeToHomeAndEnter(switchEnum, ext); } /// /// Gets whether the Volume button's function has been changed to that of the Home and Enter button's. /// @note Supported by PICO 4 Enterprise with system version OTA-5.2.8 or later. /// /// /// * `S_ON`: changed /// * `S_OFF`: not changed /// public static SwitchEnum IsVolumeChangeToHomeAndEnter() { return PXR_EnterprisePlugin.UPxr_IsVolumeChangeToHomeAndEnter(); } /// /// Upgrades the OTA. /// @note Supported by PICO Neo3 Pro (system version 4.8.0 or later) and PICO 4 Enterprise (system version OTA0-5.2.8 or later). /// /// The location of the OTA package. /// /// * `0`: success /// * `1`: failure /// * `21`: OTA package version too low /// public static int InstallOTAPackage(String otaPackagePath) { return PXR_EnterprisePlugin.UPxr_InstallOTAPackage(otaPackagePath); } /// /// Gets the configuration of the Wi-Fi network that the device automatically connects to. /// /// The SSID and password of the Wi-Fi network. public static string GetAutoConnectWiFiConfig() { return PXR_EnterprisePlugin.UPxr_GetAutoConnectWiFiConfig(); } /// /// Gets the scheduled auto startup settings for the device. /// @note Supported by PICO Neo3 Pro (system version 4.8.0 or later) and PICO 4 Enterprise (system version OTA-5.2.8 or later). /// /// /// * `open`: the status of scheduled auto startup: /// * `true`: enabled /// * `false`: disabled /// * `time`: the time when the device auto starts up, for example, `1658980380000`. Returned when `open` is `true`. /// public static string GetTimingStartupStatus() { return PXR_EnterprisePlugin.UPxr_GetTimingStartupStatus(); } /// /// Gets the scheduled auto shutdown settings for the device. /// @note Supported by PICO Neo3 Pro (system version 4.8.0 or later) and PICO 4 Enterprise (system version OTA-5.2.8 or later). /// /// /// * `open`: the status of scheduled auto shutdown: /// * `true`: enabled /// * `false`: disabled /// * `time`: the time when the device auto shuts down, for example, `1658980380000`. Returned when `open` is `true`. /// public static string GetTimingShutdownStatus() { return PXR_EnterprisePlugin.UPxr_GetTimingShutdownStatus(); } /// /// Gets the status of a specified controller button. /// @note Supported by PICO Neo3 Pro (system version 4.8.0 or later) and PICO 4 Enterprise (system version OTA0-5.2.8 or later). /// /// The enumerations of controller button: /// * `CONTROLLER_KEY_JOYSTICK` /// * `CONTROLLER_KEY_MENU` /// * `CONTROLLER_KEY_TRIGGER` /// * `CONTROLLER_KEY_RIGHT_A` /// * `CONTROLLER_KEY_RIGHT_B` /// * `CONTROLLER_KEY_LEFT_X` /// * `CONTROLLER_KEY_LEFT_Y` /// * `CONTROLLER_KEY_LEFT_GRIP` /// * `CONTROLLER_KEY_RIGHT_GRIP` /// /// The button's status: /// * `0`: disabled /// * `1`: enabled /// public static int GetControllerKeyState(ControllerKeyEnum pxrControllerKey) { return PXR_EnterprisePlugin.UPxr_GetControllerKeyState(pxrControllerKey); } /// /// Enables or disables a specified controller button. /// @note Supported by PICO Neo3 Pro (system version 4.8.0 or later) and PICO 4 Enterprise (system version OTA-5.2.8 or later). /// /// The enumerations of controller button: /// * `CONTROLLER_KEY_JOYSTICK` /// * `CONTROLLER_KEY_MENU` /// * `CONTROLLER_KEY_TRIGGER` /// * `CONTROLLER_KEY_RIGHT_A` /// * `CONTROLLER_KEY_RIGHT_B` /// * `CONTROLLER_KEY_LEFT_X` /// * `CONTROLLER_KEY_LEFT_Y` /// * `CONTROLLER_KEY_LEFT_GRIP` /// * `CONTROLLER_KEY_RIGHT_GRIP` /// /// Whether to enable or disable the button: /// * `S_ON`: enable /// * `S_OFF`: disable /// /// /// `0` indicates success, other values indicate failure. /// public static int SetControllerKeyState(ControllerKeyEnum pxrControllerKey, SwitchEnum status) { return PXR_EnterprisePlugin.UPxr_SetControllerKeyState(pxrControllerKey, status); } /// /// Gets the status of the switch which is for powering off the USB cable when the device is shut down. /// /// The switch's status: /// * `S_ON`: on /// * `S_OFF`: off /// public static SwitchEnum GetPowerOffWithUSBCable() { return PXR_EnterprisePlugin.UPxr_ControlGetPowerOffWithUSBCable(); } /// /// Gets the screen timeout setting for the device. /// /// `PBS_ScreenOffDelayTimeEnum`: the enumerations of screen timeout. public static ScreenOffDelayTimeEnum GetScreenOffDelay() { return PXR_EnterprisePlugin.UPxr_PropertyGetScreenOffDelay(); } /// /// Gets the sleep timeout settings for the device. /// /// `PBS_SleepDelayTimeEnum`: the enumeration of sleep timeout. public static SleepDelayTimeEnum GetSleepDelay() { return PXR_EnterprisePlugin.UPxr_PropertyGetSleepDelay(); } /// /// Gets the current settings for the Power button. /// /// /// * `null`: not set /// * `singleTap`: whether a single-tap event has been set /// * `longTap`: whether a long-press event has been set /// * `longPressTime`: the time after which the long-press event takes place. Returned when `longTap` is `true`. /// public static string GetPowerKeyStatus() { return PXR_EnterprisePlugin.UPxr_PropertyGetPowerKeyStatus(); } /// /// Get the Enter button's status. /// /// /// * `0`: disabled /// * `1`: enabled /// public static int GetEnterKeyStatus() { return PXR_EnterprisePlugin.UPxr_GetEnterKeyStatus(); } /// /// Get the Volume button's status. /// /// /// * `0`: disabled /// * `1`: enabled /// public static int GetVolumeKeyStatus() { return PXR_EnterprisePlugin.UPxr_GetVolumeKeyStatus(); } /// /// Get the Back button's status. /// /// /// * `0`: disabled /// * `1`: enabled /// public static int GetBackKeyStatus() { return PXR_EnterprisePlugin.UPxr_GetBackKeyStatus(); } /// /// Gets the event settings for the Home button. /// /// The enumerations of event type: /// * `SINGLE_CLICK`: single-click event /// * `DOUBLE_CLICK`: double-click event /// * `LONG_PRESS`: long-press event /// /// /// * For `SINGLE_CLICK` and `DOUBLE_CLICK`, the event(s) you set will be returned. /// * For `LONG_PRESS`, the time and event you set will be returned. If you have not set a time for a long-press event, time will be `null`. /// /// * If you have not set any event for the event type you pass in the request, the response will return `null`. /// * For event enumerations, see `PropertySetHomeKey` or `PropertySetHomeKeyAll`. /// public static string GetHomeKeyStatus(HomeEventEnum homeEvent) { return PXR_EnterprisePlugin.UPxr_PropertyGetHomeKeyStatus(homeEvent); } /// /// Gets the status of a specified system function switch. /// /// The enumerations of system function switch: /// * `SFS_USB`: USB debugging /// * `SFS_AUTOSLEEP`: auto sleep /// * `SFS_SCREENON_CHARGING`: screen-on charging /// * `SFS_OTG_CHARGING`: OTG charging (supported by G2 devices) /// * `SFS_RETURN_MENU_IN_2DMODE`: display the Return icon on the 2D screen /// * `SFS_COMBINATION_KEY`: combination key /// * `SFS_CALIBRATION_WITH_POWER_ON`: calibration with power on /// * `SFS_SYSTEM_UPDATE`: system update (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_CAST_SERVICE`: phone casting service /// * `SFS_EYE_PROTECTION`: eye-protection mode /// * `SFS_SECURITY_ZONE_PERMANENTLY`: permanently disable the 6DoF play area (supported by PICO Neo2 devices) /// * `SFS_GLOBAL_CALIBRATION`: global calibration (supported by PICO G2 devices) /// * `SFS_Auto_Calibration`: auto calibration /// * `SFS_USB_BOOT`: USB plug-in boot /// * `SFS_VOLUME_UI`: global volume UI (need to restart the device to make the setting take effect) /// * `SFS_CONTROLLER_UI`: global controller connected UI /// * `SFS_NAVGATION_SWITCH`: navigation bar /// * `SFS_SHORTCUT_SHOW_RECORD_UI`: screen recording button UI /// * `SFS_SHORTCUT_SHOW_FIT_UI`: PICO fit UI /// * `SFS_SHORTCUT_SHOW_CAST_UI`: screencast button UI /// * `SFS_SHORTCUT_SHOW_CAPTURE_UI`: screenshot button UI /// * `SFS_USB_FORCE_HOST`: set the Neo3 Pro/Pro Eye device as the host device /// * `SFS_SET_DEFAULT_SAFETY_ZONE`: set a default play area for PICO Neo3 and PICO 4 series devices /// * `SFS_ALLOW_RESET_BOUNDARY`: allow to reset customized boundary for PICO Neo3 series devices /// * `SFS_BOUNDARY_CONFIRMATION_SCREEN`: whether to display the boundary confirmation screen for PICO Neo3 and PICO 4 series devices /// * `SFS_LONG_PRESS_HOME_TO_RECENTER`: long press the Home button to recenter for PICO Neo3 and PICO 4 series devices /// * `SFS_POWER_CTRL_WIFI_ENABLE`: stay connected to the network when the device sleeps/turns off (supported by PICO Neo3 Pro with system version 4.8.0 or later and PICO 4 Enterprise with system version OTA-5.2.8 or later) /// * `SFS_WIFI_DISABLE`: disable Wi-Fi (supported by PICO Neo3 Pro with system version 4.8.0 or later and PICO 4 Enterprise with system version OTA-5.2.8 or later) /// * `SFS_SIX_DOF_SWITCH`: 6DoF position tracking for PICO Neo3 and PICO 4 series devices /// * `SFS_INVERSE_DISPERSION`: anti-dispersion (supported by PICO Neo3 Pro with system version 4.8.0 or later and PICO 4 Enterprise with system version OTA0-5.2.8 or later) /// * `SFS_LOGCAT`: system log switch (/data/logs) (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_PSENSOR`: PSensor switch (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SYSTEM_UPDATE_OTA`: OTA upgrade (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SYSTEM_UPDATE_APP`: app upgrade and update (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SHORTCUT_SHOW_WLAN_UI`: quickly set whether to show the WLAN button (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SHORTCUT_SHOW_BOUNDARY_UI`: quickly set whether to show the boundary button (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SHORTCUT_SHOW_BLUETOOTH_UI`: quickly set whether to show the bluetooth button (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SHORTCUT_SHOW_CLEAN_TASK_UI`: quickly set whether to show the one-click clear button (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SHORTCUT_SHOW_IPD_ADJUSTMENT_UI`: quickly set whether to show the IPD adjustment button (supported by PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SHORTCUT_SHOW_POWER_UI`: quickly set whether to show the power button (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_SHORTCUT_SHOW_EDIT_UI`: quickly set whether to show the edit button (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_BASIC_SETTING_APP_LIBRARY_UI`: the button for customizing the app library (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_BASIC_SETTING_SHORTCUT_UI`: the button for customizing quick settings (supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later) /// * `SFS_LED_FLASHING_WHEN_SCREEN_OFF`: whether to keep the LED indicator light on when the device's screen is off and the battery is below 20% (supported by PICO G3 devices) /// * `SFS_BASIC_SETTING_CUSTOMIZE_SETTING_UI`: customize settings item to show or hide in basic settings /// * `SFS_BASIC_SETTING_SHOW_APP_QUIT_CONFIRM_DIALOG`: whether to show the app-quit dialog box when switching to a new app /// * `SFS_BASIC_SETTING_KILL_BACKGROUND_VR_APP`: whether to kill background VR apps (`1`: kill, and this is the default setting; `2`: do not kill) /// * `SFS_BASIC_SETTING_SHOW_CAST_NOTIFICATION`: whether to show a blue icon when casting the screen. The icon is displayed by default, and you can set the value to `0` to hide it. /// * `SFS_AUTOMATIC_IPD`: auto IPD switch (supported by PICO Neo3 series and PICO 4 Enterprise with system version 5.7.0 or later) /// * `SFS_QUICK_SEETHROUGH_MODE`: quick seethrough mode switch (supported by PICO Neo3 series and PICO 4 Enterprise with system version 5.7.0 or later) /// * `SFS_HIGN_REFERSH_MODE`: high refresh mode switch (supported by PICO Neo3 series and PICO 4 Enterprise with system version 5.7.0 or later) /// * `SFS_SEETHROUGH_APP_KEEP_RUNNING`: set whether to keep the app running under the seethrough mode (supported by PICO Neo3 series and PICO 4 Enterprise with system version 5.8.0 or later) /// * `SFS_OUTDOOR_TRACKING_ENHANCEMENT`: enhance outdoor position tracking (supported by PICO Neo3 series and PICO 4 Enterprise with system version 5.8.0 or later) /// * `SFS_AUTOIPD_AUTO_COMFIRM`: quick auto-IPD (supported by PICO 4 Enterprise with system version 5.8.0 or later) /// * `SFS_LAUNCH_AUTOIPD_IF_GLASSES_WEARED`: set whether to launch auto-IPD after wearing the headset (supported by PICO 4 Enterprise with system version 5.8.0 or later) /// * `SFS_GESTURE_RECOGNITION_HOME_ENABLE`: Home gesture switch (supported by PICO Neo3 series and PICO 4 Enterprise with system version 5.8.0 or later) /// * `SFS_GESTURE_RECOGNITION_RESET_ENABLE`: enable/disable the Reset gesture (supported by PICO Neo3 series and PICO 4 Enterprise with system version 5.8.0 or later) /// * `SFS_AUTO_COPY_FILES_FROM_USB_DEVICE`: automatically import OTG resources (supported by PICO Neo3 series and PICO 4 Enterprise with system version 5.8.0 or later) /// /// The callback that returns the switch's status: /// * `0`: off /// * `1`: on /// * `2`: not supported by device /// For `SFS_SYSTEM_UPDATE`, the returns are as follows: /// * `0`: off /// * `1`: OTA upgrade on /// * `2`: app upgrade on /// * `3`: OTA and app upgrade on /// public static void GetSwitchSystemFunctionStatus(SystemFunctionSwitchEnum systemFunction, Action callback) { PXR_EnterprisePlugin.UPxr_GetSwitchSystemFunctionStatus(systemFunction, callback); } /// /// Gets the configured USB mode. /// /// /// * `MTP`: MTP mode /// * `CHARGE`: charging mode /// public static string GetUsbConfigurationOption() { return PXR_EnterprisePlugin.UPxr_SwitchGetUsbConfigurationOption(); } /// /// Gets the current launcher. /// @note Supported by PICO Neo3 Pro (system version 4.8.0 or later) and PICO 4 Enterprise (system version OTA0-5.2.8 or later). /// /// The package name or class name of the launcher. public static string GetCurrentLauncher() { return PXR_EnterprisePlugin.UPxr_GetCurrentLauncher(); } /// /// Initializes the screencast service. /// @note Supported by PICO Neo3 Pro (system version 4.8.0 or later) and PICO 4 Enterprise (system version OTA0-5.2.8 or later). /// /// The callback: /// * `0`: disconnect /// * `1`: connect /// * `2`: no microphone permission /// /// /// * `0`: failure /// * `1`: success /// Returns `0` when there is no microphone permission. /// public static int PICOCastInit(Action callback) { return PXR_EnterprisePlugin.UPxr_PICOCastInit(callback); } /// /// Sets whether to show the screencast authorization window. /// @note Supported by PICO Neo3 Pro (system version 4.8.0 or later) and PICO 4 Enterprise (system version OTA0-5.2.8 or later). /// /// /// * `0`: ask every time (default) /// * `1`: always allow /// * `2`: not accepted /// /// /// * `0`: failure /// * `1`: success /// public static int PICOCastSetShowAuthorization(int authZ) { return PXR_EnterprisePlugin.UPxr_PICOCastSetShowAuthorization(authZ); } /// /// Gets the setting of whether to show the screencast authorization window. /// @note Supported by PICO Neo3 Pro (system version 4.8.0 or later) and PICO 4 Enterprise (system version OTA0-5.2.8 or later). /// /// /// * `0`: ask every time (default) /// * `1`: always allow /// * `2`: not accepted /// public static int PICOCastGetShowAuthorization() { return PXR_EnterprisePlugin.UPxr_PICOCastGetShowAuthorization(); } /// /// Gets the URL for screencast. /// @note Supported by PICO Neo3 Pro (system version 4.8.0 or later) and PICO 4 Enterprise (system version OTA0-5.2.8 or later). /// /// The enumerations of URL type: /// * `NormalURL`: Normal URL. The screencast authorization window will show if it is not set. /// * `NoConfirmURL`: Non-confirm URL. The screencast authorization window will not show in the browser. Screencast will start once you enter the URL. /// * `RtmpURL`: Returns the RTMP live streaming URL. The screencast authorization window will not appear on the VR headset's screen. /// /// The URL for screencast. public static string PICOCastGetUrl(PICOCastUrlTypeEnum urlType) { return PXR_EnterprisePlugin.UPxr_PICOCastGetUrl(urlType); } /// /// Stops screencast. /// @note Supported by PICO Neo3 Pro (system version 4.8.0 or later) and PICO 4 Enterprise (system version OTA0-5.2.8 or later). /// /// /// * `0`: failure /// * `1`: success /// public static int PICOCastStopCast() { return PXR_EnterprisePlugin.UPxr_PICOCastStopCast(); } /// /// sets screencast options. /// @note Supported by PICO Neo3 Pro (system version 4.8.0 or later) and PICO 4 Enterprise (system version OTA0-5.2.8 or later). /// /// The enumerations of the property to set: /// * `OPTION_RESOLUTION_LEVEL`: resolution level /// * `OPTION_BITRATE_LEVEL`: bitrate level /// * `OPTION_AUDIO_ENABLE`: whether to enable the audio /// /// The values that can be set for each property: /// * For `OPTION_RESOLUTION_LEVEL`: /// * `OPTION_VALUE_RESOLUTION_HIGH` /// * `OPTION_VALUE_RESOLUTION_MIDDLE` /// * `OPTION_VALUE_RESOLUTION_AUTO` /// * `OPTION_VALUE_RESOLUTION_HIGH_2K` /// * `OPTION_VALUE_RESOLUTION_HIGH_4K` /// * For `OPTION_BITRATE_LEVEL`: /// * `OPTION_VALUE_BITRATE_HIGH` /// * `OPTION_VALUE_BITRATE_MIDDLE` /// * `OPTION_VALUE_BITRATE_LOW` /// * For `OPTION_AUDIO_ENABLE`: /// * `OPTION_VALUE_AUDIO_ON` /// * `OPTION_VALUE_AUDIO_OFF` /// /// /// * `0`: failure /// * `1`: success /// public static int PICOCastSetOption(PICOCastOptionOrStatusEnum castOptionOrStatus, PICOCastOptionValueEnum castOptionValue) { return PXR_EnterprisePlugin.UPxr_PICOCastSetOption(castOptionOrStatus, castOptionValue); } /// /// Gets the screencast settings for the current device. /// @note Supported by PICO Neo3 Pro (system version 4.8.0 or later) and PICO 4 Enterprise (system version OTA0-5.2.8 or later). /// /// The enumerations of the screencast property to get setting for: /// * `OPTION_RESOLUTION_LEVEL`: resolution level /// * `OPTION_BITRATE_LEVEL`: bitrate level /// * `OPTION_AUDIO_ENABLE`: whether the audio is enabled /// * `PICOCAST_STATUS`: returns the current screencast status /// /// The setting of the selected property: /// * For `OPTION_RESOLUTION_LEVEL`: /// * `OPTION_VALUE_RESOLUTION_HIGH` /// * `OPTION_VALUE_RESOLUTION_MIDDLE` /// * `OPTION_VALUE_RESOLUTION_AUTO` /// * `OPTION_VALUE_RESOLUTION_HIGH_2K` /// * `OPTION_VALUE_RESOLUTION_HIGH_4K` /// * For `OPTION_BITRATE_LEVEL`: /// * `OPTION_VALUE_BITRATE_HIGH` /// * `OPTION_VALUE_BITRATE_MIDDLE` /// * `OPTION_VALUE_BITRATE_LOW` /// * For `OPTION_AUDIO_ENABLE`: /// * `OPTION_VALUE_AUDIO_ON` /// * `OPTION_VALUE_AUDIO_OFF` /// * `PICOCAST_STATUS` : /// * `STATUS_VALUE_STATE_STARTED` /// * `STATUS_VALUE_STATE_STOPPED` /// * `STATUS_VALUE_ERROR` /// public static PICOCastOptionValueEnum PICOCastGetOptionOrStatus(PICOCastOptionOrStatusEnum castOptionOrStatus) { return PXR_EnterprisePlugin.UPxr_PICOCastGetOptionOrStatus(castOptionOrStatus); } /// Sets the system language for the device. /// For a language that is spoken in different countries/regions, the system language is then co-set by the language code and the device's country/region code. /// For example, if the language code is set to `en` and the device's country/region code is `US`, the system language will be set to English (United States). /// @note Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later. /// /// Supported language codes: /// * `cs`: Czech /// * `da`: Danish /// * `de`: German /// * `el`: Greek /// * `en`: English (United States / United Kingdom) /// * `es`: Spanish /// * `fi`: Finnish /// * `fr`: French /// * `it`: Italian /// * `ja`: Japanese /// * `ko`: Korean /// * `ms`: Malay /// * `nb`: Norwegian /// * `nl`: Dutch /// * `pl`: Polish /// * `pt`: Portuguese (Brazil / Portugal) /// * `ro`: Romanian /// * `ru`: Russian /// * `sv`: Swedish /// * `th`: Thai /// * `tr`: Turkish /// * `zh`: Chinese (Simplified) / Chinese (Hong Kong SAR of China) / Chinese (Traditional) /// For devices in Mainland China / Taiwan, China / Hong Kong SAR of China / Macao SAR of China, the country/region code has been defined in factory settings. /// /// /// * `0`: success /// * `1`: failure /// * `22`: invalid language /// public static int SetSystemLanguage(String language) { return PXR_EnterprisePlugin.UPxr_SetSystemLanguage(language); } /// Gets the device's system language. /// @note Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later. /// /// The system language set for the device. For details, refer to the /// parameter description for `SetSystemLanguage`. public static String GetSystemLanguage() { return PXR_EnterprisePlugin.UPxr_GetSystemLanguage(); } /// Sets a default Wi-Fi network for the device. Once set, the device will automatically connect to the Wi-Fi network if accessible. /// @note Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later. /// /// The SSID (name) of the Wi-Fi network. /// The password of the Wi-Fi network. /// /// * `0`: success /// * `1`: failure /// public static int ConfigWifi(String ssid, String pwd) { return PXR_EnterprisePlugin.UPxr_ConfigWifi(ssid, pwd); } /// Gets the device's default Wi-Fi network. /// @note Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later. /// /// The SSID (name) of the Wi-Fi network. public static String[] GetConfiguredWifi() { return PXR_EnterprisePlugin.UPxr_GetConfiguredWifi(); } /// Sets a country/region for the device. /// @note Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later. /// /// The country/region code co-determines the device's system language with the language code you set via `SetSystemLanguage`. /// Below are supported country/region codes: /// * `AD`: Andorra /// * `AT`: Austria /// * `AU`: Australia /// * `BE`: Belgium /// * `BG`: Bulgaria /// * `CA`: Canada /// * `CH`: Switzerland /// * `CZ`: Czech Republic /// * `DE`: Germany /// * `DK`: Denmark /// * `EE`: Estonia /// * `ES`: Spain /// * `FI`: Finland /// * `FR`: France /// * `GB`: the Great Britain /// * `GR`: Greece /// * `HR`: Croatia /// * `HU`: Hungary /// * `IE`: Ireland /// * `IL`: Israel /// * `IS`: Iceland /// * `IT`: Italy /// * `JP`: Japan /// * `KR`: Korea /// * `LI`: Liechtenstein /// * `LT`: Lithuania /// * `LU`: Luxembourg /// * `LV`: Latvia /// * `MC`: Monaco /// * `MT`: Malta /// * `MY`: Malaysia /// * `NL`: Netherlands /// * `NO`: Norway /// * `NZ`: New Zealand /// * `PL`: Poland /// * `PT`: Portugal /// * `RO`: Romania /// * `SE`: Sweden /// * `SG`: Singapore /// * `SI`: Slovenia /// * `SK`: Slovakia /// * `SM`: San Marino /// * `TR`: Turkey /// * `US`: the United States /// * `VA`: Vatican /// /// Set the callback to get the result: /// * `0`: success /// * `1`: failure /// public static int SetSystemCountryCode(String countryCode, Action callback) { return PXR_EnterprisePlugin.UPxr_SetSystemCountryCode(countryCode, callback); } /// Gets the device's country/region code. /// @note Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later. /// /// A string value that indicates the device's current country/region code. /// For supported country/region codes, see the parameter description in `SetSystemCountryCode`. public static string GetSystemCountryCode() { return PXR_EnterprisePlugin.UPxr_GetSystemCountryCode(); } /// Sets the page to skip in initialization settings. /// @note Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later. /// /// Set the flag. /// The first 6 bits are valid, the 7th to 32rd bits are reserved. For each bit, `0` indicates showing and `1` indicates hiding. /// * `Constants#INIT_SETTING_HANDLE_CONNECTION_TEACHING`: the controller connection tutorial page /// * `Constants#INIT_SETTING_TRIGGER_KEY_TEACHING`: the Trigger button tutorial page /// * `Constants#INIT_SETTING_SELECT_LANGUAGE`: the language selection page /// * `Constants#INIT_SETTING_SELECT_COUNTRY`: the country/region selection page. Only available for devices in non-Mainland China countries/regions. /// * `Constants#INIT_SETTING_WIFI_SETTING`: the Wi-Fi settings page /// * `Constants#INIT_SETTING_QUICK_SETTING`: the quick settings page /// /// Below is an example implementation: /// ```csharp /// int flag = Constants.INIT_SETTING_HANDLE_CONNECTION_TEACHING | Constants.INIT_SETTING_TRIGGER_KEY_TEACHING; /// int result = serviceBinder.pbsSetSkipInitSettingPage(flag,0); /// ``` /// /// * `0`: success /// * `1`: failure /// public static int SetSkipInitSettingPage(int flag) { return PXR_EnterprisePlugin.UPxr_SetSkipInitSettingPage(flag); } /// Gets the page to skip in initialization settings. /// @note Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later. /// /// Returns the flag set in `SetSkipInitSettingPage`. public static int GetSkipInitSettingPage() { return PXR_EnterprisePlugin.UPxr_GetSkipInitSettingPage(); } /// Gets whether the initialization settings have been complete. /// @note Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later. /// /// /// * `0`: not complete /// * `1`: complete /// public static int IsInitSettingComplete() { return PXR_EnterprisePlugin.UPxr_IsInitSettingComplete(); } /// Starts an activity in another app. /// @note Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later. /// (Optional) The app's package name. /// (Optional) The app's class name. /// (Optional) The action to be performed. /// The basic types of standard fields that can be used as extra data. /// Standard categories that can be used to further clarify an Intent. Add a new category to the intent. /// Add additional flags to the intent. /// /// * `0`: success /// * `1`: failure /// public static int StartActivity(String packageName, String className, String action, String extra, String[] categories, int[] flags) { return PXR_EnterprisePlugin.UPxr_StartActivity(packageName, className, action, extra, categories, flags); } /// Shows/hides specified app(s) in the library. /// @note Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later. /// /// Package name(s). If there are multiple names, use commas (,) to separate them. /// Specifies to show/hide the app(s), enums: /// * `S_ON`: show /// * `S_OFF`: hide /// /// /// * `0`: success /// * `1`: failure /// public static int CustomizeAppLibrary(String[] packageNames, SwitchEnum switchEnum) { return PXR_EnterprisePlugin.UPxr_CustomizeAppLibrary(packageNames, switchEnum); } /// /// Gets the controller's battery level. /// @note Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later. /// /// Returns the following information: /// * array[0]: the left controller's battery level /// * array[1]: the right controller's battery level /// * an integer from 1 to 5, which indicates the battery level, the bigger the integer, the higher the battery level /// public static int[] GetControllerBattery() { return PXR_EnterprisePlugin.UPxr_GetControllerBattery(); } /// /// Gets the controller's connection status. /// @note Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later. /// /// /// * `0`: both controllers are disconnected /// * `1`: the left controller is connected /// * `2`: the right controller is connected /// * `3`: both controllers are connected /// public static int GetControllerConnectState() { return PXR_EnterprisePlugin.UPxr_GetControllerConnectState(); } /// /// Gets the apps that are hidden in the library. /// @note Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.4.0 or later. /// /// The packages names of hidden apps. Multiple names are separated by commas (,). public static string GetAppLibraryHideList() { return PXR_EnterprisePlugin.UPxr_GetAppLibraryHideList(); } /// /// Sets the device that outputs audio during screen casting. /// @note /// - Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.5.0 or later. /// - This API is only for miracast. /// /// Specifies the device that outputs audio. Enumerations: /// * `AUDIO_SINK`: the HMD /// * `AUDIO_TARGET`: the receiver /// * `AUDIO_SINK_TARGET`: both the HMD and the receiver /// /// /// * `0`: success /// * `1`: failure /// public static int SetScreenCastAudioOutput(ScreencastAudioOutputEnum screencastAudioOutput) { return PXR_EnterprisePlugin.UPxr_SetScreenCastAudioOutput(screencastAudioOutput); } /// /// Gets the device that outputs audio during screen casting. /// @note /// - Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.5.0 or later. /// - This API is only for miracast. /// /// /// Enumerations: /// * `AUDIO_SINK`: the HMD /// * `AUDIO_TARGET`: the receiver /// * `AUDIO_SINK_TARGET`: both the HMD and the receiver /// public static ScreencastAudioOutputEnum GetScreenCastAudioOutput() { return PXR_EnterprisePlugin.UPxr_GetScreenCastAudioOutput(); } /// /// Displays or hides the specified tab or option on the Settings pane. /// @note Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.5.0 or later. /// /// Specifies the tab or option to display or hide. Enumerations: /// * `CUSTOMIZE_SETTINGS_TAB_WLAN`: the "WLAN" tab /// * `CUSTOMIZE_SETTINGS_TAB_CONTROLLER`: the "Controller" tab /// * `CUSTOMIZE_SETTINGS_TAB_BLUETOOTH`: the "Bluetooth" tab /// * `CUSTOMIZE_SETTINGS_TAB_DISPLAY`: the "Display" tab /// * `CUSTOMIZE_SETTINGS_TAB_LAB`: the "LAB" tab /// * `CUSTOMIZE_SETTINGS_TAB_GENERAL_FACTORY_RESET`: the "Factory Reset" option on the "General" tab /// * `CUSTOMIZE_SETTINGS_TAB_GENERAL_LOCKSCREEN`: the "Lock Screen" option on the "General" tab /// /// Sets to display or hide the specified tab or option: /// * `S_ON`: display /// * `S_OFF`: hide /// /// /// * `0`: success /// * `1`: failure /// public static int UPxr_CustomizeSettingsTabStatus(CustomizeSettingsTabEnum customizeSettingsTabEnum, SwitchEnum switchEnum) { return PXR_EnterprisePlugin.UPxr_CustomizeSettingsTabStatus(customizeSettingsTabEnum, switchEnum); } /// /// Gets the status set for the specified tab or option on the Settings pane. /// @note Supported by PICO Neo3 Pro and PICO 4 Enterprise with system version 5.5.0 or later. /// /// Specifies the tab or option to get status for. Enumerations: /// * `CUSTOMIZE_SETTINGS_TAB_WLAN`: the "WLAN" tab /// * `CUSTOMIZE_SETTINGS_TAB_CONTROLLER`: the "Controller" tab /// * `CUSTOMIZE_SETTINGS_TAB_BLUETOOTH`: the "Bluetooth" tab /// * `CUSTOMIZE_SETTINGS_TAB_DISPLAY`: the "Display" tab /// * `CUSTOMIZE_SETTINGS_TAB_LAB`: the "LAB" tab /// * `CUSTOMIZE_SETTINGS_TAB_GENERAL_FACTORY_RESET`: the "Factory Reset" option on the "General" tab /// * `CUSTOMIZE_SETTINGS_TAB_GENERAL_LOCKSCREEN`: the "Lock Screen" option on the "General" tab /// /// /// The status of the specified tab or option: /// * `S_ON`: displayed /// * `S_OFF`: hidden /// public static SwitchEnum UPxr_GetCustomizeSettingsTabStatus(CustomizeSettingsTabEnum customizeSettingsTabEnum) { return PXR_EnterprisePlugin.UPxr_GetCustomizeSettingsTabStatus(customizeSettingsTabEnum); } /// /// Shuts down the PICO device when the USB plug is unplugged or the plug runs out of power. /// /// Determines whether to enable/disable this function: /// * `S_ON`: enable /// * `S_OFF`: disable /// public static void SetPowerOffWithUSBCable(SwitchEnum switchEnum) { PXR_EnterprisePlugin.UPxr_SetPowerOffWithUSBCable(switchEnum); } /// /// Removes a specific Home key event setting, which restores the event to its default setting. /// /// Specify a Home key event from the following: /// `PBS_HomeEventEnum. SINGLE_CLICK`: single-click event /// `PBS_HomeEventEnum. DOUBLE_CLICK`: double-click event /// `PBS_HomeEventEnum. LONG_PRESS`: long press event /// `PBS_HomeEventEnum. SINGLE_CLICK_RIGHT_CTL`: single-click on the right controller's Home button /// `PBS_HomeEventEnum. DOUBLE_CLICK_RIGHT_CTL`: double-click on the right controller's Home button /// `PBS_HomeEventEnum. LONG_PRESS_RIGHT_CTL`: long press on the right controller's Home button /// `PBS_HomeEventEnum. SINGLE_CLICK_LEFT_CTL`: single-click on the left controller's Home button /// `PBS_HomeEventEnum. DOUBLE_CLICK_LEFT_CTL`: double-click on the left controller's Home button /// `PBS_HomeEventEnum. LONG_PRESS_LEFT_CTL`: long press on the left controller's Home button /// `PBS_HomeEventEnum. SINGLE_CLICK_HMD`: single-click on the HMD's Home button /// `PBS_HomeEventEnum. DOUBLE_CLICK_HMD`: double-click on the HMD's Home button /// `PBS_HomeEventEnum. LONG_PRESS_HMD`: long press on the HMD's Home button /// public static void RemoveControllerHomeKey(HomeEventEnum EventEnum) { PXR_EnterprisePlugin.UPxr_RemoveControllerHomeKey(EventEnum); } /// /// Sets the power on logo or the power on/off animation. /// /// Specify a setting from the following: /// * `PBS_PowerOnOffLogoEnum. PLPowerOnLogo`: sets a logo for the first frame after powering on the device /// * `PBS_PowerOnOffLogoEnum. PLPowerOnAnimation`: sets the power on animation /// * `PBS_PowerOnOffLogoEnum. PLPowerOffAnimation`: sets the power off animation /// /// /// * For setting a logo for the first frame after powering on the device, pass the path where the .img file is stored, for example, `/sdcard/bootlogo.img`. /// * For setting the power on/off animation, pass the folder where the pictures composing the animation is stored. /// /// Result callback: /// * `true`: success /// * `false`: failure /// public static void SetPowerOnOffLogo(PowerOnOffLogoEnum powerOnOffLogoEnum, String path, Action callback) { PXR_EnterprisePlugin.UPxr_SetPowerOnOffLogo(powerOnOffLogoEnum,path,callback); } /// /// Sets an interpupillary distance (IPD). /// @note Supported by PICO 4 Enterprise with system version 5.7.0 or later. /// /// /// The IPD to set. Valid value range: [62,72]. Unit: millimeters. /// /// Result callback: /// * `0`: success /// * `1`: failure /// * `23`: the `ipd` value is out of the valid range /// public static void SetIPD(float ipd, Action callback) { PXR_EnterprisePlugin.UPxr_SetIPD(ipd,callback); } /// /// Gets the device configured for miracast. /// /// /// The name of the device. /// public static string GetAutoMiracastConfig() { return PXR_EnterprisePlugin.UPxr_GetAutoMiracastConfig(); } /// /// Sets screencast-related parameters. /// @note Supported by PICO Neo3 series and PICO 4 Enterprise with system version 5.7.0 or later. /// /// /// The mediaFormat object to set. Currently, only support settings the bitrate. /// /// /// * `0`: success /// * `1`: failure /// public static int SetPicoCastMediaFormat(PicoCastMediaFormat mediaFormat) { return PXR_EnterprisePlugin.UPxr_SetPicoCastMediaFormat(mediaFormat); } /// /// Gets the pose and ID of the marker. /// @note Supported by 6Dof devices. /// /// Specify a tracking origin mode from the following: /// * `TrackingOriginModeFlags.Device`: Device mode. The system sets the device's initial position as the origin. The device's height from the floor is not calculated. /// * `TrackingOriginModeFlags.Floor`: Floor mode. The system sets an origin based on the device's original position and the device's height from the floor. /// @note The PICO Unity OpenXR SDK only supports the `TrackingOriginModeFlags.Device` mode. /// /// /// Set the offset added to the camera's Y direction, which is for simulating a user's height and is only applicable if you select the 'Device' mode. /// /// /// The callback function for returning marker information. /// /// /// * `0`: success /// * `1`: failure /// public static int SetMarkerInfoCallback(TrackingOriginModeFlags trackingMode,float cameraYOffset,Action> markerInfos) { return PXR_EnterprisePlugin.UPxr_setMarkerInfoCallback(trackingMode,cameraYOffset,markerInfos); } /// /// Open RGB camera. /// @note The PICO Unity OpenXR SDK does not support this API. /// /// Whether the RGB camera has been opened: /// * `true`: success /// * `false`: failure /// public static bool OpenVSTCamera() { return PXR_EnterprisePlugin.UPxr_OpenVSTCamera(); } /// /// Close RGB camera. /// @note The PICO Unity OpenXR SDK does not support this API. /// /// Whether the RGB camera has been closed: /// * `true`: success /// * `false`: failure /// public static bool CloseVSTCamera() { return PXR_EnterprisePlugin.UPxr_CloseVSTCamera(); } /// /// Get camera parameters(including intrinsics & extrinsics). /// @note The PICO Unity OpenXR SDK does not support this API. /// /// RGBCameraParams including intrinsics and extrinsics. /// public static RGBCameraParams GetCameraParameters() { return PXR_EnterprisePlugin.UPxr_GetCameraParameters(); } /// /// Get current head tracking confidence. /// @note The PICO Unity OpenXR SDK does not support this API. /// /// /// * `0`: bad /// * `1`: good /// public static int GetHeadTrackingConfidence() { return PXR_EnterprisePlugin.UPxr_GetHeadTrackingConfidence(); } /// /// Acquire RGB camera frame,distortion /// @note The PICO Unity OpenXR SDK does not support this API. /// /// [out]frame frame info /// /// * `0`: success /// * other: failure /// public static int AcquireVSTCameraFrame(out Frame frame) { return PXR_EnterprisePlugin.UPxr_AcquireVSTCameraFrame(out frame); } /// /// Acquire RGB camera frame,anti-distortion /// @note The PICO Unity OpenXR SDK does not support this API. /// /// [in]width desired frame width,should be less equal than 2328 /// [in]height desired frame height, should be less equal than 1748 /// [out]frame frame info /// /// * `0`: success /// * other: failure /// public static int AcquireVSTCameraFrameAntiDistortion(int width, int height, out Frame frame) { return PXR_EnterprisePlugin.UPxr_AcquireVSTCameraFrameAntiDistortion(width, height, out frame); } /// /// Gets the predicted display time. /// @note The PICO Unity OpenXR SDK does not support this API. /// The predicted display time. public static double GetPredictedDisplayTime() { return PXR_EnterprisePlugin.UPxr_GetPredictedDisplayTime(); } /// /// Gets the predicted status of the sensor. /// @note The PICO Unity OpenXR SDK does not support this API. /// /// predict time. /// The predicted status of the sensor. public static SensorState GetPredictedMainSensorState(double predictTime) { return PXR_EnterprisePlugin.UPxr_GetPredictedMainSensorState(predictTime); } /// /// Directs the user to the floor-height-adjustment app to adjust the floor's height. /// @note Supported by PICO Neo3 Pro, general PICO Neo3 devices activated as enterprise devices, and PICO 4 Enterprise. /// /// /// * `0`: success /// * `1`: failure /// public static int GotoSeeThroughFloorSetting() { return PXR_EnterprisePlugin.UPxr_gotoSeeThroughFloorSetting(); } /// /// Copies a file or a folder from the source path to the destination path. /// @note Supported by PICO Neo3 Pro, general PICO Neo3 devices activated as enterprise devices, and PICO 4 Enterprise. /// /// /// The source path of the file or folder. /// * For mobile storage devices, the prefix of the path is 'udisk://'. For example, the path of the Movie folder under the root directory should be passed as 'udisk://Movie'. /// * For internal storage paths, directly specify the path under the root directory. For example, the path of the Picture folder under the root directory should be passed as 'Picture'. /// /// /// The destination path that the file or folder is copied to. /// * For mobile storage devices, the prefix of the path is 'udisk://'. For example, the path of the Movie folder under the root directory should be passed as 'udisk://Movie'. /// * For internal storage paths, directly write the path under the root directory. For example, the path of the Picture folder under the root directory should be passed as 'Picture'. /// /// The result callback: /// * `onCopyStart`: copy start callback /// * `onCopyProgress(double process)`: copy progress callback, value range:[0.00, 1.00] /// * `onCopyFinish(int errorCode)`: `0` (copy succeeded); `101` (USB flash disk is not connected); `103` (insufficient storage space in the target device); `104` (copy failed) /// /// /// * `0`: API call succeeded, wait for copy to start /// * `101`: USB flash drive is not connected /// * `102`: source file/folder does not exist /// * `106`: null parameter /// public static int FileCopy(String srcPath, String dstPath, FileCopyCallback callback) { return PXR_EnterprisePlugin.UPxr_fileCopy(srcPath, dstPath, callback); } /// /// Checks whether a map is being used. /// @note Supported by PICO Neo3 Pro, general PICO Neo3 devices activated as enterprise devices, and PICO 4 Enterprise. /// /// The path of the map's zip file. /// The result callback: /// * `0`: success /// * `1`: failure /// * `101`: file does not exist /// * `102`: failed to unzip the file /// * `103`: file corruption /// * `104`: position tracking is disabled /// * `106`: failed to get the current map's information /// * `107`: `path` parameter is null /// public static void IsMapInEffect(String path, Action callback) { PXR_EnterprisePlugin.UPxr_IsMapInEffect(path, callback); } /// /// Imports a map. /// @note Supported by PICO Neo3 Pro, general PICO Neo3 devices activated as enterprise devices, and PICO 4 Enterprise. /// /// The path of the map's zip file. /// The result callback: /// * `0`: success /// * `1`: failure /// * `101`: file does not exist /// * `102`: failed to unzip the file /// * `103`: file corruption /// * `104`: position tracking is disabled /// * `107`: `path` parameter is null /// public static void ImportMapByPath(String path, Action callback) { PXR_EnterprisePlugin.UPxr_ImportMapByPath(path, callback); } } }