VR application starting method and VR equipment

By turning on the slam function after the VR device is on until it is turned off, the process of frequently starting and closing the slam function is avoided, and the problem of slow startup speed of the 6dof VR device application is solved and the user experience is improved.

CN119201258APending Publication Date: 2024-12-27HISENSE VISUAL TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310754723.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-06-25
Publication Date
2024-12-27

AI Technical Summary

Technical Problem

6dof VR devices need to frequently start and close the slam function when starting and switching applications, resulting in slower application startup speed and poor user experience.

Method used

Turn on the slam function after the VR device is started for the first time and it will not be turned off until the screen is turned off, avoiding repeated execution of the slam function opening and closing process every time the application is started and switched.

Benefits of technology

Reduces the startup time of applications in 6dof VR devices, improves the startup speed of VR applications, and improves the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119201258A_ABST
    Figure CN119201258A_ABST
Patent Text Reader

Abstract

The invention provides a VR application starting method and VR equipment. The VR application starting method is used for improving the VR application starting speed. Comprising the steps that after the VR equipment is powered on and a screen turn-on instruction is received, if it is determined that an obtained screen state value is a first state value, an slam function is started, a VR mode state value is set to be a first mode value, the screen state value is used for indicating whether a screen of the VR equipment is turned on or not, and the VR mode state value is used for indicating whether the slam function of the VR equipment is started or not; the first mode value is used for representing that the slam function of the VR equipment is started; if the instruction of starting the target application is received, rendering and displaying the content of the target application based on a real-time screen action instruction of the user to the target application until a target application exit instruction is received; and when a screen turn-off instruction is received and the obtained screen state value is a second state value, turning off the sla m function, and setting the VR mode state value as a second mode value.
Need to check novelty before this filing date? Find Prior Art

Description

Background Art

[0002] Generally speaking, the faster the VR application starts, the better the user experience. Currently, mainstream VR (Virtual Reality) applications are developed using Unity. If the model in the application is complex, the VR application startup is slower than pure 2D (Two Dimensional) applications. As a 6Dof (six degrees of freedom) VR application, not only model loading but also slam (Simultaneous Localization and Mapping) startup must be considered, because after the application is started, the 6Dof pose needs to be used normally, which requires slam to be started normally.

[0003] At present, 6dof VR devices usually use the SLAM function based on the CV (Computer Vision) solution. The SLAM function based on the CV solution usually requires a lot of calculations and data processing, and each VR application startup and exit, as well as switching to the next VR application, requires the process of starting the SLAM function and the process of closing the SLAM function. This process takes some time, so it will cause users to start applications from the desktop slowly when using 6dof VR devices, resulting in a poor user experience. Summary of the invention

[0004] The present application provides a method for starting a VR application and a VR device, which are used to increase the startup speed of the VR application and improve the user experience.

[0005] In a first aspect, an embodiment of the present application provides a method for starting an application, the method comprising:

[0006] When the VR device is powered on and receives a screen-on instruction, a screen status value of the VR device is obtained, wherein the screen status value is used to indicate whether the screen of the VR device has been turned on;

[0007] If it is determined that the screen status value is the first status value, the real-time positioning and map building slam function is turned on, and the VR mode status value is set to the first mode value, wherein the first status value is used to indicate that the screen of the VR device has been lit, the VR mode status value is used to indicate whether the VR device has turned on the slam function, and the first mode value is used to indicate that the VR device has turned on the slam function;

[0008] If a command to start a target application is received from a user, a real-time screen action command of the user on the target application is obtained, and based on the real-time screen action command, the target application content corresponding to the real-time screen action command is rendered and displayed, until a target application exit command sent by the user is received, the target application is exited;

[0009] When a screen-off instruction is received and the acquired screen status value is the second status value, the slam function of the VR device is turned off, and the VR mode status value is set to the second mode value, wherein the second mode value is used to indicate that the slam function of the VR device has been turned off.

[0010] A second aspect of the present application provides a VR device, including a processor and a memory, wherein the processor and the memory are connected via a bus;

[0011] The memory stores a computer program, and the processor is configured to perform the following operations based on the computer program:

[0012] When the VR device is powered on and receives a screen-on instruction, a screen status value of the VR device is obtained, wherein the screen status value is used to indicate whether the screen of the VR device has been turned on;

