A method for synchronizing virtual content of MR glasses with a mobile terminal

By using a multi-device collaborative QR code pose estimation and dynamic anchor point update mechanism, combined with a network synchronization framework and RPC scheme, the stability and consistency issues in the synchronization of virtual content between MR glasses and mobile terminals are resolved, achieving a highly immersive real-time collaborative effect.

CN123185394APending Publication Date: 2026-11-27NORTHEASTERN UNIV CHINA
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611332551.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-31
Publication Date
2026-11-27

AI Technical Summary

Technical Problem

Existing technologies for synchronizing virtual content between MR glasses and mobile terminals suffer from problems such as reliance on a stable internet connection, initial deviations caused by changes in ambient lighting, visual drift, asynchronous logical states under complex interactions, and visual jumps caused by network fluctuations, making it difficult to meet the requirements for high immersion and real-time collaboration.

Method used

A multi-device collaborative QR code continuous pose estimation and tracking and spatial anchor point dynamic update mechanism is adopted. The virtual content list is dynamically synchronized through the Unity NGO network synchronization framework. The NetworkTransform component is used for incremental updates. An RPC-based animation synchronization scheme is designed. Visual compensation is combined with IMU inertial navigation and SLAM feature point cloud to ensure the long-term stability of the reference frame and the frame-level consistency of the animation.

Benefits of technology

It achieves long-term stable tracking at the centimeter level in complex environments, eliminates visual jumps, improves immersion and operational accuracy, reduces network bandwidth requirements, and meets data privacy and security requirements in offline scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123185394A_ABST
    Figure CN123185394A_ABST
Patent Text Reader

Abstract

The application provides a kind of MR glasses and virtual content synchronization method of mobile terminal, it is related to MR and distributed network communication technical field.Adopt the sustained tracking and dynamic hierarchical compensation mechanism of multimodal fusion, effectively solve the spatial dislocation and occlusion loss problem under long time operation;Using the RPC mechanism of Unity NGO architecture with delay compensation to realize frame-level animation synchronization, overcome the defect that the complex mechanical motion in traditional underlying protocol scheme is not consistent in multi-terminal display;The application benefits from the built-in scene snapshot recovery and incremental update mechanism, newly added equipment can complete the full state alignment instantly, significantly improve the collaboration efficiency.In addition, the complete localization closed-loop processing capacity of the application not only reduces the demand for network bandwidth and deployment cost, but also fundamentally meets the strict requirements of data privacy and security in offline scenes such as classified industry and military.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the fields of Mixed Reality (MR) and distributed network communication technology, and in particular to a method for synchronizing virtual content between MR glasses and a mobile terminal. Background Technology

[0002] In cloud-based spatial anchor point-based reference frame synchronization schemes, the process typically begins with one device scanning the physical environment, extracting feature point cloud information using technologies such as visual inertial odometry, and uploading it to a cloud server to establish a specific spatial anchor point. Subsequently, other participating mobile terminals or MR devices obtain the data packet for this anchor point by accessing the cloud API, and perform feature search and comparison in real-time images captured by their local cameras. Once a match is found, the system can map the independent local coordinate systems of each device to a unified cloud coordinate system, thereby achieving alignment of virtual content in physical space.

[0003] In local reference frame alignment schemes based on single QR code recognition, developers typically place a pre-defined printed QR code in the physical environment as a spatial anchor. The mobile terminal and MR glasses capture this image using their respective cameras, and the image tracking algorithm built into the AR underlying framework calculates the camera's real-time pose data relative to the QR code's center point. By forcibly setting the physical position of this QR code as the global origin of the virtual world, all devices that have scanned the same QR code can establish a unified local coordinate reference frame, thereby achieving consistency in the initial spatial position of virtual objects across multiple camera perspectives.

[0004] After spatial reference frame alignment is completed, existing synchronization schemes typically rely on custom data transmission protocols based on sockets (such as TCP or UDP). This involves manually writing the underlying communication logic to encapsulate and unpack transformation data such as coordinates, rotations, and scaling of virtual objects. Systems often employ a simple master-slave architecture or message broadcasting mechanism. The master device captures pose changes in the virtual content and distributes update commands to other collaborating terminals. Upon receiving the commands, each terminal updates the spatial position of the corresponding virtual model in real time using local scripts, thus maintaining a basic convergence of visual representation on each device screen.

