This commit is contained in:
2025-11-13 17:40:28 +08:00
parent 962ab49609
commit 10156da245
5503 changed files with 805282 additions and 0 deletions

View File

@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 865e330f2b0cd4141ab4a4153d535675
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,18 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum ControllerKeyEnum
{
CONTROLLER_KEY_JOYSTICK=0,
CONTROLLER_KEY_MENU=1,
CONTROLLER_KEY_TRIGGER=2,
CONTROLLER_KEY_RIGHT_A=3,
CONTROLLER_KEY_RIGHT_B=4,
CONTROLLER_KEY_LEFT_X=5,
CONTROLLER_KEY_LEFT_Y=6,
CONTROLLER_KEY_LEFT_GRIP=7,
CONTROLLER_KEY_RIGHT_GRIP=8,
CONTROLLER_KEY_VOLUME_DOWN=9,
CONTROLLER_KEY_VOLUME_UP=10,
CONTROLLER_KEY_CLICK=11
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 71820ab70affcbd4faa8707df25e1725
timeCreated: 1685945465

View File

@@ -0,0 +1,12 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum ControllerPairTimeEnum
{
DEFAULT=0,
FIFTEEN=15,
SIXTY=60,
ONE_HUNDRED_AND_TWENTY=120,
SIX_HUNDRED=600,
NEVER=-1
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 88ffdfff23fd922469ae84af0a209731
timeCreated: 1685943806

View File

@@ -0,0 +1,90 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum CustomizeSettingsTabEnum
{
/// <summary>
/// Hide the WIFI tag. Applicable to MerlinE, NEO3, PICO4, and Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_WLAN = 0,
/// <summary>
/// Hide the controller tag. Applicable to MerlinE, NEO3, and PICO4 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_CONTROLLER = 1,
/// <summary>
/// Hide the Bluetooth tag. Applicable to MerlinE, NEO3, PICO4, and Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_BLUETOOTH = 2,
/// <summary>
/// Hide the display tag. Applicable to MerlinE, NEO3, and PICO4 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_DISPLAY = 3,
/// <summary>
/// Hide the lab tag. Applicable to MerlinE, NEO3, and PICO4 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_LAB = 4,
/// <summary>
/// Hide the lock screen entry. Applicable to MerlinE, NEO3, PICO4, and Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_GENERAL_LOCKSCREEN = 5,
/// <summary>
/// Hide the factory reset entry. Applicable to MerlinE, NEO3, PICO4, and Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_GENERAL_FACTORY_RESET = 6,
/// <summary>
/// Account settings. Applicable to Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_ACCOUNTS = 7,
/// <summary>
/// System upgrade settings. Applicable to Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_SYSTEM_UPDATE = 8,
/// <summary>
/// Interaction settings. Applicable to Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_INTERACTION = 9,
/// <summary>
/// Pupil distance settings. Applicable to Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_PUPIL_DISTANCE = 10,
/// <summary>
/// Camera and see-through settings. Applicable to Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_CAMERA_SEETHROUGH = 11,
/// <summary>
/// Virtual environment settings. Applicable to Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_VIRTUAL_ENVIRONMENT = 12,
/// <summary>
/// Safety guard settings. Applicable to Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_SAFEGUARD = 13,
/// <summary>
/// Room capture settings. Applicable to Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_ROOM_CAPTURE = 14,
/// <summary>
/// Performance settings. Applicable to Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_PERFORMANCE = 15,
/// <summary>
/// Control center settings. Applicable to Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_CONTROL_CENTRE = 16,
/// <summary>
/// Notification settings. Applicable to Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_NOTIFICATIONS = 17,
/// <summary>
/// App management settings. Applicable to Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_APP_MANAGEMENT = 18,
/// <summary>
/// About device settings. Applicable to Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_ABOUT = 19,
/// <summary>
/// Help and feedback settings. Applicable to Sparrow_PUI5130 devices.
/// </summary>
CUSTOMIZE_SETTINGS_TAB_HELP_FEEDBACK = 20
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: f2714615e3a23d9449fdf19cdf584b48
timeCreated: 1685945379

View File

@@ -0,0 +1,8 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum DeviceControlEnum
{
DEVICE_CONTROL_REBOOT=0,
DEVICE_CONTROL_SHUTDOWN=1
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 9cfd7333ed47ab44a874e4fe98c1c08d
timeCreated: 1685937183

View File

@@ -0,0 +1,18 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum HomeEventEnum
{
SINGLE_CLICK=0,
DOUBLE_CLICK=1,
LONG_PRESS=2,
SINGLE_CLICK_RIGHT_CTL=3,
DOUBLE_CLICK_RIGHT_CTL=4,
LONG_PRESS_RIGHT_CTL=5,
SINGLE_CLICK_LEFT_CTL=6,
DOUBLE_CLICK_LEFT_CTL=7,
LONG_PRESS_LEFT_CTL=8,
SINGLE_CLICK_HMD=9,
DOUBLE_CLICK_HMD=10,
LONG_PRESS_HMD=11
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 599cdfc907c46d6488436b1622eafd50
timeCreated: 1685937306

View File

@@ -0,0 +1,17 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum HomeFunctionEnum
{
VALUE_HOME_GO_TO_SETTING=0,
VALUE_HOME_BACK=1,
VALUE_HOME_RECENTER=2,
VALUE_HOME_OPEN_APP=3,
VALUE_HOME_DISABLE=4,
VALUE_HOME_GO_TO_HOME=5,
VALUE_HOME_SEND_BROADCAST=6,
VALUE_HOME_CLEAN_MEMORY=7,
VALUE_HOME_QUICK_SETTING=8,
VALUE_HOME_SCREEN_CAP=9,
VALUE_HOME_SCREEN_RECORD=10
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 6effac1077bec9348aaf4f68c8787e7f
timeCreated: 1685937603

View File

@@ -0,0 +1,17 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum OnLineSystemUpdateStatusCode
{
IDLE = 0,
CHECKING_FOR_UPDATE = 1,
UPDATE_AVAILABLE = 2,
DOWNLOADING = 3,
DOWNLOAD_FINISH = 4,
UPGRADE_EXTRACTING = 5,
UPGRADE_VERIFYING = 6,
UPGRADE_WAITING_REBOOT = 7,
UPGRADE_FINISH = 8,
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 79034eaebec042aa9293074a76344d1a
timeCreated: 1721371631

View File

@@ -0,0 +1,13 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum OnlineSystemUpdateErrorCode
{
SUCCESS = 0,
ERROR = -1,
UPDATE_NOT_AVAILABLE = -3,
CHECK_UPDATE_ERROR = -4,
DOWNLOAD_ERROR = -5,
DOWNLOAD_VERIFY_ERROR = -6,
UPGRADE_ERROR = -7
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 31d0774851654ff7becb2ee354dfad40
timeCreated: 1721371579

View File

@@ -0,0 +1,10 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum PICOCastOptionOrStatusEnum
{
OPTION_RESOLUTION_LEVEL=0,
OPTION_BITRATE_LEVEL=1,
OPTION_AUDIO_ENABLE=2,
PICO_CAST_STATUS=3
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: aab97c5d20f1fe940beb18a3fe308e46
timeCreated: 1685945051

View File

@@ -0,0 +1,22 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum PICOCastOptionValueEnum
{
OPTION_VALUE_RESOLUTION_HIGH,
OPTION_VALUE_RESOLUTION_MIDDLE,
OPTION_VALUE_RESOLUTION_AUTO,
OPTION_VALUE_RESOLUTION_HIGH_2K,
OPTION_VALUE_RESOLUTION_HIGH_4K,
OPTION_VALUE_BITRATE_HIGH,
OPTION_VALUE_BITRATE_MIDDLE,
OPTION_VALUE_BITRATE_LOW,
OPTION_VALUE_AUDIO_ON,
OPTION_VALUE_AUDIO_OFF,
STATUS_VALUE_STATE_STARTED,
STATUS_VALUE_STATE_STOPPED,
STATUS_VALUE_ERROR
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 1de348b2dfe662e4b9053c101bbda4fa
timeCreated: 1685945106

View File

@@ -0,0 +1,9 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum PICOCastUrlTypeEnum
{
NORMAL_URL=0,
NO_CONFIRM_URL=1,
RTMP_URL=2
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 1d04bb6dfca248143bdd812fb00ea7b2
timeCreated: 1685944504

View File

@@ -0,0 +1,8 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum PackageControlEnum
{
PACKAGE_SILENCE_INSTALL=0,
PACKAGE_SILENCE_UNINSTALL=1
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: f9508b93fb3d76f49ae71ad9e3d679f9
timeCreated: 1685937232

View File

@@ -0,0 +1,7 @@
namespace Unity.XR.PICO.TOBSupport
{
public class PicoCastMediaFormat
{
public int bitrate = -1;//kb
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 8eca65ab8e7e4984a8415528a35a2f3d
timeCreated: 1686223794

View File

@@ -0,0 +1,20 @@
using System;
using System.Runtime.InteropServices;
namespace Unity.XR.PICO.TOBSupport
{
public enum PoseErrorType
{
BRIGHT_LIGHT_ERROR = (1 << 0),
LOW_LIGHT_ERROR = (1 << 1),
LOW_FEATURE_COUNT_ERROR = (1 << 2),
CAMERA_CALIBRATION_ERROR = (1 << 3),
RELOCATION_IN_PROGRESS = (1 << 4),
INITILIZATION_IN_PROGRESS = (1 << 5),
NO_CAMERA_ERROR = (1 << 6),
NO_IMU_ERROR = (1 << 7),
IMU_JITTER_ERROR = (1 << 8),
UNKNOWN_ERROR = (1 << 9)
};
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 46bdaa338aeb42e4c813168706e540f3
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,9 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum PowerOnOffLogoEnum
{
PLPowerOnLogo=0,
PLPowerOnAnimation=1,
PLPowerOffAnimation=2
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: f7e0adfb5b4e8e342ad0fa15263e54ca
timeCreated: 1685945676

View File

@@ -0,0 +1,13 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum ScreenOffDelayTimeEnum
{
THREE,
TEN ,
THIRTY ,
SIXTY,
THREE_HUNDRED,
SIX_HUNDRED ,
NEVER
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 22e9ab23329ae354097af770cf179472
timeCreated: 1685943725

View File

@@ -0,0 +1,10 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum ScreencastAudioOutputEnum
{
AUDIO_ERROR=0,
AUDIO_SINK = 1,
AUDIO_TARGET = 2,
AUDIO_SINK_TARGET = 3,
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: d484897b4d6e06b4281b6e25e222c723
timeCreated: 1685945230

View File

@@ -0,0 +1,13 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum SleepDelayTimeEnum
{
FIFTEEN ,
THIRTY ,
SIXTY ,
THREE_HUNDRED ,
SIX_HUNDRED ,
ONE_THOUSAND_AND_EIGHT_HUNDRED ,
NEVER
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: ca0a63d4310322847a9569df3fb34d4a
timeCreated: 1685943762

View File

@@ -0,0 +1,13 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum StartVRSettingsEnum
{
START_VR_SETTINGS_ITEM_WIFI=0,
START_VR_SETTINGS_ITEM_BLUETOOTH=1,
START_VR_SETTINGS_ITEM_CONTROLLER=2,
START_VR_SETTINGS_ITEM_LAB=3,
START_VR_SETTINGS_ITEM_BRIGHTNESS=4,
START_VR_SETTINGS_ITEM_GENERAL=5,
START_VR_SETTINGS_ITEM_NOTIFICATION=6
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 47b4eb0018f80d5428bed27d2e7f69bf
timeCreated: 1685944404

View File

@@ -0,0 +1,8 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum SwitchEnum
{
S_ON=0,
S_OFF=1
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: ef3b88f2e4c726543b34bbb0f0aca35f
timeCreated: 1685937261

View File

@@ -0,0 +1,543 @@
using System;
namespace Unity.XR.PICO.TOBSupport
{
public enum SystemFunctionSwitchEnum
{
/// <summary>
/// USB debugging switch.
/// </summary>
SFS_USB = 0,
/// <summary>
/// Automatic sleep switch.
/// </summary>
SFS_AUTOSLEEP = 1,
/// <summary>
/// Screen-on charging switch.
/// </summary>
[Obsolete]
SFS_SCREENON_CHARGING = 2,
/// <summary>
/// OTG charging switch (only available on G2 series).
/// </summary>
SFS_OTG_CHARGING = 3,
/// <summary>
/// Switch for displaying the return icon in 2D mode (only available on G2 series).
/// </summary>
SFS_RETURN_MENU_IN_2DMODE = 4,
/// <summary>
/// Combination key switch.
/// </summary>
SFS_COMBINATION_KEY = 5,
/// <summary>
/// Power-on calibration switch (only available on G2 series).
/// </summary>
SFS_CALIBRATION_WITH_POWER_ON = 6,
/// <summary>
/// System upgrade and update switch.
/// </summary>
SFS_SYSTEM_UPDATE = 7,
/// <summary>
/// Mobile screen mirroring switch, only supports PUI4.X.
/// </summary>
SFS_CAST_SERVICE = 8,
/// <summary>
/// Eye protection mode switch.
/// </summary>
SFS_EYE_PROTECTION = 9,
/// <summary>
/// Permanent disable switch for 6Dof safety zone.
/// </summary>
SFS_SECURITY_ZONE_PERMANENTLY = 10,
/// <summary>
/// Global calibration switch (only supported in 3dof mode).
/// </summary>
SFS_GLOBAL_CALIBRATION = 11,
/// <summary>
/// Automatic calibration (Obsolete).
/// </summary>
[Obsolete] SFS_Auto_Calibration = 12,
/// <summary>
/// USB boot switch.
/// </summary>
SFS_USB_BOOT = 13,
/// <summary>
/// Global UI prompt switch for volume adjustment.
/// </summary>
SFS_VOLUME_UI = 14,
/// <summary>
/// Global UI prompt switch for controller connection.
/// </summary>
SFS_CONTROLLER_UI = 15,
/// <summary>
/// Interface for turning on/off the navigation bar.
/// </summary>
SFS_NAVGATION_SWITCH = 16,
/// <summary>
/// Switch for displaying the screen recording button.
/// </summary>
SFS_SHORTCUT_SHOW_RECORD_UI = 17,
/// <summary>
/// Switch for turning on/off the fitness UI, supported on Neo3 Pro PUI4.x.
/// </summary>
SFS_SHORTCUT_SHOW_FIT_UI = 18,
/// <summary>
/// Switch for displaying the screen mirroring button.
/// </summary>
SFS_SHORTCUT_SHOW_CAST_UI = 19,
/// <summary>
/// Switch for displaying the screen capture button.
/// </summary>
SFS_SHORTCUT_SHOW_CAPTURE_UI = 20,
/// <summary>
/// Switch for killing 2D apps in the background (Obsolete).
/// </summary>
[Obsolete] SFS_STOP_MEM_INFO_SERVICE = 21,
/// <summary>
/// Switch for restricting app auto-startup (Obsolete).
/// </summary>
[Obsolete] SFS_START_APP_BOOT_COMPLETED = 22,
/// <summary>
/// Set the device as a host device.
/// </summary>
SFS_USB_FORCE_HOST = 23,
/// <summary>
/// Set the default safety zone for Neo3 and PICO4 series devices.
/// </summary>
SFS_SET_DEFAULT_SAFETY_ZONE = 24,
/// <summary>
/// Allow resetting the boundary for Neo3 and PICO4 series devices.
/// </summary>
SFS_ALLOW_RESET_BOUNDARY = 25,
/// <summary>
/// Switch for displaying the confirmation screen for the safety boundary on Neo3 and PICO4 series devices.
/// </summary>
SFS_BOUNDARY_CONFIRMATION_SCREEN = 26,
/// <summary>
/// Recenter by long-pressing the Home key on Neo3 and PICO4 series devices.
/// </summary>
SFS_LONG_PRESS_HOME_TO_RECENTER = 27,
/// <summary>
/// Keep the device connected to the network after the screen is off. Supported on PICO4 E [PUI5.4.0 and above], PICO G3 [PUI5.4.0 and above], and Neo3 Pro [PUI4.8.0 & 4.8.1 and above].
/// </summary>
SFS_POWER_CTRL_WIFI_ENABLE = 28,
/// <summary>
/// Disable Wi-Fi. Supported on PICO4 E [PUI5.4.0 and above], PICO G3 [PUI5.4.0 and above], and Neo3 Pro [PUI4.8.0 & 4.8.1 and above].
/// </summary>
SFS_WIFI_DISABLE = 29,
/// <summary>
/// 6Dof switch for Neo3 and PICO4 series devices.
/// </summary>
SFS_SIX_DOF_SWITCH = 30,
/// <summary>
/// Inverse dispersion switch, available on PICO Neo3 and G3.
/// </summary>
SFS_INVERSE_DISPERSION = 31,
/// <summary>
/// Switch for logcat, path: data/logs.
/// </summary>
SFS_LOGCAT = 32,
/// <summary>
/// Switch for the proximity sensor.
/// </summary>
SFS_PSENSOR = 33,
/// <summary>
/// OTA upgrade switch, available on [PUI5.4.0 and above].
/// </summary>
SFS_SYSTEM_UPDATE_OTA = 34,
/// <summary>
/// App upgrade and update switch, available on [PUI5.4.0 and above].
/// </summary>
SFS_SYSTEM_UPDATE_APP = 35,
/// <summary>
/// Switch for displaying the WLAN button in the quick settings, available on [PUI5.4.0 and above].
/// </summary>
SFS_SHORTCUT_SHOW_WLAN_UI = 36,
/// <summary>
/// Switch for displaying the safety boundary button in the quick settings, available on PICO4E & Neo3Pro [PUI5.4.0].
/// </summary>
SFS_SHORTCUT_SHOW_BOUNDARY_UI = 37,
/// <summary>
/// Switch for displaying the Bluetooth button in the quick settings, available on [PUI5.4.0 and above].
/// </summary>
SFS_SHORTCUT_SHOW_BLUETOOTH_UI = 38,
/// <summary>
/// Switch for displaying the one-click cleanup button in the quick settings, available on [PUI5.4.0].
/// </summary>
SFS_SHORTCUT_SHOW_CLEAN_TASK_UI = 39,
/// <summary>
/// Switch for displaying the IPD adjustment button in the quick settings, available on PICO4E [PUI5.4.0].
/// </summary>
SFS_SHORTCUT_SHOW_IPD_ADJUSTMENT_UI = 40,
/// <summary>
/// Switch for displaying the power (shutdown/restart) button in the quick settings, available on [PUI5.4.0 and above].
/// </summary>
SFS_SHORTCUT_SHOW_POWER_UI = 41,
/// <summary>
/// Switch for displaying the edit button in the quick settings, available on [PUI5.4.0 and above].
/// </summary>
SFS_SHORTCUT_SHOW_EDIT_UI = 42,
/// <summary>
/// Custom resource button in the industry settings - basic settings, available on [PUI5.4.0 and above].
/// </summary>
SFS_BASIC_SETTING_APP_LIBRARY_UI = 43,
/// <summary>
/// Custom quick settings button in the industry settings - basic settings, available on [PUI5.4.0 and above].
/// </summary>
SFS_BASIC_SETTING_SHORTCUT_UI = 44,
/// <summary>
/// Whether the LED indicator lights up when the screen is off and the battery level is less than 20%, available on PICO G3.
/// </summary>
SFS_LED_FLASHING_WHEN_SCREEN_OFF = 45,
/// <summary>
/// Show/hide the custom settings items in the basic settings.
/// </summary>
SFS_BASIC_SETTING_CUSTOMIZE_SETTING_UI = 46,
/// <summary>
/// Switch for displaying the app quit confirmation dialog when switching apps.
/// </summary>
SFS_BASIC_SETTING_SHOW_APP_QUIT_CONFIRM_DIALOG = 47,
/// <summary>
/// Switch for killing background VR apps. 1 means kill, 2 means don't kill, default is kill.
/// </summary>
SFS_BASIC_SETTING_KILL_BACKGROUND_VR_APP = 48,
/// <summary>
/// Switch for displaying a blue icon during screen mirroring. Default is to display, set to 0 to hide.
/// </summary>
SFS_BASIC_SETTING_SHOW_CAST_NOTIFICATION = 49,
/// <summary>
/// Automatic IPD switch, available on PICO 4E.
/// </summary>
SFS_AUTOMATIC_IPD = 50,
/// <summary>
/// Quick see-through mode switch, available on PICO Neo3 Pro, PICO 4E, and Neo3 Enterprise Edition [PUI 5.7.0].
/// </summary>
SFS_QUICK_SEETHROUGH_MODE = 51,
/// <summary>
/// High refresh rate mode switch, available on PICO Neo3 Pro, PICO 4E, and Neo3 Enterprise Edition [PUI 5.7.0].
/// </summary>
SFS_HIGN_REFERSH_MODE = 52,
/// <summary>
/// Switch for keeping apps running in see-through mode, available on PICO Neo3 Pro, PICO 4E, Neo3 Enterprise Edition, and G3 [PUI 5.8.0].
/// </summary>
SFS_SEETHROUGH_APP_KEEP_RUNNING = 53,
/// <summary>
/// Outdoor tracking enhancement, available on PICO Neo3 Pro, PICO 4E, and Neo3 Enterprise Edition [PUI 5.8.0].
/// </summary>
SFS_OUTDOOR_TRACKING_ENHANCEMENT = 54,
/// <summary>
/// Quick IPD confirmation, available on PICO 4E [PUI 5.8.0].
/// </summary>
SFS_AUTOIPD_AUTO_COMFIRM = 55,
/// <summary>
/// Launch automatic IPD when the headset is worn, available on PICO 4E [PUI 5.8.0].
/// </summary>
SFS_LAUNCH_AUTOIPD_IF_GLASSES_WEARED = 56,
/// <summary>
/// Enable home gesture recognition, available on PICO Neo3 Pro, PICO 4E, and Neo3 Enterprise Edition [PUI 5.8.0].
/// </summary>
SFS_GESTURE_RECOGNITION_HOME_ENABLE = 57,
/// <summary>
/// Enable reset gesture recognition, available on PICO Neo3 Pro, PICO 4E, and Neo3 Enterprise Edition [PUI 5.8.0].
/// </summary>
SFS_GESTURE_RECOGNITION_RESET_ENABLE = 58,
/// <summary>
/// Automatic file copying from USB device (OTG), available on PICO Neo3 Pro, PICO 4E, Neo3 Enterprise Edition, and G3 [PUI 5.8.0].
/// </summary>
SFS_AUTO_COPY_FILES_FROM_USB_DEVICE = 59,
/// <summary>
/// Wi-Fi P2P auto-connect, allowing silent connection without pop-up window.
/// </summary>
SFS_WIFI_P2P_AUTO_CONNECT = 60,
/// <summary>
/// Switch for enabling file copying when the screen is locked.
/// </summary>
SFS_LOCK_SCREEN_FILE_COPY_ENABLE = 61,
/// <summary>
/// Switch for enabling dynamic marker tracking.
/// </summary>
SFS_TRACKING_ENABLE_DYNAMIC_MARKER = 62,
/// <summary>
/// Switch for toggling between 3DOF and 6DOF modes for the controller.
/// </summary>
SFS_ENABLE_3DOF_CONTROLLER_TRACKING = 63,
/// <summary>
/// Enable controller vibration feedback, supported from PUI560.
/// </summary>
SFS_SYSTEM_VIBRATION_ENABLED = 64,
/// <summary>
/// Bluetooth switch.
/// </summary>
SFS_BLUE_TOOTH = 65,
/// <summary>
/// Enhanced video quality, supported from PUI580.
/// </summary>
SFS_ENHANCED_VIDEO_QUALITY = 66,
/// <summary>
/// Gesture recognition (tracking), supported from PUI560.
/// </summary>
SFS_GESTURE_RECOGNITION = 67,
/// <summary>
/// Automatic brightness adjustment, supported from PUI560.
/// </summary>
SFS_BRIGHTNESS_AUTO_ADJUST = 68,
/// <summary>
/// High-current OTG mode, supported from PUI580.
/// </summary>
SFS_HIGH_CURRENT_OTG_MODE = 69,
/// <summary>
/// Disable background app audio playback, supported from PUI560.
/// </summary>
SFS_BACKGROUND_APP_PLAY_AUDIO = 70,
/// <summary>
/// Do not disturb mode, supported from PUI560.
/// </summary>
SFS_NO_DISTURB_MODE = 71,
/// <summary>
/// Monocular screen mirroring, supported from PUI570.
/// </summary>
SFS_MONOCULAR_SCREENCAST = 72,
/// <summary>
/// Monocular screen capture and recording, supported from PUI570.
/// </summary>
SFS_MONOCULAR_SCREEN_CAPTURE = 73,
/// <summary>
/// Stabilize the recording screen to reduce jitter, supported from PUI570.
/// </summary>
SFS_STABILIZATION_FOR_RECORDING = 74,
/// <summary>
/// Hide 2D apps when returning to the home screen if the main app is a VR app.
/// </summary>
SFS_HIDE_2D_APP_WHEN_GO_TO_HOME = 75,
/// <summary>
/// Controller vibration switch.
/// </summary>
SFS_CONTROLLER_VIBRATE = 76,
/// <summary>
/// Refresh mode switch.
/// </summary>
SFS_REFRESH_MODE = 77,
/// <summary>
/// Smart audio switch.
/// </summary>
SFS_SMART_AUDIO = 78,
/// <summary>
/// Eye tracking switch.
/// </summary>
SFS_EYE_TRACK = 79,
/// <summary>
/// Facial expression simulation switch.
/// </summary>
SFS_FACE_SIMULATE = 80,
/// <summary>
/// Enable microphone during screen recording.
/// </summary>
SFS_ENABLE_MIC_WHEN_RECORD = 81,
/// <summary>
/// Continue recording when the screen is off.
/// </summary>
SFS_KEEP_RECORD_WHEN_SCREEN_OFF = 82,
/// <summary>
/// Controller vibration tip in the safety boundary.
/// </summary>
SFS_CONTROLLER_TIP_VIBRATE = 83,
/// <summary>
/// Controller-triggered see-through in the safety boundary.
/// </summary>
SFS_CONTROLLER_SEE_THROUGH = 84,
/// <summary>
/// Lower the height of the safety boundary in place.
/// </summary>
SFS_LOW_BORDER_HEIGHT = 85,
/// <summary>
/// Safety tip for fast movement in the safety boundary.
/// </summary>
SFS_FAST_MOVE_TIP = 86,
/// <summary>
/// Enable wireless USB debugging.
/// </summary>
SFS_WIRELESS_USB_ADB = 87,
/// <summary>
/// Automatic system update.
/// </summary>
SFS_SYSTEM_AUTO_UPDATE = 88,
/// <summary>
/// USB tethering switch.
/// </summary>
SFS_USB_TETHERING = 89,
/// <summary>
/// Respond to the HMD back key in real-time in VR apps.
/// When the switch is on: Pressing the HMD back key sends a DOWN event, and releasing it sends an UP event.
/// When the switch is off: Pressing the HMD back key does not send a DOWN event, and releasing it sends both DOWN/UP events.
/// </summary>
SFS_REAL_TIME_RESPONSE_HMD_BACK_KEY_IN_VR_APP = 90,
/// <summary>
/// Prioritize using markers to retrieve the map.
/// </summary>
SFS_RETRIEVE_MAP_BY_MARKER_FIRST = 91,
/// <summary>
/// Detect if the controller is in a still state.
/// </summary>
SFS_CONTROLLER_STILL = 92,
/// <summary>
/// Switch for displaying the performance button in the quick settings, available on Sparrow_PUI513.
/// </summary>
SFS_SHORTCUT_SHOW_PERFORMANCE_UI = 93,
/// <summary>
/// Battery status display.
/// 0 - Do not display.
/// 1 - Display on the HUD.
/// 2 - Always display.
/// </summary>
SFS_BATTERY_STATUS_DISPLAY = 94,
/// <summary>
/// Quick relocation.
/// </summary>
SFS_QUICK_RELOCATION = 95,
/// <summary>
///toggle for mixed tracking mode
/// </summary>
SFS_MIXED_INTERACTION_MODE = 96,
/// <summary>
/// reminder for abnormal locating
/// </summary>
SFS_REMINDER_FOR_ABNORMAL_LOCATING = 97,
/// <summary>
/// HOME gesture toggle: in system desktop
/// </summary>
SFS_GESTURE_RECOGNITION_HOME_ENABLE_ON_DESKTOP=98,
/// <summary>
/// RESET gesture toggle: in system desktop
/// </summary>
SFS_GESTURE_RECOGNITION_RESET_ENABLE_ON_DESKTOP=99,
/// <summary>
/// disable window memory optimization strategy
/// </summary>
SFS_DISABLE_WINDOW_MEMORY_OPTIMIZATION=100,
/// <summary>
/// global VST.
/// </summary>
SFS_GLOBAL_VST=102,
/// <summary>
/// toggle for hand tracking injection
/// </summary>
SFS_HAND_TRACKING_HOOK=103,
/// <summary>
/// toggle for USB tethering with static IP
/// </summary>
SFS_USB_TETHERING_STATIC_IP_ENABLED=104,
/// <summary>
/// tracking mode (`0`- body tracking; `1` - object tracking)
/// </summary>
SFS_TRACKER_MODE=105,
/// <summary>
/// Guardian persistent immersive mode: do not auto-enter VST when leaving the play area (`0` — system default, no special handling; `1` — do not trigger VST)
/// </summary>
SFS_GUARDIAN_PERSISTENT_IMMERSION_MODE=106
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: d478586fa3b0236429ce81bab6f48957
timeCreated: 1685943877

View File

@@ -0,0 +1,134 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum SystemInfoEnum
{
/// <summary>
/// Check the battery level.
/// </summary>
ELECTRIC_QUANTITY = 0,
/// <summary>
/// Check the PUI version number.
/// </summary>
PUI_VERSION = 1,
/// <summary>
/// Check the device model.
/// </summary>
EQUIPMENT_MODEL = 2,
/// <summary>
/// Check the device serial number (SN).
/// </summary>
EQUIPMENT_SN = 3,
/// <summary>
/// Check the customer serial number (SN).
/// </summary>
CUSTOMER_SN = 4,
/// <summary>
/// Check the internal storage space of the device.
/// </summary>
INTERNAL_STORAGE_SPACE_OF_THE_DEVICE = 5,
/// <summary>
/// Check the Bluetooth status of the device.
/// </summary>
DEVICE_BLUETOOTH_STATUS = 6,
/// <summary>
/// Check the name of the connected Bluetooth device.
/// </summary>
BLUETOOTH_NAME_CONNECTED = 7,
/// <summary>
/// Check the Bluetooth MAC address.
/// </summary>
BLUETOOTH_MAC_ADDRESS = 8,
/// <summary>
/// Check the Wi-Fi status of the device.
/// </summary>
DEVICE_WIFI_STATUS = 9,
/// <summary>
/// Check the name of the connected Wi-Fi network.
/// </summary>
WIFI_NAME_CONNECTED = 10,
/// <summary>
/// Check the WLAN MAC address.
/// </summary>
WLAN_MAC_ADDRESS = 11,
/// <summary>
/// Check the device IP address.
/// </summary>
DEVICE_IP = 12,
/// <summary>
/// Check if the device is charging.
/// </summary>
CHARGING_STATUS = 13,
/// <summary>
/// Neo3 device old and new keys.
/// </summary>
DEVICE_KEY = 14,
/// <summary>
/// Bluetooth information of the device itself.
/// Return value format: Name|Address
/// Return value example: PICO 4|08:16:D5:70:20:11
/// </summary>
BLUETOOTH_INFO_DEVICE = 15,
/// <summary>
/// Information of the connected Bluetooth devices.
/// Return value format: [Bluetooth device 1 name|Bluetooth device 1 address, Bluetooth device 2 name|Bluetooth device 2 address, ...]
/// Return value example: [PICO 4|08:16:D5:70:20:11, PICO Neo 3|21:23:D5:7A:2C:DE]
/// </summary>
BLUETOOTH_INFO_CONNECTED = 16,
/// <summary>
/// Camera temperature in Celsius.
/// </summary>
CAMERA_TEMPERATURE_CELSIUS = 17,
/// <summary>
/// Camera temperature in Fahrenheit.
/// </summary>
CAMERA_TEMPERATURE_FAHRENHEIT = 18,
/// <summary>
/// Large space map information.
/// </summary>
LARGESPACE_MAP_INFO = 19,
/// <summary>
/// Current charging protocol.
/// </summary>
CURRENT_CHARGING_PROTOCOL = 20,
/// <summary>
/// Maximum USB charging power.
/// </summary>
USB_PWOER_MAX = 21,
/// <summary>
/// Head-mounted display (HMD) position and orientation.
/// </summary>
HMD_POSITION_AND_ORIENTATION = 22,
/// <summary>
/// the status of PSensor
/// </summary>
PSENSOR_STATUS = 23,
/// <summary>
/// the scale of the large-space map
/// </summary>
LARGE_SPACE_MAP_SCALE = 24
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 1fb47fac324da0244b89e5cba9b606db
timeCreated: 1685937098

View File

@@ -0,0 +1,9 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum SystemKeyEnum
{
ENTER_KEY=0,
BACK_KEY=1,
VOLUME_KEY=2,
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 6d168ba74a784d1c8fcf699a5e6e12b5
timeCreated: 1698917116

View File

@@ -0,0 +1,8 @@
namespace Unity.XR.PICO.TOBSupport
{
public enum USBConfigModeEnum
{
MTP=0,
CHARGE=1
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 83c4de97e8bbda3448a5180986a87c33
timeCreated: 1685944441

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: c5c24af23d2b3de43bf3444f7edca288
timeCreated: 1685952511

View File

@@ -0,0 +1,28 @@
using System;
using UnityEngine;
namespace Unity.XR.PICO.TOBSupport
{
public class BindCallback : AndroidJavaProxy
{
public Action<bool> mCallback;
public BindCallback(Action<bool> callback) : base("com.picoxr.tobservice.interfaces.BoolCallback")
{
mCallback = callback;
}
public void CallBack(bool var1)
{
Debug.Log("ToBService bindCallBack 回调:" + var1);
PXR_EnterprisePlugin.GetServiceBinder();
PXR_EnterpriseTools.QueueOnMainThread(() =>
{
if (mCallback != null)
{
mCallback(var1);
}
});
}
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 51a5199660b7a714aae526c9e8ecf42e
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,26 @@
using System;
using UnityEngine;
namespace Unity.XR.PICO.TOBSupport
{
public class BoolCallback : AndroidJavaProxy
{
public Action<bool> mCallback;
public BoolCallback(Action<bool> callback) : base("com.picoxr.tobservice.interfaces.BoolCallback")
{
mCallback = callback;
}
public void CallBack(bool var1)
{
PXR_EnterpriseTools.QueueOnMainThread(() =>
{
if (mCallback!=null)
{
mCallback(var1);
}
});
}
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 4ec069c2f433a8649af361d7ff835006
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,50 @@
using System;
using UnityEngine;
namespace Unity.XR.PICO.TOBSupport
{
public class FileCopyCallback: AndroidJavaProxy
{
public Action mOnCopyStart;
public Action<double> mOnCopyProgress;
public Action<int> mOnCopyFinish;
public FileCopyCallback(Action onCopyStart,Action<double> onCopyProgress,Action<int> onCopyFinish) : base("com.picoxr.tobservice.interfaces.FileCopyCallback")
{
mOnCopyStart = onCopyStart;
mOnCopyProgress = onCopyProgress;
mOnCopyFinish = onCopyFinish;
}
public void OnCopyStart()
{
PXR_EnterpriseTools.QueueOnMainThread(() =>
{
if (mOnCopyStart!=null)
{
mOnCopyStart();
}
});
}
public void OnCopyProgress(double var1)
{
PXR_EnterpriseTools.QueueOnMainThread(() =>
{
if (mOnCopyProgress!=null)
{
mOnCopyProgress(var1);
}
});
}
public void OnCopyFinish(int var1)
{
PXR_EnterpriseTools.QueueOnMainThread(() =>
{
if (mOnCopyFinish!=null)
{
mOnCopyFinish(var1);
}
});
}
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 3f1ff22a32748af4ebc61fc3e215b7c1
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,26 @@
using System;
using UnityEngine;
namespace Unity.XR.PICO.TOBSupport
{
public class IntCallback : AndroidJavaProxy
{
public Action<int> mCallback;
public IntCallback(Action<int> callback) : base("com.picoxr.tobservice.interfaces.IntCallback")
{
mCallback = callback;
}
public void CallBack(int var1)
{
PXR_EnterpriseTools.QueueOnMainThread(() =>
{
if (mCallback != null)
{
mCallback(var1);
}
});
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 96277bb913de2a84e8f29f38fbdc9f29
timeCreated: 1685959032

View File

@@ -0,0 +1,26 @@
using System;
using UnityEngine;
namespace Unity.XR.PICO.TOBSupport
{
public class LongCallback : AndroidJavaProxy
{
public Action<long> mCallback;
public LongCallback(Action<long> callback) : base("com.picoxr.tobservice.interfaces.LongCallback")
{
mCallback = callback;
}
public void CallBack(long var1)
{
PXR_EnterpriseTools.QueueOnMainThread(() =>
{
if (mCallback != null)
{
mCallback(var1);
}
});
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: be7c175a931c58d43adc4dfd8b4919a2
timeCreated: 1685959096

View File

@@ -0,0 +1,118 @@
using System;
using System.Collections;
using System.Collections.Generic;
using LitJson;
#if PICO_OPENXR_SDK
using Unity.XR.OpenXR.Features.PICOSupport;
#endif
using Unity.XR.PXR;
using UnityEngine;
using UnityEngine.XR;
namespace Unity.XR.PICO.TOBSupport
{
public class MarkerInfoCallback : AndroidJavaProxy
{
public Action<List<MarkerInfo>> mCallback;
private List<MarkerInfo> mlist = new List<MarkerInfo>();
private TrackingOriginModeFlags TrackingMode;
private float YOffset;
public MarkerInfoCallback(TrackingOriginModeFlags trackingMode, float cameraYOffset,
Action<List<MarkerInfo>> callback) : base("com.picoxr.tobservice.interfaces.StringCallback")
{
TrackingMode = trackingMode;
YOffset = cameraYOffset;
mCallback = callback;
mlist.Clear();
#if PICO_OPENXR_SDK
OpenXRExtensions.SetMarkMode();
#endif
}
public void CallBack(string var1)
{
Debug.Log("ToBService MarkerInfo Callback 回调:" + var1);
List<MarkerInfo> tmp = JsonToMarkerInfos(var1);
PXR_EnterpriseTools.QueueOnMainThread(() =>
{
if (mCallback != null)
{
mCallback(tmp);
}
});
}
public List<MarkerInfo> JsonToMarkerInfos(string json)
{
if (string.IsNullOrEmpty(json))
{
return null;
}
List<MarkerInfo> ModelList = new List<MarkerInfo>();
JsonData jsonData = JsonMapper.ToObject(json);
IDictionary dictionary = jsonData as IDictionary;
for (int i = 0; i < dictionary.Count; i++)
{
Debug.Log("TOB TestDemo---- MarkerInfo Callback 回调:1");
float OriginHeight = 0;
if (TrackingMode == TrackingOriginModeFlags.Device || TrackingMode == TrackingOriginModeFlags.Floor)
{
#if !PICO_OPENXR_SDK
OriginHeight = PXR_Plugin.System.UPxr_GetConfigFloat(ConfigType.ToDelaSensorY);
#else
float trackingorigin_height = PXR_EnterprisePlugin.oxr_get_trackingorigin_height();
float locationheight = OpenXRExtensions.GetLocationHeight();
if (TrackingMode == TrackingOriginModeFlags.Floor)
{
YOffset = 0;
OriginHeight = -trackingorigin_height;
}
else
{
// OriginHeight = trackingorigin_height + locationheight;
// OriginHeight = locationheight;
OriginHeight = -trackingorigin_height;
}
#endif
}
else
{
OriginHeight = 0;
YOffset = 0;
}
Debug.Log("TOB TestDemo---- MarkerInfo Callback 回调:OriginHeight"+OriginHeight );
MarkerInfo model = new MarkerInfo();
model.posX = double.Parse(jsonData[i]["posX"].ToString());
model.posY = double.Parse(jsonData[i]["posY"].ToString()) + OriginHeight + YOffset;
model.posZ = -double.Parse(jsonData[i]["posZ"].ToString());
model.rotationX = -double.Parse(jsonData[i]["rotationX"].ToString());
model.rotationY = -double.Parse(jsonData[i]["rotationY"].ToString());
model.rotationZ = double.Parse(jsonData[i]["rotationZ"].ToString());
model.rotationW = double.Parse(jsonData[i]["rotationW"].ToString());
model.validFlag = int.Parse(jsonData[i]["validFlag"].ToString());
model.markerType = int.Parse(jsonData[i]["markerType"].ToString());
model.iMarkerId = int.Parse(jsonData[i]["iMarkerId"].ToString());
model.dTimestamp = double.Parse(jsonData[i]["dTimestamp"].ToString());
IDictionary dictionaryReserve = jsonData[i]["reserve"] as IDictionary;
model.reserve = new float[dictionaryReserve.Count];
for (int j = 0; j < dictionaryReserve.Count; j++)
{
model.reserve[j] = float.Parse(jsonData[i]["reserve"][j].ToString());
}
ModelList.Add(model);
}
return ModelList;
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 0f3dd52fe57c0fc4490989b3e1841b24
timeCreated: 1686224891

View File

@@ -0,0 +1,26 @@
using System;
using UnityEngine;
namespace Unity.XR.PICO.TOBSupport
{
public class StringCallback : AndroidJavaProxy
{
public Action<string> mCallback;
public StringCallback(Action<string> callback) : base("com.picoxr.tobservice.interfaces.StringCallback")
{
mCallback = callback;
}
public void CallBack(string var1)
{
PXR_EnterpriseTools.QueueOnMainThread(() =>
{
if (mCallback != null)
{
mCallback(var1);
}
});
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 0032579f19172484ebd2e85a16a8194d
timeCreated: 1685959143

View File

@@ -0,0 +1,39 @@
using System;
using UnityEngine;
namespace Unity.XR.PICO.TOBSupport
{
public class SystemUpdateCallback: AndroidJavaProxy
{
public Action<int, float> OnUpdateStatusChanged;
public Action<int, string> OnUpdateComplete;
public SystemUpdateCallback(Action<int, float> onUpdateStatusChanged,Action<int, string> onUpdateComplete) : base("com.picoxr.tobservice.interfaces.SystemUpdateCallback")
{
OnUpdateStatusChanged = onUpdateStatusChanged;
OnUpdateComplete = onUpdateComplete;
}
public void onUpdateStatusChanged(int statusCode, float percent)
{
PXR_EnterpriseTools.QueueOnMainThread(() =>
{
if (OnUpdateStatusChanged != null)
{
OnUpdateStatusChanged(statusCode, percent);
}
});
}
public void onUpdateComplete(int errorCode, String errorMsg)
{
PXR_EnterpriseTools.QueueOnMainThread(() =>
{
if (OnUpdateComplete != null)
{
OnUpdateComplete(errorCode, errorMsg);
}
});
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: dfd8a8c785434ba88e87c2d8f2b726e8
timeCreated: 1721371715

View File

@@ -0,0 +1,59 @@
using System;
using System.Collections;
using System.Collections.Generic;
using LitJson;
using UnityEngine;
namespace Unity.XR.PICO.TOBSupport
{
public class WifiDisplayModelCallback : AndroidJavaProxy
{
public Action<List<WifiDisplayModel>> mCallback;
public WifiDisplayModelCallback(Action<List<WifiDisplayModel>> callback) : base("com.picoxr.tobservice.interfaces.StringCallback")
{
mCallback = callback;
}
public void CallBack(string var1)
{
Debug.Log("ToBService WifiDisplayModelCallback 回调:" + var1);
List<WifiDisplayModel> tmp = JsonToWifiDisplayModel(var1);
PXR_EnterpriseTools.QueueOnMainThread(() =>
{
if (mCallback != null)
{
mCallback(tmp);
}
});
}
public List<WifiDisplayModel> JsonToWifiDisplayModel(string json)
{
if (string.IsNullOrEmpty(json))
{
return null;
}
List<WifiDisplayModel> ModelList = new List<WifiDisplayModel>();
JsonData jsonData = JsonMapper.ToObject(json);
IDictionary dictionary = jsonData as IDictionary;
for (int i = 0; i < dictionary.Count; i++)
{
WifiDisplayModel model = new WifiDisplayModel();
model.deviceAddress = jsonData[i]["deviceAddress"].ToString();
model.deviceName = jsonData[i]["deviceName"].ToString();
model.isAvailable = bool.Parse(jsonData[i]["isAvailable"].ToString());
model.canConnect = bool.Parse(jsonData[i]["canConnect"].ToString());
model.isRemembered = bool.Parse(jsonData[i]["isRemembered"].ToString());
model.statusCode = int.Parse(jsonData[i]["statusCode"].ToString());
model.status = jsonData[i]["status"].ToString();
model.description = jsonData[i]["description"].ToString();
ModelList.Add(model);
}
return ModelList;
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 6cf02f2e31d415c41b26dd8e5108dada
timeCreated: 1686050869

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 1f65db304235e324c898720b2c3f4ce1
timeCreated: 1686224723

View File

@@ -0,0 +1,58 @@
namespace Unity.XR.PICO.TOBSupport
{
public class ComponentName
{
private string _pkg;
private string _cls;
private string _flattenToShortString;
private string _getShortClassName;
private string _toShortString;
private string _toString;
public ComponentName(string pkg, string cls)
{
_pkg = pkg;
_cls = cls;
}
public ComponentName(string pkg, string cls, string flattenToShortString, string getShortClassName, string toShortString, string toString)
{
_pkg = pkg;
_cls = cls;
_flattenToShortString = flattenToShortString;
_getShortClassName = getShortClassName;
_toShortString = toShortString;
_toString = toString;
}
public string getPackageName()
{
return _pkg;
}
public string getClassName()
{
return _cls;
}
public string flattenToShortString()
{
return _flattenToShortString;
}
public string getShortClassName()
{
return _getShortClassName;
}
public string toShortString()
{
return _toShortString;
}
public override string ToString()
{
return _toString;
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 7f27e4ace8184aa899a9b7f6849e3c72
timeCreated: 1742452121

View File

@@ -0,0 +1,33 @@
namespace Unity.XR.PICO.TOBSupport
{
public class PXRCapture
{
public const string VALUE_TRUE = "1";
public const string VALUE_FALSE = "0";
public const string KEY_MCTF = "enable-mctf";
public const string KEY_EIS = "enable-eis";
public const string KEY_MFNR = "enable-mfnr";
public const string KEY_ENABLE_MVHEVC = "enable-mvhevc";
public const string KEY_OUTPUT_CAMERA_RAW_DATA = "output-camera-raw-data";
//与视频录制有关,目前暂不支持
public const string KEY_VIDEO_FPS = "video-fps";
public const string KEY_VIDEO_WIDTH = "video-width";
public const string KEY_VIDEO_HEIGHT = "video-height";
public const string KEY_VIDEO_BITRATE = "video-bit-rate";
public const string KEY_WRITE_DEPTH_DATA = "write-depth-data";
public const string KEY_WRITE_POSE_DATA = "write-pose-data";
public const string KEY_WRITE_CAMERA_PARAMS_DATA = "write-camera-params-data";
public const int CAPTURE_STATUS_STREAM_TIME_OUT = -100;
public const int CAPTURE_STATUS_PREPROCESS_ERROR = -99;
public const int CAPTURE_STATUS_RECORD_ERROR = -98;
public const int CAPTURE_STATUS_NO_PERMISSION = -97;
public const int CAPTURE_STATUS_SERVER_DIED = -96;
public const int CAPTURE_STATUS_UNKNOWN = -95;
public const int CAPTURE_STATUS_OK = 0;
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 73b8e45c73404959ba2f68cd312a907f
timeCreated: 1752739063

View File

@@ -0,0 +1,97 @@
using System;
using UnityEngine;
namespace Unity.XR.PICO.TOBSupport
{
[Serializable]
public class HandStateAlg
{
public const int Hand_MaxBones = 26;
public const int Hand_MaxPinch = 5;
public const int Hand_MaxFingers = 5;
public const int Hand_Pinch_Num = 4;
public short status;
public HandJointsLocation rootPose;
public HandJointsLocation[] bonePose ;
public short pinches;
public float[] pinchStrength ;
public float clickStrength;
public Pose pointerPose;
public float handScale;
public int handConfidence;
public int[] fingerConfidence ;
public long requestedTimeStamp;
public long sampleTimeStamp;
public long outputTimeStamp;
public short poseType = 0;
public int handType ;
public Pose rootPoseVel;
public Pose[] bonePoseVel ;
public Pose rootPoseAcc;
public Pose[] bonePoseAcc;
public short clickType ;
public bool[] pinchActionReadyOpenxr ;
public bool aimActionReadyOpenxr;
public bool gripActionReadyOpenxr;
public float[] pinchActionValueOpenxr ;
public float aimActionValueOpenxr;
public float gripActionValueOpenxr;
public Pose[] pinchPoseOpenxr ;
public Pose aimPoseOpenxr;
public Pose pokePoseOpenxr;
public Pose gripPoseOpenxr;
public Pose gripSurfacePoseOpenxr;
public HandStateAlg()
{
status = 0;
rootPose = new HandJointsLocation();
bonePose = new HandJointsLocation[Hand_MaxBones];
for (int i = 0; i < Hand_MaxBones; i++) {
bonePose[i] = new HandJointsLocation();
}
pinches = 0;
pinchStrength = new float[Hand_MaxPinch];
clickStrength = 0f;
pointerPose = new Pose();
handScale = 1f;
handConfidence = 0;
fingerConfidence = new int[Hand_MaxFingers];
requestedTimeStamp = 0;
sampleTimeStamp = 0;
outputTimeStamp = 0;
poseType = 0;
handType = -1;
rootPoseVel = new Pose();
bonePoseVel = new Pose[Hand_MaxBones];
rootPoseAcc = new Pose();
bonePoseAcc = new Pose[Hand_MaxBones];
clickType = -1;
pinchActionReadyOpenxr = new bool[Hand_Pinch_Num];
aimActionReadyOpenxr = false;
gripActionReadyOpenxr = false;
pinchActionValueOpenxr = new float[Hand_Pinch_Num];
aimActionValueOpenxr = 0f;
gripActionValueOpenxr = 0f;
pinchPoseOpenxr = new Pose[Hand_Pinch_Num];
aimPoseOpenxr = new Pose();
pokePoseOpenxr = new Pose();
gripPoseOpenxr = new Pose();
gripSurfacePoseOpenxr = new Pose();
}
public static string ToJson(HandStateAlg data)
{
// 注意JsonUtility 序列化数组时需包裹在对象中,这里直接序列化根对象即可
return JsonUtility.ToJson(data, true); // 第二个参数为 true 时输出格式化的 JSON
}
}
[Serializable]
public class HandJointsLocation
{
public long locationFloags;
public Pose pose;
public float radius;
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 69863a27ce994e6697f6b7ff45e7b032
timeCreated: 1748339838

View File

@@ -0,0 +1,106 @@
using System;
using System.Collections.Generic;
using UnityEngine;
namespace Unity.XR.PICO.TOBSupport
{
[Serializable]
public class IMUData
{
public long timestamp;
public double vx;
public double vy;
public double vz;
public double ax;
public double ay;
public double az;
public double wx;
public double wy;
public double wz;
public double w_ax;
public double w_ay;
public double w_az;
public List<int> reservedInt;
public List<double> reservedDouble;
public IMUData()
{
timestamp = 0;
vx = vy = vz = 0.0;
ax = ay = az = 0.0;
wx = wy = wz = 0.0;
w_ax = w_ay = w_az = 0.0;
reservedInt = new List<int>();
reservedDouble = new List<double>();
}
}
[Serializable]
public class IMUDataListWrapper
{
public List<IMUData> IMUDatas;
}
public partial class JsonParser
{
public static IMUData ParseIMUDataFromJson(string json)
{
try
{
return JsonUtility.FromJson<IMUData>(json);
}
catch (Exception ex)
{
Debug.LogError($"JSON 解析出错: {ex.Message}");
return null;
}
}
public static List<IMUData> ParseIMUDatasFromJson(string json)
{
try
{
// 先解析到包装类
IMUDataListWrapper wrapper = JsonUtility.FromJson<IMUDataListWrapper>(json);
if (wrapper != null && wrapper.IMUDatas != null)
{
return wrapper.IMUDatas;
}
return null;
}
catch (Exception ex)
{
Debug.LogError($"JSON 解析出错: {ex.Message}");
return null;
}
}
public static string IMUDataToJson(IMUData data)
{
try
{
return JsonUtility.ToJson(data);
}
catch (Exception ex)
{
Debug.LogError($"对象转 JSON 出错: {ex.Message}");
return null;
}
}
public static string IMUDataArrayToJson(List<IMUData> datas)
{
try
{
// 创建包装类实例
IMUDataListWrapper wrapper = new IMUDataListWrapper
{
IMUDatas = datas
};
// 使用 JsonUtility.ToJson 方法将包装类对象转换为 JSON 字符串
return JsonUtility.ToJson(wrapper);
}
catch (Exception ex)
{
Debug.LogError($"对象数组转 JSON 出错: {ex.Message}");
return null;
}
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 0e5b2760ae0040efa99b7c803b07de50
timeCreated: 1748317798

View File

@@ -0,0 +1,132 @@
using System.Collections.Generic;
using UnityEngine;
namespace Unity.XR.PICO.TOBSupport
{
public class Intent
{
private string Componentpkg = "";
private string Componentcls = "";
private string Action = "";
private string type = "";
private string url = "";
List<string> categoryList = new List<string>();
Dictionary<string, string> stringPairs = new Dictionary<string, string>();
Dictionary<string, bool> boolPairs = new Dictionary<string, bool>();
Dictionary<string, int> intPairs = new Dictionary<string, int>();
Dictionary<string, float> floatPairs = new Dictionary<string, float>();
Dictionary<string, double> doublePairs = new Dictionary<string, double>();
public void setComponent(string pkg, string cls)
{
Componentpkg = pkg;
Componentcls = cls;
}
public void setAction(string _Action)
{
Action = _Action;
}
public void setType(string _type)
{
type = _type;
}
public void setData(string _url)
{
url = _url;
}
public void addCategory(string _category)
{
categoryList.Add(_category);
}
public void putExtra(string name, string value)
{
stringPairs.Add(name, value);
}
public void putExtra(string name, int value)
{
intPairs.Add(name, value);
}
public void putExtra(string name, float value)
{
floatPairs.Add(name, value);
}
public void putExtra(string name, double value)
{
doublePairs.Add(name, value);
}
public void putExtra(string name, bool value)
{
boolPairs.Add(name, value);
}
public AndroidJavaObject getIntent()
{
AndroidJavaObject intent = new AndroidJavaObject("android.content.Intent");
if (!string.IsNullOrEmpty(Componentpkg) && !string.IsNullOrEmpty(Componentcls))
{
AndroidJavaObject componentName =
new AndroidJavaObject("android.content.ComponentName", Componentpkg, Componentcls);
intent.Call<AndroidJavaObject>("setComponent", componentName);
}
if (!string.IsNullOrEmpty(Action))
{
intent.Call<AndroidJavaObject>("setAction", Action);
}
if (!string.IsNullOrEmpty(type))
{
intent.Call<AndroidJavaObject>("setType", type);
}
// mIntent.setData(Uri.parse(""));
if (!string.IsNullOrEmpty(url))
{
AndroidJavaClass uriClass = new AndroidJavaClass("android.net.Uri"); // 对应的安卓调用函数是Uri.parse()
AndroidJavaObject uriObject = uriClass.CallStatic<AndroidJavaObject>("parse", url);
intent.Call<AndroidJavaObject>("setData", uriObject);
}
if (categoryList.Count != 0)
{
for (int i = 0; i < categoryList.Count; i++)
{
intent.Call<AndroidJavaObject>("addCategory", categoryList[i]);
}
}
foreach (KeyValuePair<string, string> kvp in stringPairs)
{
intent.Call<AndroidJavaObject>("putExtra", kvp.Key, kvp.Value);
}
foreach (KeyValuePair<string, int> kvp in intPairs)
{
intent.Call<AndroidJavaObject>("putExtra", kvp.Key, kvp.Value);
}
foreach (KeyValuePair<string, bool> kvp in boolPairs)
{
intent.Call<AndroidJavaObject>("putExtra", kvp.Key, kvp.Value);
}
foreach (KeyValuePair<string, float> kvp in floatPairs)
{
intent.Call<AndroidJavaObject>("putExtra", kvp.Key, kvp.Value);
}
foreach (KeyValuePair<string, double> kvp in doublePairs)
{
intent.Call<AndroidJavaObject>("putExtra", kvp.Key, kvp.Value);
}
return intent;
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 9e2fc05a295c4d17bf17cf1784ef3059
timeCreated: 1709199569

View File

@@ -0,0 +1,39 @@
using System.Collections.Generic;
namespace Unity.XR.PICO.TOBSupport
{
public class LargeSpaceBoundsInfo
{
public const int TYPE_IN_SITU_SAFETY_ZONE = 10;
public const int TYPE_OBSTACLE = 2;
public const int TYPE_CUSTOMIZE_SECURITY_ZONE = 1;
public override string ToString()
{
return $"LargeSpaceBoundsInfo{{type= {type}, bounds= {string.Join(", ", bounds)} }}";
}
private int type;
private List<Point3D> bounds = new List<Point3D>();
public List<Point3D> getBounds()
{
return this.bounds;
}
public void setType(int type)
{
this.type = type;
}
public int getType()
{
return this.type;
}
public void addPoint3D(Point3D point3D)
{
this.bounds.Add(point3D);
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 5d34bae0bdbf4862981e6029b5552dfe
timeCreated: 1742457676

View File

@@ -0,0 +1,20 @@
namespace Unity.XR.PICO.TOBSupport
{
public class LargeSpaceQuickModeInfo
{
public bool status;
public int length;
public int width;
public int originType;
public LargeSpaceQuickModeInfo()
{
}
public override string ToString()
{
return
$"{nameof(status)}: {status}, {nameof(length)}: {length}, {nameof(width)}: {width}, {nameof(originType)}: {originType}";
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: fb0961e0f2e64cd5bfff021b5f334bea
timeCreated: 1715673498

View File

@@ -0,0 +1,38 @@
using System.Linq;
namespace Unity.XR.PICO.TOBSupport
{
public class MarkerInfo
{
// position
public double posX;
public double posY;
public double posZ;
// rotation
public double rotationX;
public double rotationY;
public double rotationZ;
public double rotationW;
// 标志位:识别无效=0识别有效=1
public int validFlag;
// 类型:静态=1/动态=0
public int markerType;
// marker id
public int iMarkerId;
// 检测图像的时间戳
public double dTimestamp;
// 预留标志位
public float[] reserve;
public override string ToString()
{
return $"{nameof(posX)}: {posX}, {nameof(posY)}: {posY}, {nameof(posZ)}: {posZ}, {nameof(rotationX)}: {rotationX}, {nameof(rotationY)}: {rotationY}, {nameof(rotationZ)}: {rotationZ}, {nameof(rotationW)}: {rotationW}, {nameof(validFlag)}: {validFlag}, {nameof(markerType)}: {markerType}, {nameof(iMarkerId)}: {iMarkerId}, {nameof(dTimestamp)}: {dTimestamp}, {nameof(reserve)}: {string.Join(" ", reserve)}";
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: f68848d9c705ba340a11b2713ae79b83
timeCreated: 1686224373

View File

@@ -0,0 +1,24 @@
using System;
namespace Unity.XR.PICO.TOBSupport
{
public class OffLineSystemUpdateConfig
{
//OTA压缩包路径
public String otaFilePath = null;
//升级完成后是否自动重启
public Boolean autoReboot = true;
//升级过程中是否显示进度
public Boolean showProgress = false;
public OffLineSystemUpdateConfig()
{
}
public OffLineSystemUpdateConfig(string otaFilePath, bool autoReboot, bool showProgress)
{
this.otaFilePath = otaFilePath;
this.autoReboot = autoReboot;
this.showProgress = showProgress;
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 1bacf34f0a1d4af78e887965627b33eb
timeCreated: 1721372797

View File

@@ -0,0 +1,18 @@
namespace Unity.XR.PICO.TOBSupport
{
public class Point3D
{
public double x;
public double y;
public double z;
public Point3D()
{
}
public override string ToString()
{
return $"Point3D:{nameof(x)}: {x}, {nameof(y)}: {y}, {nameof(z)}: {z}";
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 4808a326866641fdbd01f82a39e44aaf
timeCreated: 1715150347

View File

@@ -0,0 +1,119 @@
using System;
using System.Collections.Generic;
using UnityEngine;
namespace Unity.XR.PICO.TOBSupport
{
// 包装 Pose 列表的类,用于 JsonUtility 解析
[Serializable]
public class PoseListWrapper
{
public List<Pose> Poses;
}
[Serializable]
public class Pose
{
public long timestamp;
public double x;
public double y;
public double z;
public double rw;
public double rx;
public double ry;
public double rz;
public int type;
public int confidence;
public int poseError;
public List<int> reservedInt;
public List<double> reservedDouble;
public Pose()
{
timestamp = 0;
x = 0.0;
y = 0.0;
z = 0.0;
rw = 0.0;
rx = 0.0;
ry = 0.0;
rz = 0.0;
type = 0;
confidence = 0;
poseError = 0;
reservedInt = new List<int>();
reservedDouble = new List<double>();
}
}
public partial class JsonParser
{
public static Pose ParsePoseFromJson(string json)
{
try
{
// 使用 Unity 的 JsonUtility 解析 JSON 字符串为 Pose 对象
return JsonUtility.FromJson<Pose>(json);
}
catch (Exception ex)
{
Debug.LogError($"JSON 解析出错: {ex.Message}");
return null;
}
}
public static List<Pose> ParsePoseArrayFromJson(string json)
{
try
{
// 先解析到包装类
PoseListWrapper wrapper = JsonUtility.FromJson<PoseListWrapper>(json);
if (wrapper != null && wrapper.Poses != null)
{
return wrapper.Poses;
}
return null;
}
catch (Exception ex)
{
Debug.LogError($"JSON 解析出错: {ex.Message}");
return null;
}
}
// 新增方法:将 Pose 对象转换为 JSON 字符串
public static string PoseToJson(Pose pose)
{
try
{
// 使用 JsonUtility.ToJson 方法将 Pose 对象转换为 JSON 字符串
return JsonUtility.ToJson(pose);
}
catch (Exception ex)
{
Debug.LogError($"对象转 JSON 出错: {ex.Message}");
return null;
}
}
// 新增方法:将 Pose 数组转换为 JSON 字符串
public static string PoseArrayToJson(List<Pose> poses)
{
try
{
// 创建包装类实例
PoseListWrapper wrapper = new PoseListWrapper
{
Poses =poses
};
// 使用 JsonUtility.ToJson 方法将包装类对象转换为 JSON 字符串
return JsonUtility.ToJson(wrapper);
}
catch (Exception ex)
{
Debug.LogError($"对象数组转 JSON 出错: {ex.Message}");
return null;
}
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: d5ce8d9b73c44f868c21ed1793aa87b5
timeCreated: 1748311214

View File

@@ -0,0 +1,114 @@
using System;
using System.Collections.Generic;
using UnityEngine;
namespace Unity.XR.PICO.TOBSupport
{
[System.Serializable]
public class SwiftDevice
{
public const int STATUS_OFFLINE = 0;
public const int STATUS_ONLINE = 1;
public const int POSITION_UNDEFINED = 0;
public const int POSITION_LEFT = 1;
public const int POSITION_RIGHT = 2;
public const int POSITION_CENTER = 3;
public const int BIND_NONE = 0;
public const int BIND_DONE = 1;
public const int ID_ALL = 0;
public const int ID_T1 = 1;
public const int ID_T2 = 2;
public const int ID_T3 = 3;
public const int CHARGE_STATUS_NONE = 0;
public const int CHARGE_STATUS_PRE = 1;
public const int CHARGE_STATUS_GOING = 2;
public const int CHARGE_STATUS_DONE = 3;
public const int BATTERY_LOW = 0;
public int connectState;
public int position;
public int bindState;
public int id;
public string fwVersion;
public string hwVersion;
public string sn;
public string addr;
public int chargeStatus;
public int battery;
public int imuType;
public int generation;
public SwiftDevice()
{
connectState = 0;
position = 0;
bindState = 0;
id = 0;
fwVersion = string.Empty;
hwVersion = string.Empty;
sn = string.Empty;
addr = string.Empty;
chargeStatus = 0;
battery = 0;
imuType = 0;
generation = 0;
}
}
[Serializable]
public class SwiftDeviceListWrapper
{
public List<SwiftDevice> SwiftDevices;
}
public partial class JsonParser
{
public static SwiftDevice ParseSwiftDeviceFromJson(string json)
{
try
{
// 使用 Unity 的 JsonUtility 解析 JSON 字符串为 Pose 对象
return JsonUtility.FromJson<SwiftDevice>(json);
}
catch (Exception ex)
{
Debug.LogError($"JSON 解析出错: {ex.Message}");
return null;
}
}
public static List<SwiftDevice> ParseSwiftDeviceArrayFromJson(string json)
{
try
{
// 先解析到包装类
SwiftDeviceListWrapper wrapper = JsonUtility.FromJson<SwiftDeviceListWrapper>(json);
if (wrapper != null && wrapper.SwiftDevices != null)
{
return wrapper.SwiftDevices;
}
return null;
}
catch (Exception ex)
{
Debug.LogError($"JSON 解析出错: {ex.Message}");
return null;
}
}
public static string SwiftDeviceArrayToJson(List<SwiftDevice> devices)
{
try
{
// 创建包装类实例
SwiftDeviceListWrapper wrapper = new SwiftDeviceListWrapper
{
SwiftDevices = devices
};
// 使用 JsonUtility.ToJson 方法将包装类对象转换为 JSON 字符串
return JsonUtility.ToJson(wrapper);
}
catch (Exception ex)
{
Debug.LogError($"对象数组转 JSON 出错: {ex.Message}");
return null;
}
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: a0d01db5d714456bafa586dce096e79d
timeCreated: 1748333820

View File

@@ -0,0 +1,26 @@
namespace Unity.XR.PICO.TOBSupport
{
public class WifiConfiguration
{
public WifiConfiguration(string ssid, string password, bool isClient=true)
{
this.ssid = ssid;
this.password = password;
this.isClient = isClient;
}
public WifiConfiguration()
{
this.ssid = "";
this.password = "";
this.isClient = true;
}
public override string ToString()
{
return $"{nameof(ssid)}: {ssid}, {nameof(password)}: {password}, {nameof(isClient)}: {isClient}";
}
public string ssid;
public string password;
public bool isClient;
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 125a220e1cca49a38fb1bc398371735b
timeCreated: 1727247563

View File

@@ -0,0 +1,23 @@
namespace Unity.XR.PICO.TOBSupport
{
public class WifiDisplayModel
{
public static int STATUS_NOT_CONNECT = -1;
public static int STATUS_NONE = 0;
public static int STATUS_SCANNING = 1;
public static int STATUS_CONNECTING = 2;
public static int STATUS_AVAILABLE = 3;
public static int STATUS_NOT_AVAILABLE = 4;
public static int STATUS_IN_USE = 5;
public static int STATUS_CONNECTED = 6;
public string deviceAddress;
public string deviceName;
public bool isAvailable;
public bool canConnect;
public bool isRemembered;
public int statusCode;
public string status;
public string description;
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 39f5fd05aee2d0047932945fab6f46a1
timeCreated: 1686050281

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 0ec549f2e9b5b3d48bab5cb6bcf28a7e
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: b696a6381610a1f46b9bb9ca74202107
timeCreated: 1685947774

Some files were not shown because too many files have changed in this diff Show More