[0013] If it is determined that the screen status value is the first status value, the real-time positioning and map building slam function is turned on, and the VR mode status value is set to the first mode value, wherein the first status value is used to indicate that the screen of the VR device has been lit, the VR mode status value is used to indicate whether the VR device has turned on the slam function, and the first mode value is used to indicate that the VR device has turned on the slam function;

[0014] If a command to start a target application is received from a user, a real-time screen action command of the user on the target application is obtained, and based on the real-time screen action command, the target application content corresponding to the real-time screen action command is rendered and displayed, until a target application exit command sent by the user is received, the target application is exited;

[0015] When a screen-off instruction is received and the acquired screen status value is the second status value, the slam function of the VR device is turned off, and the VR mode status value is set to the second mode value, wherein the second mode value is used to indicate that the slam function of the VR device has been turned off.

[0016] According to a third aspect provided by an embodiment of the present invention, a computer storage medium is provided, wherein the computer storage medium stores a computer program, and the computer program is used to execute the method as described in the first aspect.

[0017] In the above embodiment of the present application, the slam function is turned on after the screen is first lit after the VR device is started, and the slam function is not turned off until the screen of the VR device is turned off. During this period, the slam function is always turned on, so no matter whether it is starting or exiting an application or switching an application, it is not necessary to execute the process of turning on the slam function and the process of turning off the slam function every time, so the startup time of the application in the 6dof VR device is reduced and the startup speed of the VR application is improved. BRIEF DESCRIPTION OF THE DRAWINGS

[0018] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.

[0019] Figure 1 The flowchart of the startup scenario of the VR application in the prior art provided by the embodiment of the present application is exemplified;

[0020] Figure 2 A flowchart of a method for starting a VR application provided in an embodiment of the present application is exemplified;

[0021] Figure 3 The flowchart of the control scenario of starting a VR application provided by an embodiment of the present application is exemplarily shown;

[0022] Figure 4 A schematic diagram of a process for starting a VR application provided in an embodiment of the present application is exemplified;

[0023] Figure 5 A schematic diagram of a device for starting a VR application provided in an embodiment of the present application is exemplarily shown;

[0024] Figure 6 The hardware structure diagram of the electronic VR device provided in the embodiment of the present application is exemplified. DETAILED DESCRIPTION

[0025] In order to make the purpose, implementation mode and advantages of the present application clearer, the exemplary implementation mode of the present application will be clearly and completely described below in conjunction with the drawings in the exemplary embodiments of the present application. Obviously, the described exemplary embodiments are only part of the embodiments of the present application, rather than all the embodiments.

[0026] Based on the exemplary embodiments described in this application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the claims attached to this application. In addition, although the disclosure in this application is introduced according to one or several exemplary examples, it should be understood that each aspect of the disclosure can also constitute a complete implementation method separately.

[0027] It should be noted that the brief description of terms in this application is only for the convenience of understanding the embodiments described below, and is not intended to limit the embodiments of this application. Unless otherwise specified, these terms should be understood according to their common and usual meanings.

[0028] The terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the numbers used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover but not exclude inclusion, for example, a product or device comprising a series of components is not necessarily limited to those components clearly listed, but may include other components not clearly listed or inherent to these products or devices.

[0029] The term "module" as used in this application refers to any known or later developed hardware, software, firmware, artificial intelligence, fuzzy logic or combination of hardware and / or software code that is capable of performing the functions associated with that element.

[0030] The idea of ​​the embodiments of the present application is summarized below.

[0031] At present, the startup and exit of each VR application in the 6dof VR device requires the process of starting and closing the slam function when switching to the next application. This process usually takes some time, which results in a slow speed for users to start applications from the desktop when using the 6dof VR device, and a poor user experience. For example, when the user starts VR application 1, the slam function needs to be started. When VR application 1 is closed or running in the background, the slam function is turned off. When the user starts VR application 2, the slam function is started. When VR application 2 is closed or running in the background, the slam function is turned off. Therefore, each time an application is opened, the slam function needs to be restarted, and when the application is exited, the slam function needs to be turned off, resulting in a long time for application startup and a slow application startup speed.