[0005] Synchronization schemes based on cloud-based spatial anchors heavily rely on stable internet connections and the responsiveness of cloud services. They are often unusable in offline environments, areas with weak network connectivity, or private scenarios with extremely high data privacy requirements. Furthermore, the significant physical latency in uploading, processing, and distributing environmental feature points makes it difficult to achieve real-time synchronization of spatial locations between devices with extremely low latency. In addition, for single scenes lacking texture features or environments with drastic lighting changes, the success rate of anchor matching and positioning accuracy will drop significantly, making it difficult to guarantee the stability of virtual content during long-term, high-intensity collaborative interactions.

[0006] Local alignment schemes based on single QR code recognition are highly dependent on the instantaneous accuracy of visual capture. Changes in ambient lighting, tilted shooting angles, or small QR code sizes can easily lead to initial deviations in the coordinate systems established by different devices. Furthermore, these deviations accumulate and cause severe "drifting" as the user moves further. In addition, simple QR code alignment only solves the problem of static spatial overlap, lacking depth detection technology to calibrate visual distance differences between different devices. Moreover, the lack of mature network synchronization protocols makes it difficult to maintain cross-device consistency for complex logic such as model lists and animator states in real-time during subsequent interactions, failing to meet the demands of highly immersive real-time collaboration.

[0007] Beyond spatial pose synchronization, complex distributed scenarios also involve real-time unification of "logical states." Existing lightweight alignment solutions lack mature network object lifecycle management and automatic state snapshot mechanisms. The system struggles to maintain a dynamic list of virtual 3D models across devices in real time, and is prone to data lag or state asynchrony when handling complex animation states and logical triggers within the models. Furthermore, because these underlying solutions typically lack robust access control mechanisms, network jitter compensation, and smooth interpolation algorithms, virtual content often exhibits noticeable jumps and flickering when facing network fluctuations. Moreover, given the completely different underlying architectures of MR glasses and mobile devices, developers must invest significant resources in redundant cross-platform adaptation, resulting in extremely poor system scalability and an inability to meet the demands of highly immersive real-time collaboration. Summary of the Invention

[0008] The technical problem to be solved by the present invention is to provide a method for synchronizing virtual content between MR glasses and mobile terminals, which does not rely on a one-time initial alignment, but ensures the long-term stability of the reference frame through a multi-device collaborative QR code continuous pose estimation and tracking and a dynamic update mechanism for spatial anchor points.

[0009] To solve the above-mentioned technical problems, the technical solution adopted by the present invention is as follows: A method for synchronizing virtual content between MR glasses and mobile terminals is proposed. First, a unified reference system is established across device spaces. Dynamic synchronization of the virtual content list is achieved through the Unity NGO network synchronization framework. For each virtual element in the scene, its pose update is achieved through smooth interpolation based on incremental updates using a NetworkTransform component, ensuring that the position of the virtual 3D model does not visually change during network fluctuations. For complex interaction logic, an animation synchronization scheme based on Remote Procedure Call (RPC) is designed. When the MR glasses or mobile terminal triggers a specific action of the 3D model, a ServerRpc signal is sent to the server. After verifying operation permissions, the server distributes timestamped animation trigger parameters to all terminals via ClientRpc. When the receiving end executes the animation, it automatically calibrates the NormalizedTime parameter of the animator based on network latency, ensuring that the visual performance deviation of each frame is within the millisecond error range when terminals with different computing capabilities play the same complex animation.

