Virtual reality tour guide information generation method and device, medium and electronic equipment
By acquiring a set of collision-free accessible points and generating navigation paths using a multi-objective optimization algorithm, the problem of user spatial perception and memory in virtual reality systems is solved, enabling users to navigate and remember naturally in the virtual environment.
Patent Information
- Application Number
- CN202411272322.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-11
- Publication Date
- 2025-11-21
- Estimated Expiration
- 2044-09-11
AI Technical Summary
Existing virtual reality systems rely on teleportation points and path guidance technology for user spatial navigation, neglecting the user's spatial perception and memory process. This leads to a loss of sense of direction and position, making it impossible to achieve effective virtual environment memory.
Based on the user's visual perception characteristics, a set of collision-free accessible points is obtained, a navigation path that conforms to the user's visual and scene characteristics is generated, a multi-objective optimization algorithm is used to optimize the path selection, and guide information is generated by combining the visualization processing of viewpoints and paths.
It enhances users' immersion and spatial positioning capabilities in the virtual environment, enables users to naturally remember the virtual environment, and optimizes path selection through visual and cognitive characteristics.
Smart Images

Figure CN119334347B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of virtual reality technology, and in particular to a method, apparatus, medium and electronic device for generating virtual reality navigation information. Background Technology
[0002] Virtual reality (VR) technology, as an immersive interactive method, has shown broad application potential in various fields such as education, entertainment, and professional training. Users can immerse themselves in a three-dimensional virtual environment and interact naturally with digital content through head-mounted display devices. This technology provides users with a completely new way of experiencing things, making learning, gaming, and training activities more vivid and effective.
[0003] Currently, spatial navigation in virtual reality systems primarily relies on teleportation points and pathfinding technologies. Teleportation points allow users to quickly move to different locations within the virtual environment by selecting different points, while pathfinding guides users forward by providing continuous navigational cues.
[0004] Traditional point-and-click navigation methods, while quickly moving users to different locations, often neglect the user's spatial perception and memory processes, impacting their sense of direction and location within the virtual environment. Furthermore, while path-guided methods provide continuous navigational cues, they typically lack global path construction and cannot effectively optimize path selection based on the user's perspective and cognitive characteristics. Existing technologies cannot achieve the effect of users remembering the virtual environment. Summary of the Invention
[0005] This application provides a method, apparatus, medium, and electronic device for generating virtual reality navigation information. To provide a basic understanding of some aspects of the disclosed embodiments, a brief summary is given below. This summary is not intended as a general description, nor is it intended to identify key / important components or describe the scope of protection of these embodiments. Its sole purpose is to present some concepts in a simple form as a prelude to the detailed description that follows.
[0006] In a first aspect, embodiments of this application provide a method for generating virtual reality navigation information, the method comprising:
[0007] Acquire scene data for virtual reality scenes;
[0008] Based on scene data, identify the key 3D objects that need to be focused on for navigation in virtual reality scenes;
[0009] Based on the user's preset visual perception features in the virtual reality scene, obtain the accessible points that do not collide during the movement as the accessible point set.
[0010] Based on the set of accessible points and key 3D objects, a final set of viewpoints is generated to provide the best visual experience for the user, serving as elements representing the viewpoints.
[0011] Generate elements representing the navigation path based on the set of accessible points;
[0012] Visualize the elements representing the navigation path and the elements representing the viewpoint to obtain navigation information for the virtual reality scene.
[0013] Optionally, preset visual perception features include the user's visual exploration stride and the user's initial position;
[0014] Based on the user's preset visual perception features in the virtual reality scene, collision-free accessible points during movement are obtained as the accessible point set, including:
[0015] Create a virtual object at the user's initial location;
[0016] Starting from the user's initial position, control the virtual object to move in multiple preset directions in the virtual reality scene according to the visual exploration step size;
[0017] If the movement trajectory can cover the virtual reality scene, obtain the accessible points without collision during the movement;
[0018] Accessible points that do not collide during movement are defined as the set of accessible points.
[0019] Optionally, based on the set of accessible points and key 3D objects, a final viewpoint set is generated to provide the user with the best visual experience, including:
[0020] For each accessible point in the accessible point set, rays are emitted according to preset positions and sampling intervals;
[0021] Count the number of rays that fall on key 3D objects from each accessible point in the accessible point set;
[0022] Accessible points with a number of rays greater than a preset threshold are selected as the candidate point set.
[0023] Cluster the candidate point set based on the preset radius to obtain the clustered point set;
[0024] Calculate the average position based on the positions of each candidate point in the candidate point set;
[0025] From the cluster set, select cluster points whose distance from the average position meets a preset distance threshold, and use them as the final viewpoint set for the user to obtain the best visual effect.
[0026] Optionally, elements representing the navigation path are generated based on the set of accessible points, including:
[0027] Based on the spatial structure or content characteristics contained in the scene data, the virtual reality scene is divided into multiple partitions;
[0028] From the set of accessible points, determine the accessible points contained in each partition, which are then used as the subset of reachable points for each partition;
[0029] Within the reachable subset of each partition, mark the optimal viewpoint subset;
[0030] Generate elements representing navigation paths based on the reachable subset and the optimal viewpoint subset for each partition.
[0031] Optionally, elements representing the navigation path are generated based on the reachable subset and the optimal viewpoint subset for each partition, including:
[0032] For each partition, create a start point and an end point to obtain the start point and end point positions for each partition;
[0033] Create a two-dimensional matrix for each partition based on the subset of reachable points for each partition;
[0034] The starting and ending positions of each partition, the two-dimensional matrix of each partition, and the optimal viewpoint subset are used as parameters of the multi-objective optimization algorithm. Multi-objective pathfinding is performed through the multi-objective optimization algorithm to obtain the pathfinding set of all partitions.
[0035] Generate elements representing navigation paths based on the pathfinding sets of all partitions.
[0036] Optionally, based on the wayfinding sets of all partitions, generate elements representing the navigation path, including:
[0037] Merge the wayfinding sets of all partitions to obtain a coherent navigation path;
[0038] The heuristic strategy, which involves increasing the cost of boundary locations and reducing the number of path inflection points, optimizes the coherent navigation path and obtains elements representing the navigation path.
[0039] Optionally, elements representing the navigation path and elements representing the viewpoint are visualized to obtain navigation information for the virtual reality scene, including:
[0040] The viewpoint map is obtained by visualizing the elements representing the viewpoint using preset VR transmission elements.
[0041] The navigation path is rendered using Unity3D resources to obtain the navigation path map;
[0042] By merging the viewpoint map and the navigation path map, we can obtain the navigation information for the virtual reality scene.
[0043] Secondly, embodiments of this application provide a virtual reality navigation information generation device, the device comprising:
[0044] The scene data acquisition module is used to acquire scene data of virtual reality scenes;
[0045] The key 3D object recognition module is used to identify key 3D objects that need to be focused on for navigation in a virtual reality scene based on scene data;
[0046] The accessible point set acquisition module is used to acquire non-collision accessible points during the movement process as an accessible point set based on the user's preset visual perception features in the virtual reality scene.
[0047] The first element generation module is used to generate a final viewpoint set for the user to obtain the best visual effect based on the accessible point set and key 3D objects, which serves as the element representing the viewpoint.
[0048] The second element generation module is used to generate elements representing navigation paths based on the set of accessible points;
[0049] The element visualization module is used to visualize elements representing navigation paths and elements representing viewpoints, thereby obtaining navigation information for virtual reality scenes.
[0050] Thirdly, embodiments of this application provide a computer storage medium storing multiple instructions adapted for loading and execution of the above-described method steps by a processor.
[0051] Fourthly, embodiments of this application provide an electronic device that may include: a processor and a memory; wherein the memory stores a computer program adapted to be loaded by the processor and executed by the above-described method steps.
[0052] The technical solutions provided in this application embodiment may include the following beneficial effects:
[0053] In this embodiment, on the one hand, based on the user's preset visual perception features in the virtual reality scene, non-collision accessible points during movement are obtained as an accessible point set, and then a navigation path is generated. Because the generation of the navigation path fully considers the user's visual perception and spatial cognition, the user can naturally understand and remember their direction and position during movement. This continuity and intuitiveness greatly enhances the user's immersion and spatial positioning ability, and helps to ensure that the user maintains continuous perception of the environment during navigation. On the other hand, by utilizing 3D objects and visual perception features in the scene, a global navigation path that conforms to the user's natural vision and scene features can be generated. This can effectively optimize path selection according to the user's perspective and cognitive characteristics, and achieve the user's memory effect of the virtual environment.
[0054] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and do not limit this application. Attached Figure Description
[0055] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.
[0056] Figure 1 This is a flowchart illustrating a method for generating virtual reality navigation information according to an embodiment of this application;
[0057] Figure 2 This is a scene diagram illustrating a virtual reality scene provided in an embodiment of this application;
[0058] Figure 3 This is a schematic diagram illustrating a virtual reality navigation information generation process provided in an embodiment of this application;
[0059] Figure 4 This is a schematic diagram of another virtual reality navigation information generation process provided in an embodiment of this application;
[0060] Figure 5 This is a schematic diagram of the structure of a virtual reality navigation information generation device provided in an embodiment of this application;
[0061] Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation
[0062] The following description and accompanying drawings fully illustrate specific embodiments of this application to enable those skilled in the art to practice them.
[0063] It should be understood that the described embodiments are merely some, not all, of the embodiments in this application. All other embodiments obtained by those skilled in the art based on the embodiments in this application without inventive effort are within the scope of protection of this application.
[0064] In the following description, when referring to the accompanying drawings, the same numbers in different drawings denote the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.
[0065] In the description of this application, it should be understood that the terms "first," "second," etc., are used for descriptive purposes only and should not be construed as indicating or implying relative importance. Those skilled in the art can understand the specific meaning of the above terms in this application based on the specific circumstances. Furthermore, in the description of this application, unless otherwise stated, "multiple" refers to two or more. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, or B existing alone. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship.
[0066] This application provides a method, apparatus, medium, and electronic device for generating virtual reality navigation information to solve the problems existing in the aforementioned related technologies. In the embodiments of this application, on the one hand, based on the user's preset visual perception characteristics in the virtual reality scene, non-collision-free accessible points during movement are obtained as an accessible point set, thereby generating a navigation path. Because the generation of the navigation path fully considers the user's visual perception and spatial cognition, the user can naturally understand and remember their direction and position during movement. This continuity and intuitiveness greatly enhances the user's immersion and spatial positioning ability, helping to ensure that the user maintains continuous perception of the environment during navigation. On the other hand, by utilizing 3D objects and visual perception characteristics in the scene, a global navigation path that conforms to the user's natural vision and scene characteristics can be generated. This can effectively optimize path selection according to the user's perspective and cognitive characteristics, achieving the user's memory effect of the virtual environment. The following describes the process in detail using exemplary embodiments.
[0067] The following will be combined with the appendix Figure 1 - Appendix Figure 4 This application provides a detailed description of the virtual reality navigation information generation method provided in its embodiments. This method can be implemented using a computer program and can run on a virtual reality navigation information generation device based on the von Neumann architecture. This computer program can be integrated into an application or run as a standalone utility application.
[0068] Please see Figure 1 This is a flowchart illustrating a method for generating virtual reality navigation information, as provided in this application embodiment. Figure 1 As shown, the method in this application embodiment may include the following steps:
[0069] S101, acquire scene data of the virtual reality scene;
[0070] Virtual reality (VR) scenes refer to computer-generated, three-dimensional environments that simulate the real world, allowing users to immerse themselves in them using VR devices such as head-mounted displays. Scene data refers to the collection of information describing various elements within a VR scene (such as objects, spatial layout, lighting conditions, etc.), typically including 3D models, textures, and physical properties, which together form the foundation of the VR experience.
[0071] In some embodiments, a dataset provided by the AI2THOR-unity project can be used. This dataset contains five indoor scenes (hallway, living room, bedroom, kitchen, and bathroom), each with 30 editable 3D models. Each model contains a large number of richly structured 3D objects. These are packaged into a VR-compatible application using Unity3D for easy user interaction. The scene appearance is as follows... Figure 2 As shown.
[0072] In this embodiment, the virtual environment model created using 3D modeling software (such as Blender, Maya, or 3ds Max) can be exported to a common format (such as FBX or OBJ) and imported into a virtual reality platform to obtain scene data for the virtual reality scene. Alternatively, online platforms can provide pre-made 3D models and scene data, which users can directly download and use to obtain scene data for the virtual reality scene.
[0073] S102, Based on scene data, identify the key 3D objects that need to be focused on for navigation in the virtual reality scene;
[0074] Among them, key 3D objects are three-dimensional objects or elements that are crucial to the user's navigation experience in a virtual reality scene, such as road signs, important buildings, and interaction points.
[0075] In some embodiments, scene data can be analyzed using computer vision algorithms or features built into the game engine to identify 3D objects that are critical to navigation.
[0076] For example, in a virtual reality setting like a museum, computer vision algorithms can identify the main exhibits in each gallery—objects that users might need to pay special attention to during their visit. They can also identify all signs and waypoints, crucial for guiding users through the museum. Furthermore, they can pinpoint the museum's entrance and exit locations, ensuring users can easily find their way in and out. Finally, they can identify rest areas and interactive points of interest, areas essential for enhancing the user experience.
[0077] S103, based on the user's preset visual perception features in the virtual reality scene, obtain the accessible points that do not collide during the movement as the accessible point set.
[0078] Among them, the preset visual perception features include the user's visual exploration step length and the user's initial position.
[0079] In some embodiments of this application, the specific process of obtaining collision-free accessible points as an accessible point set based on the user's preset visual perception features in a virtual reality scene includes: creating a virtual object at the user's initial position; controlling the virtual object to move in multiple preset directions in the virtual reality scene according to the visual exploration step size, starting from the user's initial position; obtaining collision-free accessible points during the movement when the movement trajectory can cover the virtual reality scene; and using the collision-free accessible points during the movement as an accessible point set.
[0080] In this context, the user's initial position refers to the user's starting point or initial location within the virtual reality scene. A virtual object refers to a digital entity representing or controlled by the user within the virtual reality scene. A virtual reality scene refers to a computer-generated, three-dimensional environment that simulates the real world. Visual exploration stride refers to the distance or stride a user or virtual object moves during exploration in virtual reality. A movement trajectory refers to the path formed by a virtual object as it moves within the virtual reality scene. Collision-free accessible points refer to points that a virtual object can reach without colliding with other objects during movement. The set of accessible points refers to the collection of all collision-free accessible points within the virtual reality scene.
[0081] For example, the visual exploration step size can be set to 0.25 meters. Multiple preset directions include forward, backward, left, and right.
[0082] S104, Based on the accessible point set and key 3D objects, generate the final viewpoint set for the user to obtain the best visual effect, as the element representing the viewpoint;
[0083] The final viewpoint set refers to a set of viewpoints that are finally determined after clustering and distance filtering, and these viewpoints provide the best visual experience for users.
[0084] In some embodiments of this application, a final viewpoint set for optimal visual effect is generated based on an accessible point set and key 3D objects. The specific process of generating the elements representing the viewpoints includes: emitting rays at preset positions and sampling intervals for each accessible point in the accessible point set; counting the number of rays falling on key 3D objects from each accessible point in the accessible point set; selecting accessible points with a ray count greater than a preset threshold as a candidate point set; clustering the candidate point set based on a preset radius to obtain a clustered point set; calculating the average position based on the position of each candidate point in the candidate point set; and selecting clustered points from the clustered point set whose distance from the average position meets a preset distance threshold as the final viewpoint set for optimal visual effect.
[0085] In this context, "preset location" refers to a specific location pre-defined in the virtual reality scene, serving as the starting point for ray emission. "Sampling interval" refers to the fixed distance between two adjacent rays during ray emission. A ray is a virtual straight line emitted from the preset location in the virtual reality scene, used for detection. "Candidate point set" refers to a group of potentially accessible points selected after ray counting and threshold filtering. "Preset radius" refers to a pre-defined distance range used in clustering algorithms to determine the maximum distance between cluster points. "Cluster point set" refers to the set of points with similar locations obtained after processing the candidate point set using a clustering algorithm. "Average position" refers to the average position of all points in the candidate point set, used to evaluate and select the final viewpoint.
[0086] For example, the preset position can be at eye level. The sampling interval can be 1 degree. The ray direction can be set to 360 degrees horizontally, 60 degrees upwards, and 75 degrees downwards. The cluster radius is set to 1.5 * pace.
[0087] In this embodiment of the application, the process maintains the user's natural exploration tendency and visual range while also taking into account the execution process of the subsequent path generation algorithm.
[0088] S105, Generate elements representing the navigation path based on the set of accessible points;
[0089] In this embodiment of the application, the specific process of generating elements representing navigation paths based on the set of accessible points includes: dividing the virtual reality scene into multiple partitions based on the spatial structure or content features contained in the scene data; determining the accessible points contained in each partition from the set of accessible points as the reachable point subset of each partition; marking the optimal viewpoint subset within the reachable point subset of each partition; and generating elements representing navigation paths based on the reachable point subset and the optimal viewpoint subset of each partition.
[0090] Spatial structure refers to the spatial layout and organization of a virtual reality scene, such as room layout and building structure. Content features refer to the content elements in a virtual reality scene, such as different terrains, object types, and environmental styles. A partition refers to the smaller parts or areas into which a virtual reality scene is divided according to certain rules or standards. A reachable point subset refers to the subset of accessible points belonging to that partition, selected from the set of accessible points. The optimal viewpoint subset refers to the set of best viewpoints selected from the reachable point subset of each partition based on certain criteria (such as visual effects, user preferences, etc.). Elements of a navigation path refer to the basic units or components that constitute a navigation path, such as points on the path, directional indicators, and path segments.
[0091] Specifically, the specific process of generating elements representing the navigation path based on the reachable point subset and the optimal view point subset of each partition includes: for each partition, create a starting point and an ending point to obtain the starting position and the ending position of each partition; create a two-dimensional matrix for each partition according to the reachable point subset of each partition; use the starting position and the ending position of each partition, the two-dimensional matrix of each partition, and the optimal view point subset as parameters of the multi-objective optimization algorithm, and perform multi-objective path finding through the multi-objective optimization algorithm to obtain the path finding sets of all partitions; generate elements representing the navigation path according to the path finding sets of all partitions.
[0092] Among them, the starting position refers to the position of the starting point set in each partition, which is used for the start of the navigation path. The ending position refers to the position of the ending point set in each partition, which is used for the end of the navigation path. The two-dimensional matrix is a data structure composed of rows and columns, which is used here to represent the spatial distribution of the reachable point subset of each partition. The multi-objective optimization algorithm is an algorithm designed to optimize multiple objectives or criteria simultaneously, usually with trade-offs between these objectives. Multi-objective path finding refers to finding a path from the starting point to the ending point considering multiple objectives (such as the shortest path, the fewest turning points, the best visual effect, etc.). The path finding set refers to the set of paths obtained through multi-objective path finding, and each path is the optimal solution for a specific partition. The elements of the navigation path refer to the visual representation constituting the navigation path, such as lines, arrows, markers, etc., which are used to guide the user's movement in the virtual reality environment.
[0093] For example, the multi-objective optimization algorithm is the multi-objective A* algorithm. For the reachable point subset Vi of each partition, create a two-dimensional matrix Mi using the extreme value coordinates xmin, xmax, ymin, and ymax, with the width wi = (xmax - xmin) / pace + l and the height hi = (ymax - ymin) / pace + 1. The indices j, k of the point v(x, y) in the matrix Mi (0 ≤ j < wi, 0 < k < hi) are: j = (x - xmin) / pace, k = (ymax - y) / pace.
[0094] Specifically, the specific process of generating elements representing the navigation path according to the path finding sets of all partitions includes: merge the path finding sets of all partitions to obtain a coherent navigation path; optimize the coherent navigation path by means of increasing the cost of the boundary position and reducing the number of path turning points included in the heuristic strategy to obtain the elements representing the navigation path.
[0095] For example, the heuristic strategy can adopt the MMOA* algorithm, and the cost value of reachable points without adjacent collisions is set to 0.1. In the four adjacent directions, each time a collision occurs, the cost increases by 0.1 (the maximum value is 0.4). Then these cost values are used as optimization objectives and input into the MMOA* algorithm.
[0096] S106, visualize the elements representing the navigation path and the elements representing the viewpoint to obtain navigation information for the virtual reality scene.
[0097] In this embodiment of the application, the specific process of visualizing the elements representing the navigation path and the elements representing the viewpoint to obtain the navigation information of the virtual reality scene includes: visualizing the elements representing the viewpoint using preset VR transmission elements to obtain a viewpoint map; rendering the elements representing the navigation path using Unity3D resources to obtain a navigation path map; and merging the viewpoint map and the navigation path map to obtain the navigation information of the virtual reality scene.
[0098] Among these, preset VR teleportation elements refer to predefined graphical elements used in virtual reality applications to represent teleportation points or viewpoints, such as icons, cursors, and highlights. A viewpoint map is an image obtained through visualization processing, showing the location and information of various viewpoints that the user can teleport to in the virtual reality scene. Unity3D resources refer to a series of tools, materials, models, and other resources provided by the Unity3D game engine, used to create and render 3D scenes and objects in the Unity3D environment. A navigation path map is an image rendered using Unity3D resources, showing the path the user navigates in the virtual reality scene, including the path's direction, direction, and key points. Navigation information refers to a comprehensive guide provided to the user on how to navigate and explore the virtual reality scene, combining information from the viewpoint map and the navigation path map.
[0099] It should be noted that the radius of the teleportation point is proportional to the number of candidate points V' within the viewpoint cluster P; that is, the richer the viewpoint information, the more obvious the teleportation point location.
[0100] For example Figure 3 As shown, Figure 3 This application provides a schematic diagram of a virtual reality (VR) navigation information generation process. The process involves acquiring a VR scene, identifying accessible points without collisions based on the user's pre-defined visual perception features within the VR scene, and selecting a viewpoint set centered on the user, based on the accessible point set and key 3D objects. The selected viewpoints are then clustered to obtain the final viewpoint set for optimal user viewing. Visualizing this final viewpoint set yields a remote teleportation point map (viewpoint map). Based on the accessible point set, a region map is constructed, and a multi-objective A* algorithm is used for pathfinding to obtain elements representing the navigation path. Visualizing these elements yields a path map. Finally, the viewpoint map and path map are merged to obtain VR-guided navigation information.
[0101] Furthermore, this method can be transferred to larger-scale virtual reality scenarios; detailed results can be found in [link to results]. Figure 4 .
[0102] In this embodiment, on the one hand, based on the user's preset visual perception features in the virtual reality scene, non-collision accessible points during movement are obtained as an accessible point set, and then a navigation path is generated. Because the generation of the navigation path fully considers the user's visual perception and spatial cognition, the user can naturally understand and remember their direction and position during movement. This continuity and intuitiveness greatly enhances the user's immersion and spatial positioning ability, and helps to ensure that the user maintains continuous perception of the environment during navigation. On the other hand, by utilizing 3D objects and visual perception features in the scene, a global navigation path that conforms to the user's natural vision and scene features can be generated. This can effectively optimize path selection according to the user's perspective and cognitive characteristics, and achieve the user's memory effect of the virtual environment.
[0103] The following are embodiments of the apparatus described in this application, which can be used to execute the embodiments of the method described in this application. For details not disclosed in the apparatus embodiments of this application, please refer to the embodiments of the method described in this application.
[0104] Please see Figure 5 This illustration shows a schematic diagram of a virtual reality navigation information generation device provided in an exemplary embodiment of this application. The virtual reality navigation information generation device can be implemented as all or part of an electronic device through software, hardware, or a combination of both. The device 1 includes a scene data acquisition module 10, a key 3D object recognition module 20, an accessible point set acquisition module 30, a first element generation module 40, a second element generation module 50, and an element visualization module 60.
[0105] Scene data acquisition module 10 is used to acquire scene data of virtual reality scenes;
[0106] The key 3D object recognition module 20 is used to identify key 3D objects that need to be focused on for navigation in a virtual reality scene based on scene data;
[0107] Accessible point set acquisition module 30 is used to acquire non-collision accessible points during the movement process as an accessible point set based on the user's preset visual perception features in the virtual reality scene.
[0108] The first element generation module 40 is used to generate a final viewpoint set for the user to obtain the best visual effect based on the accessible point set and key 3D objects, as elements representing the viewpoints;
[0109] The second element generation module 50 is used to generate elements representing navigation paths based on the set of accessible points;
[0110] The element visualization module 60 is used to visualize elements representing navigation paths and elements representing viewpoints to obtain navigation information for the virtual reality scene.
[0111] It should be noted that the virtual reality navigation information generation device provided in the above embodiments is only illustrated by the division of the above functional modules when executing the virtual reality navigation information generation method. In practical applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. In addition, the virtual reality navigation information generation device and the virtual reality navigation information generation method embodiments provided in the above embodiments belong to the same concept, and the implementation process is detailed in the method embodiments, which will not be repeated here.
[0112] The sequence numbers of the embodiments in this application are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.
[0113] In this embodiment, on the one hand, based on the user's preset visual perception features in the virtual reality scene, non-collision accessible points during movement are obtained as an accessible point set, and then a navigation path is generated. Because the generation of the navigation path fully considers the user's visual perception and spatial cognition, the user can naturally understand and remember their direction and position during movement. This continuity and intuitiveness greatly enhances the user's immersion and spatial positioning ability, and helps to ensure that the user maintains continuous perception of the environment during navigation. On the other hand, by utilizing 3D objects and visual perception features in the scene, a global navigation path that conforms to the user's natural vision and scene features can be generated. This can effectively optimize path selection according to the user's perspective and cognitive characteristics, and achieve the user's memory effect of the virtual environment.
[0114] This application also provides a computer-readable medium having program instructions stored thereon, which, when executed by a processor, implement the virtual reality navigation information generation method provided in the above-described method embodiments.
[0115] This application also provides a computer program product containing instructions that, when run on a computer, causes the computer to execute the virtual reality navigation information generation method of the various method embodiments described above.
[0116] Please see Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Figure 6 As shown, the electronic device 1000 may include: at least one processor 1001, at least one network interface 1004, a user interface 1003, a memory 1005, and at least one communication bus 1002.
[0117] The communication bus 1002 is used to realize the connection and communication between these components.
[0118] The user interface 1003 may include a display screen and a camera. Optionally, the user interface 1003 may also include a standard wired interface and a wireless interface.
[0119] The network interface 1004 may optionally include a standard wired interface or a wireless interface (such as a Wi-Fi interface).
[0120] The processor 1001 may include one or more processing cores. The processor 1001 connects to various parts within the electronic device 1000 using various interfaces and lines. It executes various functions and processes data by running or executing instructions, programs, code sets, or instruction sets stored in the memory 1005, and by calling data stored in the memory 1005. Optionally, the processor 1001 may be implemented using at least one hardware form selected from Digital Signal Processing (DSP), Field-Programmable Gate Array (FPGA), and Programmable Logic Array (PLA). The processor 1001 may integrate one or more of the following: a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), and a modem. The CPU primarily handles the operating system, user interface, and applications; the GPU is responsible for rendering and drawing the content to be displayed on the screen; and the modem handles wireless communication. It is understood that the modem may also be implemented as a separate chip, without being integrated into the processor 1001.
[0121] The memory 1005 may include random access memory (RAM) or read-only memory. Optionally, the memory 1005 may include a non-transitory computer-readable storage medium. The memory 1005 can be used to store instructions, programs, code, code sets, or instruction sets. The memory 1005 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for at least one function (such as touch function, sound playback function, image playback function, etc.), instructions for implementing the above-described method embodiments, etc.; the data storage area may store data involved in the above-described method embodiments, etc. Optionally, the memory 1005 may also be at least one storage system located remotely from the aforementioned processor 1001. Figure 6 As shown, the memory 1005, which serves as a computer storage medium, may include an operating system, a network communication module, a user interface module, and a virtual reality navigation information generation application.
[0122] exist Figure 6 In the illustrated electronic device 1000, the user interface 1003 is mainly used to provide an input interface for the user and to acquire user input data; while the processor 1001 can be used to call the virtual reality navigation information generation application stored in the memory 1005, and specifically perform the following operations:
[0123] Acquire scene data for virtual reality scenes;
[0124] Based on scene data, identify the key 3D objects that need to be focused on for navigation in virtual reality scenes;
[0125] Based on the user's preset visual perception features in the virtual reality scene, obtain the accessible points that do not collide during the movement as the accessible point set.
[0126] Based on the set of accessible points and key 3D objects, a final set of viewpoints is generated to provide the best visual experience for the user, serving as elements representing the viewpoints.
[0127] Generate elements representing the navigation path based on the set of accessible points;
[0128] Visualize the elements representing the navigation path and the elements representing the viewpoint to obtain navigation information for the virtual reality scene.
[0129] In one embodiment, when the processor 1001 executes the operation of acquiring collision-free accessible points as a set of accessible points based on the user's preset visual perception features in the virtual reality scene, it specifically performs the following operations:
[0130] Create a virtual object at the user's initial location;
[0131] Starting from the user's initial position, control the virtual object to move in multiple preset directions in the virtual reality scene according to the visual exploration step size;
[0132] If the movement trajectory can cover the virtual reality scene, obtain the accessible points without collision during the movement;
[0133] Accessible points that do not collide during movement are defined as the set of accessible points.
[0134] In one embodiment, when the processor 1001 generates a final viewpoint set based on the accessible point set and key 3D objects to provide the user with the best visual experience, it specifically performs the following operations:
[0135] For each accessible point in the accessible point set, rays are emitted according to preset positions and sampling intervals;
[0136] Count the number of rays that fall on key 3D objects from each accessible point in the accessible point set;
[0137] Accessible points with a number of rays greater than a preset threshold are selected as the candidate point set.
[0138] Cluster the candidate point set based on the preset radius to obtain the clustered point set;
[0139] Calculate the average position based on the positions of each candidate point in the candidate point set;
[0140] From the cluster set, select cluster points whose distance from the average position meets a preset distance threshold, and use them as the final viewpoint set for the user to obtain the best visual effect.
[0141] In one embodiment, when processor 1001 generates elements representing navigation paths based on a set of accessible points, it specifically performs the following operations:
[0142] Based on the spatial structure or content characteristics contained in the scene data, the virtual reality scene is divided into multiple partitions;
[0143] From the set of accessible points, determine the accessible points contained in each partition, which are then used as the subset of reachable points for each partition;
[0144] Within the reachable subset of each partition, mark the optimal viewpoint subset;
[0145] Generate elements representing navigation paths based on the reachable subset and the optimal viewpoint subset for each partition.
[0146] In one embodiment, when the processor 1001 generates elements representing navigation paths based on a subset of reachable points and a subset of optimal viewpoints for each partition, it specifically performs the following operations:
[0147] For each partition, create a start point and an end point to obtain the start point and end point positions for each partition;
[0148] Create a two-dimensional matrix for each partition based on the subset of reachable points for each partition;
[0149] The starting and ending positions of each partition, the two-dimensional matrix of each partition, and the optimal viewpoint subset are used as parameters of the multi-objective optimization algorithm. Multi-objective pathfinding is performed through the multi-objective optimization algorithm to obtain the pathfinding set of all partitions.
[0150] Generate elements representing navigation paths based on the pathfinding sets of all partitions.
[0151] In one embodiment, when processor 1001 generates elements representing navigation paths based on the routing sets of all partitions, it specifically performs the following operations:
[0152] Merge the wayfinding sets of all partitions to obtain a coherent navigation path;
[0153] The heuristic strategy, which involves increasing the cost of boundary locations and reducing the number of path inflection points, optimizes the coherent navigation path and obtains elements representing the navigation path.
[0154] In one embodiment, when the processor 1001 executes elements representing the navigation path and elements representing the viewpoint to obtain navigation information for the virtual reality scene, it specifically performs the following operations:
[0155] The viewpoint map is obtained by visualizing the elements representing the viewpoint using preset VR transmission elements.
[0156] The navigation path is rendered using Unity3D resources to obtain the navigation path map;
[0157] By merging the viewpoint map and the navigation path map, we can obtain the navigation information for the virtual reality scene.
[0158] In this embodiment, on the one hand, based on the user's preset visual perception features in the virtual reality scene, non-collision accessible points during movement are obtained as an accessible point set, and then a navigation path is generated. Because the generation of the navigation path fully considers the user's visual perception and spatial cognition, the user can naturally understand and remember their direction and position during movement. This continuity and intuitiveness greatly enhances the user's immersion and spatial positioning ability, and helps to ensure that the user maintains continuous perception of the environment during navigation. On the other hand, by utilizing 3D objects and visual perception features in the scene, a global navigation path that conforms to the user's natural vision and scene features can be generated. This can effectively optimize path selection according to the user's perspective and cognitive characteristics, and achieve the user's memory effect of the virtual environment.
[0159] Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by a computer program instructing related hardware. The program for generating virtual reality navigation information can be stored in a computer-readable storage medium. When executed, the program can include the processes of the embodiments of the above methods. The storage medium for the program for generating virtual reality navigation information can be a magnetic disk, optical disk, read-only memory, or random access memory, etc.
[0160] The above-disclosed embodiments are merely preferred embodiments of this application and should not be construed as limiting the scope of this application. Therefore, any equivalent variations made in accordance with the claims of this application shall still fall within the scope of this application.
Claims
1. A method for generating virtual reality navigation information, characterized in that, The method includes: Acquire scene data for virtual reality scenes; Based on the scene data, identify the key 3D objects that need to be focused on for navigation in the virtual reality scene; Based on the user's preset visual perception features in the virtual reality scene, obtain the accessible points that do not collide during the movement as the accessible point set. Based on the accessible point set and the key 3D object, a final viewpoint set is generated for the user to obtain the best visual effect, which serves as the element representing the viewpoint; Based on the set of accessible points, elements representing the navigation path are generated; wherein, The step of generating elements representing navigation paths based on the set of accessible points includes: Based on the spatial structure or content features contained in the scene data, the virtual reality scene is divided into multiple partitions; From the set of accessible points, determine the accessible points contained in each partition, as a subset of reachable points for each partition; Within the reachable point subset of each partition, mark the optimal viewpoint subset; Based on the reachable subset of each partition and the optimal viewpoint subset, generate elements representing the navigation path; Visualize the elements representing the navigation path and the elements representing the viewpoint to obtain the navigation information of the virtual reality scene.
2. The method according to claim 1, characterized in that, The preset visual perception features include the user's visual exploration step length and the user's initial position; The step of acquiring collision-free accessible points as an accessible point set based on the user's preset visual perception features in the virtual reality scene includes: Create a virtual object at the user's initial location; Starting from the user's initial position, the virtual object is controlled to move in multiple preset directions within the virtual reality scene according to the visual exploration step size; If the movement trajectory can cover the virtual reality scene, obtain the accessible points without collision during the movement; Accessible points that do not collide during movement are defined as the set of accessible points.
3. The method according to claim 1, characterized in that, The step of generating the final viewpoint set for optimal visual effect for the user, based on the accessible point set and the key 3D objects, includes: For each accessible point in the set of accessible points, rays are emitted according to preset positions and sampling intervals; Count the number of rays that fall on the key 3D object from each accessible point in the accessible point set; Accessible points with a number of rays greater than a preset threshold are selected as the candidate point set. The candidate point set is clustered based on a preset radius to obtain a clustered point set; Calculate the average position based on the positions of each candidate point in the candidate point set; From the cluster point set, select cluster points whose distance from the average position meets a preset distance threshold, and use them as the final viewpoint set for the user to obtain the best visual effect.
4. The method according to claim 1, characterized in that, The step of generating elements representing navigation paths based on the reachable point subset of each partition and the optimal viewpoint subset includes: For each partition, create a start point and an end point to obtain the start point and end point positions for each partition; Create a two-dimensional matrix for each partition based on the subset of reachable points for each partition; The starting and ending positions of each partition, the two-dimensional matrix of each partition, and the optimal viewpoint subset are used as parameters of the multi-objective optimization algorithm. Multi-objective pathfinding is performed through the multi-objective optimization algorithm to obtain the pathfinding set of all partitions. Based on the pathfinding sets of all the partitions, generate elements representing navigation paths.
5. The method according to claim 4, characterized in that, The step of generating elements representing navigation paths based on the pathfinding sets of all partitions includes: Merge the pathfinding sets of all the partitions to obtain a coherent navigation path; The heuristic strategy, which involves increasing the cost of boundary locations and reducing the number of path inflection points, optimizes the coherent navigation path and obtains elements representing the navigation path.
6. The method according to claim 1, characterized in that, The visualization of navigation path elements and viewpoint elements are used to obtain navigation information for the virtual reality scene, including: The viewpoint map is obtained by visualizing the elements representing the viewpoint using preset VR transmission elements. The navigation path is rendered using Unity3D resources to obtain the navigation path map; The viewpoint map and the navigation path map are merged to obtain the navigation information for the virtual reality scene.
7. A virtual reality navigation information generation device implemented using the method according to any one of claims 1-6, characterized in that, The device includes: The scene data acquisition module is used to acquire scene data of virtual reality scenes; A key 3D object recognition module is used to identify key 3D objects that need to be focused on during navigation in the virtual reality scene based on the scene data. The accessible point set acquisition module is used to acquire non-collision accessible points during the movement process as an accessible point set based on the user's preset visual perception features in the virtual reality scene. The first element generation module is used to generate the final viewpoint set for the user to obtain the best visual effect based on the accessible point set and the key 3D object, as the element representing the viewpoint; The second element generation module is used to generate elements representing navigation paths based on the set of accessible points; The element visualization module is used to visualize elements representing navigation paths and elements representing viewpoints to obtain navigation information for the virtual reality scene.
8. A computer storage medium, characterized in that, The computer storage medium stores a plurality of instructions adapted for loading by a processor and executing the method as described in any one of claims 1-6.
9. An electronic device, characterized in that, include: A processor and a memory; wherein the memory stores a computer program adapted to be loaded by the processor and executed as described in any one of claims 1-6.
Citation Information
Patent Citations
Reality sense generation method of virtual object in teaching scene
CN112509151A
Video generation method and device, computer readable storage medium and computer equipment
CN114945090A