[0032] like Figure 1 As shown, it is a schematic diagram of a scene for starting a VR application in the prior art. Figure 1 It can be seen that when a VR application in the prior art is started, the sxrInitialize method in the SDK (Software Development Kit) corresponding to the VR application is first called for initialization, and then the SDK calls the QVRServiceClient_Create method in the QVR (Qualcomm Virtual Reality) service to connect to the QVR service. Then after the VR application is started (application onResume or focus), the VR application calls the sxrBeginXr method in the SDK, and the QVRServiceClient_StartVRMode method of the QVR service is called in the sxrBeginXr in the SDK to notify the QVR service to turn on the SLAM function. Since it takes time to start the SLAM function, the sxrBeginXr method will block and wait during the startup until the SLAM function is started. When the VR application exits (that is, when the application onPause loses focus), the VR application calls the sxrEndXr method so that the sxrEndXr method in the SDK calls the QVRServiceClient_StopVRMode method in the QVR service to notify the QVR service to turn off the SLAM function. However, it also takes time to turn off the slam function. During the shutdown period, the sxrEnd method will block and wait until the slam function is turned off. Therefore, in the prior art, each time an application is started or switched, it needs to be executed once. Figure 1 The process in will cause the VR application to start slowly.

[0033] Based on the problem of slow startup speed of VR applications in the prior art, the embodiment of the present application provides a method for starting a VR application, which turns on the slam function after the screen is turned on for the first time after the VR device is started, and turns off the slam function until the screen of the VR device is turned off. During this period, the slam function is always turned on, so whether it is starting or exiting an application or switching applications, it is not necessary to execute the process of turning on the slam function and the process of turning off the slam function every time, so the startup time of the application in the 6dof VR device is reduced and the startup speed of the VR application is improved.

[0034] Below, the method for starting the VR application in this application is introduced in detail with reference to the accompanying drawings.

[0035] like Figure 2 FIG. 1 is a flow chart of a method for starting a VR application, which may include the following steps:

[0036] Step 201: When the VR device is powered on and receives a screen-on instruction, a screen status value of the VR device is obtained, wherein the screen status value is used to indicate whether the screen of the VR device has been turned on;

[0037] To ensure that the VR application can be started smoothly, after the VR device is powered on and before receiving the screen-on command, in one embodiment, a connection is established between the display synthesis system SurfaceFlinger service and the virtual reality mode control VrmodeControl service, and the VrmodeControl service is connected to the Qualcomm virtual reality qvr service.

[0038] In one embodiment, the screen status value of the VR device is obtained in the following manner: the screen status value is obtained through the SurfaceFlinger service of the display synthesis system.

[0039] Among them, in the embodiment of the present application, the screen status value is obtained by the setPowerModelntrenal method in the SurfaceFlinger service. However, in the embodiment of the present application, the method for obtaining the screen status value is not limited, and it can be set according to the actual situation.

[0040] Step 202: If it is determined that the screen status value is the first status value, the real-time positioning and map building slam function is enabled, and the VR mode status value is set to the first mode value, wherein the first status value is used to indicate that the screen of the VR device has been lit, the VR mode status value is used to indicate whether the VR device has enabled the slam function, and the first mode value is used to indicate that the VR device has enabled the slam function;

[0041] In one embodiment, the real-time positioning and map building slam function is enabled in the following manner, and the VR mode state value is set to the first mode value:

[0042] The SurfaceFlinger service sends a positioning start instruction to the virtual reality mode control VrmodeControl service, so that the VrmodeControl service instructs the Qualcomm virtual reality QVR service to turn on the slam function based on the positioning start instruction and sets the VR mode state value to the first mode value.

[0043] Step 203: if a command to start the target application is received from the user, the real-time screen action command of the user for the target application is obtained, and the target application content corresponding to the real-time screen action command is rendered and displayed based on the real-time screen action command, until a target application exit command sent by the user is received, then the target application is exited;

[0044] Among them, obtaining real-time screen action instructions in the implementation of this application is obtained by obtaining pose.

[0045] In order to ensure that the VR application can be started smoothly, in one embodiment, after receiving the instruction sent by the user to start the target application, the SDK of the target application is connected to the QVR service. And before obtaining the real-time screen action instruction of the user for the target application, the VR mode state value is determined to be the first mode value.

[0046] In one embodiment, the VR mode state value is obtained in the following manner:

[0047] The VR mode status value is obtained from Qualcomm Virtual Reality QVR service through the software development kit SDK of the target application.