[0010] Furthermore, the specific method for establishing a unified reference system across device spaces is as follows: Step 1.1: Terminal environment perception and alignment path routing; Each terminal device perceives its underlying sensor capabilities in real time. If the device supports the native AR Foundation framework, proceed to step 1.2; if the device is a heterogeneous or low-computing-power system, proceed to step 1.3. Step 1.2: Dynamically enhance the alignment path based on the native framework; Step 1.2.1: Polymorphic persistent tracking mechanism; The device enables high-frequency image retrieval to dynamically recognize physical QR codes; whenever the screen scans the QR code again, it automatically updates the current pose offset to compensate for the drift of the visual inertial odometry over time. Step 1.2.2: Spatial anchor point lifecycle binding; The location of the QR code in physical space is encapsulated as a spatial anchor point with lifecycle awareness capabilities, and the state of this spatial anchor point is maintained in real time: Tracking in progress: High-precision pose available; Recovery in progress: After visual loss, the pose is attempted to be recovered using SLAM feature point clouds; Loss: Anchor point failure triggers compensation path; Step 1.3: General calibration path based on visual detection and depth mesh: The device calls the image library, parses it, extracts multi-feature point pixels, converts 2D to 3D ray projection, and realizes spatial mesh collision and pose inverse solution; Step 1.4: Visual vanishing adaptive compensation branch; When it is determined that the QR code is not visible in the current field of view, the compensation strategy is automatically switched according to the duration and status. Step 1.5: Global reference system mapping; Each terminal aligns the virtual content to a preset position in the physical space according to the dynamic poses obtained in real time from the above steps and the principle of constant relative pose. The principle of constant relative pose means that, with the physical QR code coordinate system as the common reference origin across terminals, after obtaining the real-time pose of each terminal's camera relative to the QR code, the position and orientation of the virtual 3D model relative to the QR code are kept fixed, so that the binding relationship between the virtual content and the 3D space of the real physical world remains consistent across all terminals.

[0011] Furthermore, the specific method of step 1.3 is as follows: Step 1.3.1: Multi-feature point pixel extraction; The device calls the ZXing image library integrated locally to parse the video frames and extract the pixel coordinates of the four corner points and the center point of the QR code; Step 1.3.2: Two-dimensional to three-dimensional ray casting; Using the camera intrinsic parameter model, a probe ray is emitted from the camera optical center toward the five pixels determined in step 1.3.1; Step 1.3.3: Spatial mesh collision and pose inverse solution; The intersection of the detection ray and the physical space grid constructed in real time by the MR glasses is determined; by analyzing the distribution of collision points in the local coordinate system of the terminal, the three-dimensional plane equation of the QR code and the three-dimensional coordinates of the center point are fitted; using the plane coordinate system of the QR code as the spatial reference, the translation component is determined by the three-dimensional coordinates of the center point, and the rotation component is constructed by the direction of the plane normal and the line connecting the corner points, thereby deriving the rigid body transformation matrix of the terminal relative to the QR code reference.

[0012] Furthermore, the compensation strategy in step 1.4 specifically includes: Step 1.4.1: Very short-term compensation; when the disappearance duration is lower than the preset threshold, track estimation is performed using IMU data to maintain the instantaneous stability of the coordinate system; Step 1.4.2: Mid-term compensation; When the disappearance time is between the preset threshold time and the upper limit threshold time, the system uses the spatial anchor points recorded in step 1.2.2 to indirectly maintain the logical position of the QR code by utilizing the static features in the physical environment. Step 1.4.3: Long-term failure handling; When the tracking is completely unavailable and cannot be retrieved, the user interface is triggered to guide the user to point the device to a known reference area or rescan the QR code to rebuild the reference frame.

[0013] Furthermore, the animation synchronization scheme is specifically as follows: Step 2.1: Network session initialization and role / permission assignment; Each terminal establishes a connection through the network layer; according to the access order and preset logic, the first device to establish a session is set as the server, and subsequent access devices are set as clients; the server is responsible for the lifecycle management of the global network manager and the uniqueness verification of network objects; Step 2.2: Snapshot recovery mechanism for new device access; When a new device accesses an existing network session, the scene recovery logic is triggered; Step 2.3: Incremental synchronization of the virtual object's basic pose; For each virtual element in the scene, perform layered transformation synchronization; specifically including: Step 2.3.1: 3D transformation synchronization; using network transformation components to monitor the position, rotation, and scaling of virtual objects; Step 2.3.2: Smoothing Interpolation and Prediction Algorithm; To address network jitter, after receiving the pose increment packet from the server, the client uses linear interpolation or spherical interpolation algorithms for smoothing to ensure visual continuity during movement; Step 2.4: Synchronize branching of the condition-triggered animation machine; Automatically detect whether the virtual object has an animation machine component attached. If so, enable the additional synchronization path; otherwise, skip this step. Step 2.5: Dynamic ownership transfer and conflict handling; When multiple users attempt to operate the same virtual 3D model simultaneously, the server allocates permissions according to a predetermined weight strategy. Only the terminal that obtains ownership can modify the network transformation parameters of the virtual 3D model, while the other terminals switch to controlled mode, thereby preventing the virtual content from oscillating in the scene.

[0014] Furthermore, step 2.2 specifically includes: Step 2.2.1: Synchronize list snapshots; The server sends the globally unique identifiers, prefab indexes, and parent-child hierarchical relationships of all activated virtual objects in the current scene to the new client by attaching a global management object with a network list component. Step 2.2.2: Persistent state alignment; Based on the snapshot information, the new client asynchronously instantiates the corresponding virtual element in local memory; at the same time, it uses the initial value synchronization feature of the network variable component to obtain the current non-instantaneous attributes of the virtual 3D model, including material color, hidden state, position, scaling, animation state, and parent-child mounting relationship, to ensure that the scene seen by the newly added terminal is synchronized with the server.

[0015] Furthermore, the specific method for enabling the additional synchronization path in section 2.4 is as follows: Step 2.4.1: Dispatch of remote procedure call instructions; When the interaction triggers the animation, the active client sends a server remote procedure call signal to the server; after verifying the operation permissions, the server broadcasts a client remote procedure call signal with a time sequence label to all clients. Step 2.4.2: Animation playback progress self-calibration; The receiving end automatically calculates the network latency based on the difference between the local timestamp and the command sending timestamp, and adjusts the normalized time parameters of the animation machine accordingly to achieve strong consistency at the animation frame level across devices.

[0016] The beneficial effects of adopting the above technical solutions are as follows: The virtual content synchronization method between MR glasses and mobile terminals provided by this invention employs a multimodal fusion continuous tracking and dynamic hierarchical compensation mechanism, effectively solving the problems of spatial misalignment and occlusion loss during long-term operation. Experiments show that this mechanism achieves centimeter-level long-term stable tracking in complex industrial environments without relying on unstable cloud services, significantly improving the robustness and environmental universality of spatial positioning. This invention utilizes the Unity NGO architecture's latency-compensated RPC mechanism to achieve frame-level animation synchronization, overcoming the defects of inconsistent display of complex mechanical movements across multiple devices in traditional underlying protocol solutions. Tests show that the playback deviation of complex animations between different computing devices is controlled within 30 milliseconds, effectively eliminating visual jumps and greatly enhancing the immersion and operational accuracy in multi-person collaborative scenarios. Thanks to the built-in scene snapshot restoration and incremental update mechanism, newly added devices can instantly complete full state alignment, significantly improving collaborative efficiency. Furthermore, the fully localized closed-loop processing capability of this invention not only reduces the demand for network bandwidth and deployment costs but also fundamentally meets the stringent requirements for data privacy and security in offline scenarios such as classified industries and the military. Attached Figure Description

[0017] Figure 1 A flowchart illustrating the establishment of a unified reference system across device spaces provided in embodiments of the present invention; Figure 2 A flowchart of an animation synchronization scheme provided in an embodiment of the present invention. Detailed Implementation

[0018] The specific embodiments of the present invention will be described in further detail below with reference to the accompanying drawings and examples. The following examples are for illustrative purposes only and are not intended to limit the scope of the invention.

[0019] A method for synchronizing virtual content between MR glasses and a mobile terminal, such as... Figure 1 and Figure 2 As shown, the method of this embodiment is described below.

[0020] The core of the method for cross-device spatial alignment in this embodiment lies in establishing a dynamically enhanced composite coordinate calibration system. This system does not rely on a one-time initial alignment, but rather ensures the long-term stability of the reference system through a multi-device collaborative QR code continuous pose estimation and tracking mechanism and a dynamic update mechanism for spatial anchor points.

[0021] After establishing a unified reference system, the virtual content list is dynamically synchronized using the Unity NGO network synchronization framework. For each virtual element in the scene, its pose update no longer relies on the original Socket byte stream transmission, but instead uses a NetworkTransform component to achieve smooth interpolation based on incremental updates, ensuring that the virtual 3D model's position does not visually jump during network fluctuations. For complex interaction logic, this embodiment designs an animation synchronization scheme based on RPC (Remote Procedure Call). When MR glasses or a mobile terminal triggers a specific action of the model (such as disassembly or rotation animation), a ServerRpc signal is sent to the server. After verifying operation permissions, the server distributes timestamped animation trigger parameters to all terminals via ClientRpc. When the receiving end executes the animation, it automatically calibrates the NormalizedTime parameter of the animator based on network latency, ensuring that the visual performance deviation of each frame is within the millisecond error range when devices with different computing capabilities play the same complex animation, thus meeting the high-fidelity interaction requirements in immersive collaborative scenarios.