[0048] In order to save computing resources, in one embodiment, after receiving the target application exit instruction sent by the user, the SDK of the target application is disconnected from the QVR service.

[0049] In one embodiment, the target application exit instruction includes ending the process of the target application or switching the process of the target application to background operation.

[0050] Step 204: When a screen-off instruction is received and the acquired screen status value is the second status value, the slam function of the VR device is turned off, and the VR mode status value is set to the second mode value, wherein the second mode value is used to indicate that the slam function of the VR device has been turned off.

[0051] In one embodiment, the positioning function of the VR device is turned off and the VR mode state value is set to the second mode value in the following manner:

[0052] A positioning shutdown instruction is sent to the VrmodeControl service through the SurfaceFlinger service, so that the VrmodeControl service instructs the qvr service to shut down the slam function based on the positioning shutdown instruction and sets the VR mode state value to the second mode value.

[0053] The following is a detailed description of the control process in the VR application startup method in the embodiment of the present application. Figure 3 As shown, the control process for starting a VR application in a VR device may include the following steps:

[0054] Step 301: When the VR device is powered on, the SurfaceFlinger service in the VR device establishes a connection with the VrmodeControl service in the VR device;

[0055] The SurfaceFlinger service in the embodiment of the present application establishes a connection with the VrmodeControl service by calling the HxrControllerClient_Create method.

[0056] Step 302: The VrmodeControl service in the VR device establishes a connection with the qvr service in the VR device in the VR device;

[0057] The VrmodeControl service in the embodiment of the present application establishes a connection with the qvr service by calling the QVRServiceClient_Create method.

[0058] It should be noted that the method of establishing a connection between the SurfaceFlinger service and the VrmodeControl service and the method of establishing a connection between the VrmodeControl service and the qvr service described above in the embodiment of the present application are only used for illustration and do not limit the method of establishing a connection. The specific method of establishing a connection can be set according to actual conditions.

[0059] Step 303: After receiving the screen-on instruction, the SurfaceFlinger service obtains the screen status value and determines that the screen status value is a first status value;

[0060] Step 304: The SurfaceFlinger service sends a positioning start instruction to the virtual reality mode control VrmodeControl service;

[0061] In the embodiment of the present application, the SurfaceFlinger service sends a positioning start instruction to the VrmodeControl service by calling the HxrControllerClient_Start method. The specific method of sending the instruction can be set according to the actual situation, and the embodiment of the present application is not limited here.

[0062] Step 305: The VrmodeControl service instructs the Qualcomm virtual reality qvr service to enable the slam function based on the positioning enable instruction;

[0063] The VrmodeControl service in the embodiment of the present application sends an instruction to the qvr service to enable the slam function by calling the QVRServiceClient_StartVRMode method. However, the specific method can be set according to the actual situation, and the embodiment of the present application is not limited here.

[0064] Step 306: After receiving the positioning start instruction, the qvr service starts the slam function and sets the VR mode state value to the first mode value;

[0065] Step 307: After receiving the screen off instruction, the SurfaceFlinger service obtains the screen status value;

[0066] Step 308: The SurfaceFlinger service determines that the screen status value is the second mode value, and sends a positioning close instruction to the VrmodeControl service;

[0067] In the implementation of this application, the first mode value is 2, and the second mode value is 0, but the first mode value and the second mode value can be set according to specific actual conditions. The embodiment of this application does not limit the first mode value and the second mode value.

[0068] Step 309: The VrmodeControl service instructs the qvr service to turn off the slam function based on the positioning shutdown instruction;

[0069] Step 310: After receiving the positioning shutdown instruction, the qvr service turns off the slam function and sets the VR mode state value to the second mode value.

[0070] In order to further connect the method in this application, the method for starting the VR application in this application is introduced in combination with the usage scenario. Figure 4 As shown, it is a schematic diagram of the process of starting the use scenario of the VR application in this application, which may include the following steps:

[0071] Step 401: When the target application in the VR device is started, the target application is initialized;

[0072] The method of initialization in the embodiment of the present application is to call the sxrlnitialize method in the SDK of the target application to initialize. However, the embodiment of the present application does not limit the method of initialization, and it can be set according to the specific actual situation.

[0073] Step 402: the SDK calls the QVRServiceClient_Create method in the QVR service to connect to the QVR service;