[0022] Figure 1 This is the main flowchart of cross-device spatial reference frame alignment and accuracy calibration based on continuous pose estimation of QR codes in this embodiment. Figure 1 As shown, the cross-device space reference frame alignment and accuracy calibration scheme includes the following steps: Step 1.1: Terminal Environment Awareness and Alignment Path Triage. After system startup, each terminal device senses its underlying sensor capabilities in real time. If the device supports the native AR Foundation framework, proceed to Step 1.2; if the device is a heterogeneous or low-computing-power system (such as glasses that only support basic visual recognition), proceed to Step 1.3.

[0023] Step 1.2: Dynamically enhance alignment path based on the native framework: Step 1.2.1: Polymorphic Continuous Tracking Mechanism. The device enables high-frequency image retrieval to dynamically recognize the physical QR code. The system does not perform a one-time alignment but maintains real-time monitoring of the QR code's pose. Whenever the image scans the QR code again, the system automatically updates the current pose offset to compensate for the drift of the visual inertial odometry over time.

[0024] Step 1.2.2: Spatial Anchor Point Lifecycle Binding. The location of the QR code in physical space is encapsulated as a "spatial anchor point" with lifecycle awareness capabilities. The system maintains the status of this anchor point in real time. Tracking in progress: High-precision pose available; Recovery in progress: After visual loss, the pose is attempted to be recovered using SLAM feature point clouds; Loss: Anchor point failure, triggering compensation path.

[0025] Step 1.3: A general calibration path based on visual inspection and depth mesh: Step 1.3.1: Multi-feature point pixel extraction. The device calls the locally integrated ZXing image library to parse the video frames and extract the pixel coordinates of the four corner points and the center point of the QR code.

[0026] Step 1.3.2: 2D to 3D ray projection. Using the camera intrinsic model, a probe ray is emitted from the camera optical center toward the five pixels determined in Step 1.3.1.

[0027] Step 1.3.3: Spatial Mesh Collision and Pose Inverse Solution. The intersection of the probe ray and the physical spatial mesh constructed in real-time by the MR glasses is determined. By analyzing the distribution of collision points in the terminal's local coordinate system, the three-dimensional plane equation of the QR code and the three-dimensional coordinates of its center point are fitted. Using this QR code plane coordinate system as a spatial reference, the translation component is determined by the three-dimensional coordinates of the center point, and the rotation component is constructed by the direction connecting the plane normal and the corner points. Thus, the rigid body transformation matrix of the terminal relative to this QR code reference is derived.

[0028] Step 1.4: Visual Vanishing Adaptive Compensation Branch. When the system determines that the QR code is not visible in the current field of view, it automatically switches the compensation strategy based on the duration and status: Step 1.4.1: Very short-term compensation. When the disappearance time is less than a preset threshold (e.g., 2 seconds), track estimation is performed using IMU data to maintain the instantaneous stability of the coordinate system.

[0029] Step 1.4.2: Mid-term compensation. When the disappearance time is between 2 and 10 seconds, the system uses the spatial anchor points recorded in step 1.2.2 to indirectly maintain the logical position of the QR code by utilizing static features in the physical environment.

[0030] Step 1.4.3: Long-term failure handling. When tracking completely fails and cannot be retrieved, the system triggers a user interface guide, prompting the user to point the device to a known reference area or rescan the QR code to rebuild the reference frame.

[0031] Step 1.5: Global Reference System Mapping. Based on the dynamic poses acquired in real-time from the previous steps, each terminal aligns the virtual content to a preset position in physical space according to the principle of constant relative pose. The principle of constant relative pose means that, using the physical QR code coordinate system as a common reference origin across terminals, after obtaining the real-time pose of each terminal's camera relative to the QR code, the position and orientation of the virtual 3D model relative to the QR code are kept fixed, thus ensuring that the binding relationship between the virtual content and the real physical world's 3D space remains consistent across all terminals.

[0032] Figure 2 This is a flowchart of a virtual content dynamic network synchronization solution, such as... Figure 2 As shown, the technical solution for dynamic synchronization and state consistency of the virtual content list includes the following steps: Step 2.1: Network Session Initialization and Role / Permission Assignment. Each terminal establishes a connection through the network layer. Based on the access order and preset logic, the system designates the first device to establish a session as the server, and subsequent access devices as clients. The server is responsible for the lifecycle management of the global network manager and the uniqueness verification of network objects.

[0033] Step 2.2: Snapshot recovery mechanism for new device access. When a new device accesses an existing network session, the scene recovery logic is triggered: Step 2.2.1: List Snapshot Synchronization. The server sends the globally unique identifiers, prefab indexes, and parent-child hierarchical relationships of all activated virtual objects in the current scene to the new client by attaching a global management object that includes the network list component.

[0034] Step 2.2.2: Persistent State Alignment. Based on the snapshot information, the new client asynchronously instantiates the corresponding virtual element in local memory. Simultaneously, leveraging the initial value synchronization feature of the network variable component, it obtains non-transient attributes of the virtual 3D model, such as its current material color, hidden state, position, scaling, animation state, and parent-child mounting relationships, ensuring that the scene seen by newly added devices is synchronized with the server.

[0035] Step 2.3: Incremental synchronization of virtual object base pose. For each virtual element in the scene, the system performs layered transformation synchronization: Step 2.3.1: 3D Transformation Synchronization. The position, rotation, and scaling of the virtual object are monitored using a network transformation component.

[0036] Step 2.3.2: Smoothing Interpolation and Prediction Algorithm. To address network jitter, after receiving the pose increment packet from the server, the client does not directly jump to the coordinates. Instead, it uses linear interpolation or spherical interpolation algorithms for smoothing to ensure visual continuity during movement.

[0037] Step 2.4: Condition-triggered animate synchronization branch. The system automatically detects whether the virtual object has an animate component attached. If so, an additional synchronization path is enabled: Step 2.4.1: Remote Procedure Call Instruction Distribution. When the interaction triggers the animation, the active client sends a server-side remote procedure call signal to the server. After verifying the operation permissions, the server broadcasts a client-side remote procedure call signal with a time sequence tag to all clients.

[0038] Step 2.4.2: Animation playback progress self-calibration. The receiving end automatically calculates the network latency based on the difference between the local timestamp and the command sending timestamp, and adjusts the normalized time parameters of the animation machine accordingly to achieve strong consistency at the animation frame level across devices.

[0039] Step 2.5: Dynamic Ownership Migration and Conflict Resolution. When multiple users attempt to operate the same virtual 3D model simultaneously, the server allocates permissions according to a predetermined weighting strategy. Only the device that acquires ownership can modify the network transformation parameters of the virtual 3D model; other devices are switched to controlled mode, thereby preventing the virtual content from oscillating in the scene.

[0040] This embodiment constructs a highly robust cross-device spatial reference frame dynamic calibration mechanism, fundamentally solving the pain points of easy drift in static alignment and poor hardware compatibility in existing technologies. Its core breakthrough is to abandon the single alignment mode and adopt a multi-modal fusion continuous tracking strategy to correct inertial accumulation errors in real time, and to introduce a spatial anchor point lifecycle state machine to cope with environmental changes. For heterogeneous low-computing-power devices, a general depth calibration algorithm based on two-dimensional feature extraction combined with collision and intersection of three-dimensional rays and physical space mesh is proposed, which can achieve high-precision pose inverse solution without dedicated hardware. In addition, a hierarchical visual loss adaptive compensation mechanism including IMU inertial navigation calculation, SLAM environmental feature maintenance and interactive relocalization is designed to ensure the continuous stability of the spatial reference in complex industrial occlusion environments.

[0041] This embodiment implements a high-fidelity distributed virtual content state synchronization architecture, solving the problem of inconsistency between logic and visuals under complex interactions. Its highlights include the implementation of frame-level animation synchronization technology based on timestamps and latency compensation. By dynamically calibrating the normalized time parameters of the animator, it ensures millisecond-level visual consistency of complex mechanical movements under different network environments. Simultaneously, it provides a robust scene snapshot recovery mechanism, enabling later-added devices to instantly align with the scene through global state serialization. Finally, it introduces permission granting and migration strategies to effectively manage operation permissions under high concurrency of multiple users, fundamentally preventing virtual object position oscillations caused by interaction conflicts.