[0074] Step 403: After the target application is started, the sxrBeginXr method of the SDK of the target VR application is called;

[0075] Step 404: SDK calls the QVRServiceClient_GetVRMode method of the qvr service through the sxrBeginXr method to obtain the VR mode status value;

[0076] Step 405: The qvr service sends the VR mode status value to the sdk;

[0077] Step 406: The SDK determines that the VR mode state value is the first mode value;

[0078] Step 407: the target application obtains the real-time screen action instruction of the user to the target application, and renders and displays the target application content corresponding to the real-time screen action instruction based on the real-time screen action instruction;

[0079] Step 408: When the target VR application exits, the sxrEndXr method of the SDK is called;

[0080] Step 409: SDK calls the QVRServiceClient_GetVRMode method of the qvr service through the sxrEndXr method to obtain the VR mode status value;

[0081] Step 410: the qvr service sends the VR mode status value to the sdk;

[0082] Step 411: The SDK determines that the VR mode state value is the first mode value;

[0083] Step 412: The target application calls the sxrShutdown method of the SDK;

[0084] Step 413: The SDK calls the QVRServiceClient_Destroy method of the QVR service to disconnect from the QVR service.

[0085] Based on the same inventive concept, the VR application startup method disclosed above can also be implemented by a VR application startup device. The effect of the VR application startup device is similar to that of the aforementioned method, and will not be repeated here.

[0086] Figure 5 The figure is a schematic diagram of the structure of a device for starting a VR application according to an embodiment of the present disclosure.

[0087] like Figure 5The VR application startup device 500 of the present disclosure may include a screen status value acquisition module 510, a slam function activation module 520, an application rendering module 530 and a slam function deactivation module 540.

[0088] The screen status value acquisition module 510 is used to acquire the screen status value of the VR device when the VR device is powered on and receives a screen-on instruction, wherein the screen status value is used to indicate whether the screen of the VR device has been turned on;

[0089] A slam function enabling module 520 is configured to enable the real-time positioning and map building slam function if it is determined that the screen state value is a first state value, and to set the VR mode state value to a first mode value, wherein the first state value is used to indicate that the screen of the VR device has been lit, the VR mode state value is used to indicate whether the VR device has enabled the slam function, and the first mode value is used to indicate that the VR device has enabled the slam function;

[0090] The application rendering module 530 is used to, if receiving an instruction to start a target application sent by a user, obtain the real-time screen action instruction of the user for the target application, and render and display the target application content corresponding to the real-time screen action instruction based on the real-time screen action instruction, until receiving an exit instruction of the target application sent by the user, then exit the target application;

[0091] The slam function closing module 540 is used to close the slam function of the VR device and set the VR mode state value to the second mode value when a screen-off instruction is received and the screen state value obtained is a second state value, wherein the second mode value is used to indicate that the slam function of the VR device has been closed.

[0092] In one embodiment, the screen status value acquisition module 510 is specifically used to:

[0093] Obtain the screen status value through the display synthesis system surfaceFlinger service;

[0094] The SLAM function activation module 520 is specifically used for:

[0095] Sending a positioning start instruction to the virtual reality mode control VrmodeControl service through the SurfaceFlinger service, so that the VrmodeControl service instructs the Qualcomm virtual reality QVR service to turn on the slam function based on the positioning start instruction, and sets the VR mode state value to the first mode value;

[0096] The SLAM function closing module 540 is specifically used for:

[0097] A positioning shutdown instruction is sent to the VrmodeControl service through the SurfaceFlinger service, so that the VrmodeControl service instructs the qvr service to shut down the slam function based on the positioning shutdown instruction and sets the VR mode state value to the second mode value.

[0098] In one embodiment, the apparatus further comprises:

[0099] The first communication connection module 550 is used to establish a connection between the SurfaceFlinger service and the VrmodeControl service, and to establish a connection between the VrmodeControl service and the qvr service after determining that the system of the VR device is started and before receiving a screen-on instruction.

[0100] In one embodiment, the apparatus further comprises:

[0101] The VR mode state value determination module 560 is used to determine that the VR mode state value is a first mode value before obtaining the real-time screen action instruction of the user for the target application.

[0102] In one embodiment, the VR mode state value determination module 560 is further configured to:

[0103] The VR mode status value is obtained by:

[0104] The VR mode status value is obtained from Qualcomm Virtual Reality QVR service through the software development kit SDK of the target application.