[0042] To verify the effectiveness of the method in this embodiment, a local area network environment consisting of one MR glasses and two mobile terminals was built, and comparative tests were conducted in an industrial simulation scene of approximately 8m × 6m. A 30-minute continuous spatial stability test showed that, compared to single-cycle QR code alignment schemes, the method in this embodiment maintained an average positional deviation of 1.5–3.0 cm, achieving centimeter-level long-term tracking. Fifty animation synchronization tests showed that, under network jitter of approximately 20–50 ms, the average deviation of complex animation playback between heterogeneous devices was approximately 18–25 ms, with a maximum of no more than 30 ms. When a new device is connected, scene snapshots can complete full state alignment within approximately 1 second. The results indicate that the method in this embodiment can meet offline collaboration requirements without cloud access.

[0043] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features therein. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope defined by the present invention.

Claims

1. A method for synchronizing virtual content between MR glasses and a mobile terminal, characterized in that: First, a unified reference system is established across device space, and the virtual content list is dynamically synchronized through the Unity NGO network synchronization framework. For each virtual element in the scene, its pose update is achieved by mounting the NetworkTransform component to realize smooth interpolation based on incremental updates, ensuring that the position of the virtual 3D model will not visually change when the network fluctuates. To address complex interaction logic, a remote procedure call-based animation synchronization solution is designed. When MR glasses or mobile terminals trigger specific actions of the 3D model, a ServerRpc signal is sent to the server. After verifying the operation permissions, the server distributes animation trigger parameters with timestamps to all terminals via ClientRpc. When the receiving end executes the animation, it automatically calibrates the NormalizedTime parameter of the animation machine according to the network latency to ensure that the visual performance deviation of each frame of terminals with different computing capabilities is within the millisecond error range when playing the same complex animation.

2. The method for synchronizing virtual content between MR glasses and a mobile terminal according to claim 1, characterized in that: The specific method for establishing a unified reference system across device spaces is as follows: Step 1.1: Terminal environment perception and alignment path routing; Each terminal device perceives its underlying sensor capabilities in real time. If the device supports the native AR Foundation framework, proceed to step 1.2; if the device is a heterogeneous or low-computing-power system, proceed to step 1.

3. Step 1.2: Dynamically enhance alignment path based on the native framework; Step 1.2.1: Polymorphic persistent tracking mechanism; The device enables high-frequency image retrieval to dynamically recognize physical QR codes; whenever the screen scans the QR code again, it automatically updates the current pose offset to compensate for the drift of the visual inertial odometry over time. Step 1.2.2: Spatial anchor point lifecycle binding; The location of the QR code in physical space is encapsulated as a spatial anchor point with lifecycle awareness capabilities, and the state of this spatial anchor point is maintained in real time: Tracking in progress: High-precision pose available; Recovery in progress: After visual loss, the pose is attempted to be recovered using SLAM feature point clouds; Loss: Anchor point failure triggers compensation path; Step 1.3: General calibration path based on visual detection and depth mesh: The device calls the image library, parses it, extracts multi-feature point pixels, converts 2D to 3D ray projection, and realizes spatial mesh collision and pose inverse solution; Step 1.4: Visual vanishing adaptive compensation branch; When it is determined that the QR code is not visible in the current field of view, the compensation strategy is automatically switched according to the duration and status. Step 1.5: Global reference system mapping; Each terminal aligns the virtual content to a preset position in the physical space according to the dynamic poses obtained in real time from the above steps and the principle of constant relative pose. The principle of constant relative pose means that, with the physical QR code coordinate system as the common reference origin across terminals, after obtaining the real-time pose of each terminal's camera relative to the QR code, the position and orientation of the virtual 3D model relative to the QR code are kept fixed, so that the binding relationship between the virtual content and the 3D space of the real physical world remains consistent across all terminals.

3. The method for synchronizing virtual content between MR glasses and a mobile terminal according to claim 2, characterized in that: The specific method for step 1.3 is as follows: Step 1.3.1: Multi-feature point pixel extraction; The device calls the ZXing image library integrated locally to parse the video frames and extract the pixel coordinates of the four corner points and the center point of the QR code; Step 1.3.2: Two-dimensional to three-dimensional ray casting; Using the camera intrinsic parameter model, a probe ray is emitted from the camera optical center toward the five pixels determined in step 1.3.1; Step 1.3.3: Spatial mesh collision and pose inverse solution; The intersection of the detection ray and the physical space grid constructed in real time by the MR glasses is determined; by analyzing the distribution of collision points in the local coordinate system of the terminal, the three-dimensional plane equation of the QR code and the three-dimensional coordinates of the center point are fitted; using the plane coordinate system of the QR code as the spatial reference, the translation component is determined by the three-dimensional coordinates of the center point, and the rotation component is constructed by the direction of the plane normal and the line connecting the corner points, thereby deriving the rigid body transformation matrix of the terminal relative to the QR code reference.