[0105] In one embodiment, the apparatus further comprises:

[0106] The second communication connection module 570 is used to establish a connection between the SDK of the target application and the QVR service after receiving an instruction to start the target application sent by the user;

[0107] The communication disconnection module 580 is used to disconnect the SDK of the target application from the QVR service after receiving the target application exit instruction sent by the user.

[0108] In one embodiment, the target application exit instruction includes ending the process of the target application or switching the process of the target application to background operation.

[0109] After introducing a method and apparatus for starting a VR application according to an exemplary embodiment of the present invention, a VR device according to another exemplary embodiment of the present invention is introduced next.

[0110] It will be appreciated by those skilled in the art that various aspects of the present invention may be implemented as a system, method or program product. Therefore, various aspects of the present invention may be specifically implemented in the following forms, namely: a complete hardware implementation, a complete software implementation (including firmware, microcode, etc.), or a combination of hardware and software, which may be collectively referred to herein as a "circuit", "module" or "system".

[0111] In some possible implementations, the VR device according to the present invention may include at least one processor and at least one computer storage medium. The computer storage medium stores program code, and when the program code is executed by the processor, the processor executes the steps in the method for starting a VR application according to various exemplary embodiments of the present invention described above in this specification. For example, the processor may execute the following steps: Figure 2 Steps 201-204 shown in .

[0112] Refer to the following Figure 6 The VR device 600 according to this embodiment of the present invention is described. Figure 6 The VR device 600 shown is merely an example and should not limit the functions and scope of use of the embodiments of the present invention.

[0113] like Figure 6 As shown, the VR device 600 is presented in the form of a general VR device. The components of the VR device 600 may include, but are not limited to: the at least one processor 601, the at least one computer storage medium 602, and a bus 603 connecting different system components (including the computer storage medium 602 and the processor 601).

[0114] Bus 603 represents one or more of several types of bus structures, including a computer storage media bus or computer storage media controller, a peripheral bus, a processor, or a local bus using any of a variety of bus architectures.

[0115] The computer storage media 602 may include readable media in the form of volatile computer storage media, such as random access computer storage media (RAM) 621 and / or cache storage media 622 , and may further include read-only computer storage media (ROM) 623 .

[0116] The computer storage medium 602 may also include a program / utility 625 having a set (at least one) of program modules 424, such program modules 624 including but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment.

[0117] The VR device 600 may also communicate with one or more external devices 604 (e.g., keyboards, pointing devices, etc.), one or more devices that enable a user to interact with the VR device 600, and / or any device that enables the VR device 600 to communicate with one or more other VR devices (e.g., routers, modems, etc.). Such communication may be performed via an input / output (I / O) interface 605. Furthermore, the VR device 600 may also communicate with one or more networks (e.g., a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) via a network adapter 606. As shown, the network adapter 606 communicates with other modules for the VR device 600 via a bus 603. It should be understood that, although not shown in the figure, other hardware and / or software modules may be used in conjunction with the VR device 600, including but not limited to: microcode, device drivers, redundant processors, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.

[0118] In some possible implementations, various aspects of a method for starting a VR application provided by the present invention may also be implemented in the form of a program product, which includes program code. When the program product runs on a computer device, the program code is used to enable the computer device to execute the steps of the method for starting a VR application according to various exemplary embodiments of the present invention described above in this specification.

[0119] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.

Claims

1. A method for starting a VR application, characterized in that: The method comprises: When the VR device is powered on and receives a screen-on instruction, a screen status value of the VR device is obtained, wherein the screen status value is used to indicate whether the screen of the VR device has been turned on; If it is determined that the screen status value is the first status value, the real-time positioning and map building slam function is turned on, and the VR mode status value is set to the first mode value, wherein the first status value is used to indicate that the screen of the VR device has been lit, the VR mode status value is used to indicate whether the VR device has turned on the slam function, and the first mode value is used to indicate that the VR device has turned on the slam function; If a command to start a target application is received from a user, a real-time screen action command of the user on the target application is obtained, and based on the real-time screen action command, the target application content corresponding to the real-time screen action command is rendered and displayed, until a target application exit command sent by the user is received, the target application is exited; When a screen-off instruction is received and the acquired screen status value is the second status value, the slam function of the VR device is turned off, and the VR mode status value is set to the second mode value, wherein the second mode value is used to indicate that the slam function of the VR device has been turned off.

2. The method according to claim 1, characterized in that The obtaining the screen status value of the VR device includes: Obtain the screen status value through the display synthesis system SurfaceFlinger service; The step of enabling the real-time positioning and map building slam function and setting the VR mode state value to the first mode value includes: Sending a positioning start instruction to the virtual reality mode control VrmodeControl service through the SurfaceFlinger service, so that the VrmodeControl service instructs the Qualcomm virtual reality QVR service to turn on the slam function based on the positioning start instruction, and sets the VR mode state value to the first mode value; The step of turning off the positioning function of the VR device and setting the VR mode state value to a second mode value includes: A positioning shutdown instruction is sent to the VrmodeControl service through the SurfaceFlinger service, so that the VrmodeControl service instructs the qvr service to shut down the slam function based on the positioning shutdown instruction and sets the VR mode state value to the second mode value.

3. The method according to claim 2, characterized in that After determining that the system of the VR device is started and before receiving a screen-on instruction, the method further includes: The SurfaceFlinger service is connected to the VrmodeControl service, and the VrmodeControl service is connected to the qvr service.

4. The method according to claim 1, characterized in that: Before acquiring the real-time screen action instruction of the user on the target application, the method further includes: Determine that the VR mode state value is a first mode value.

5. The method according to claim 4, characterized in that The VR mode status value is obtained by: The VR mode status value is obtained from Qualcomm Virtual Reality QVR service through the software development kit SDK of the target application.

6. The method according to claim 5, characterized in that The method further comprises: After receiving the instruction to start the target application sent by the user, establishing a connection between the SDK of the target application and the QVR service; After receiving the target application exit instruction sent by the user, the SDK of the target application is disconnected from the QVR service.

7. The method according to claim 1 or 6, characterized in that: The target application exit instruction includes ending the process of the target application or switching the process of the target application to background operation.

8. A VR device, characterized in that: comprising a processor and a memory, wherein the processor and the memory are connected via a bus; The memory stores a computer program, and the processor is configured to perform the following operations based on the computer program: When the VR device is powered on and receives a screen-on instruction, a screen status value of the VR device is obtained, wherein the screen status value is used to indicate whether the screen of the VR device has been turned on; If it is determined that the screen status value is the first status value, the real-time positioning and map building slam function is turned on, and the VR mode status value is set to the first mode value, wherein the first status value is used to indicate that the screen of the VR device has been lit, the VR mode status value is used to indicate whether the VR device has turned on the slam function, and the first mode value is used to indicate that the VR device has turned on the slam function; If a command to start a target application is received from a user, a real-time screen action command of the user on the target application is obtained, and based on the real-time screen action command, the target application content corresponding to the real-time screen action command is rendered and displayed, until a target application exit command sent by the user is received, the target application is exited; When a screen-off instruction is received and the acquired screen status value is the second status value, the slam function of the VR device is turned off, and the VR mode status value is set to the second mode value, wherein the second mode value is used to indicate that the slam function of the VR device has been turned off.

9. The VR device according to claim 8, characterized in that: The processor executes the step of obtaining the screen status value of the VR device, and is specifically configured to: Obtain the screen status value through the display synthesis system SurfaceFlinger service; The processor executes the slam function of starting the real-time positioning and map building, and sets the VR mode state value to the first mode value, and is specifically configured as follows: Sending a positioning start instruction to the virtual reality mode control VrmodeControl service through the SurfaceFlinger service, so that the VrmodeControl service instructs the Qualcomm virtual reality QVR service to turn on the slam function based on the positioning start instruction, and sets the VR mode state value to the first mode value; The processor executes the step of turning off the positioning function of the VR device and setting the VR mode state value to a second mode value, and is specifically configured as follows: A positioning shutdown instruction is sent to the VrmodeControl service through the SurfaceFlinger service, so that the VrmodeControl service instructs the qvr service to shut down the slam function based on the positioning shutdown instruction and sets the VR mode state value to the second mode value.

10. The VR device according to claim 9, characterized in that: The processor is further configured to: After determining that the system of the VR device is started and before receiving a screen-on instruction, the SurfaceFlinger service is connected to the VrmodeControl service, and the VrmodeControl service is connected to the qvr service.