4. The method for synchronizing virtual content between MR glasses and a mobile terminal according to claim 2, characterized in that: The compensation strategy in step 1.4 specifically includes: Step 1.4.1: Very short-term compensation; when the disappearance duration is lower than the preset threshold, track estimation is performed using IMU data to maintain the instantaneous stability of the coordinate system; Step 1.4.2: Mid-term compensation; When the disappearance time is between the preset threshold time and the upper limit threshold time, the system uses the spatial anchor points recorded in step 1.2.2 to indirectly maintain the logical position of the QR code by utilizing the static features in the physical environment. Step 1.4.3: Long-term failure handling; When the tracking is completely unavailable and cannot be retrieved, the user interface is triggered to guide the user to point the device to a known reference area or rescan the QR code to rebuild the reference frame.

5. The method for synchronizing virtual content between MR glasses and a mobile terminal according to claim 1, characterized in that: The animation synchronization scheme is as follows: Step 2.1: Network session initialization and role / permission assignment; Each terminal establishes a connection through the network layer; according to the access order and preset logic, the first device to establish a session is set as the server, and subsequent access devices are set as clients; the server is responsible for the lifecycle management of the global network manager and the uniqueness verification of network objects; Step 2.2: Snapshot recovery mechanism for new device access; When a new device accesses an existing network session, the scene recovery logic is triggered; Step 2.3: Incremental synchronization of the virtual object's basic pose; For each virtual element in the scene, perform layered transformation synchronization; specifically including: Step 2.3.1: Synchronize three-dimensional transformation; The position, rotation, and scaling of virtual objects can be monitored using network transformation components. Step 2.3.2: Smoothing Interpolation and Prediction Algorithm; To address network jitter, after receiving the pose increment packet from the server, the client uses linear interpolation or spherical interpolation algorithms for smoothing to ensure visual continuity during movement; Step 2.4: Synchronize branching of the condition-triggered animation machine; Automatically detect whether the virtual object has an animation machine component attached. If so, enable the additional synchronization path; otherwise, skip this step. Step 2.5: Dynamic ownership transfer and conflict handling; When multiple users attempt to operate the same virtual 3D model simultaneously, the server allocates permissions according to a predetermined weight strategy. Only the terminal that obtains ownership can modify the network transformation parameters of the virtual 3D model, while the other terminals switch to controlled mode, thereby preventing the virtual content from oscillating in the scene.

6. The method for synchronizing virtual content between MR glasses and a mobile terminal according to claim 5, characterized in that: Step 2.2 specifically includes: Step 2.2.1: Synchronize list snapshots; The server sends the globally unique identifiers, prefab indexes, and parent-child hierarchical relationships of all activated virtual objects in the current scene to the new client by attaching a global management object with a network list component. Step 2.2.2: Persistent state alignment; Based on the snapshot information, the new client asynchronously instantiates the corresponding virtual element in local memory; at the same time, it uses the initial value synchronization feature of the network variable component to obtain the current non-instantaneous attributes of the virtual 3D model, including material color, hidden state, position, scaling, animation state, and parent-child mounting relationship, to ensure that the scene seen by the newly added terminal is synchronized with the server.

7. The method for synchronizing virtual content between MR glasses and a mobile terminal according to claim 5, characterized in that: The specific method for enabling the additional synchronization path in section 2.4 is as follows: Step 2.4.1: Dispatch of remote procedure call instructions; When the interaction triggers the animation, the active client sends a server remote procedure call signal to the server; after verifying the operation permissions, the server broadcasts a client remote procedure call signal with a time sequence label to all clients. Step 2.4.2: Animation playback progress self-calibration; The receiving end automatically calculates the network latency based on the difference between the local timestamp and the command sending timestamp, and adjusts the normalized time parameters of the animation machine accordingly to achieve strong consistency at the animation frame level across devices.