AR navigation path generation method, system, electronic device and storage medium
The AR navigation path is generated through the navigation grid map and vector expansion method, which solves the problems of inflexible paths and poor user experience, realizes efficient navigation on the mobile terminal, ensures that the path is within the passable area, and improves the user experience.
Patent Information
- Application Number
- CN202110819215.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-07-20
- Publication Date
- 2024-09-06
- Estimated Expiration
- 2041-07-20
AI Technical Summary
In existing AR navigation technology, the problems of inflexible paths, winding paths, and limited use of mobile terminals, resulting in poor user experience, have not been effectively solved.
Using the navigation grid map combined with the funnel algorithm and vector expansion method, by obtaining the location information and area information of the starting point and end point, using the area search algorithm to establish the connection relationship, generate a path composed of vertices, and move in reverse through the angle of the vector pair Target length distance, generate target path, and adjust the path through iterative vector expansion method to ensure that it is within the passable area.
It improves path flexibility and navigation efficiency, solves the problems of path detours and poor user experience, and enables AR navigation to be used on mobile devices without restrictions, with low computational complexity and strong versatility.
Smart Images

Figure CN113658342B
Abstract
Description
Technical Field
[0001] The present application relates to the field of AR navigation technology, and in particular to a method, system, electronic device and storage medium for generating an AR navigation path. Background Art
[0002] AR (Augmented Reality) navigation combines 3D content with traditional navigation content, making navigation information output richer, and has great application prospects in indoor scenes such as shopping malls, museums, and amusement parks. Like traditional navigation, AR navigation needs to convert the environment into a map format that can be processed by computers, and then obtain the starting and ending point information to generate a path in the map, and obtain the basic information that constitutes the navigation system, such as the location of the navigation point and navigation prompts, based on the generated path.
[0003] In the related art, on the one hand, the AR navigation algorithm has a path planning based on an undirected node graph, that is, all POI points are converted into nodes of an undirected node graph, and these nodes are associated with certain rules to form a complete road network. When the user's current location, i.e., the starting point, and a node on the node graph, i.e., the end point information, are input, a planning algorithm, such as A*, is used to obtain the path result. However, the use of an undirected node graph to represent the road network information will lose most of the environmental information, and it is easy to generate paths such as crossing obstacles and broken lines when the undirected graph is associated with the user's position; in addition, the road network generated by the undirected graph is relatively fixed. In the case where multiple annotated paths are required to cover most of the walking paths in a large open area indoors, too many and too dense road networks will cause problems such as path detours and path turns. On the other hand, the AR navigation algorithm also has a path planning based on a grid map, which rasterizes the scene at a certain resolution. The size of the resolution affects the storage and search efficiency of the map. Too small a resolution and a scene with too large an area will cause the constructed grid map to be too large, which is not only not conducive to the expansion of the scene, but also this path planning method will be limited in use on the mobile terminal. In addition, the path search method of traditional navigation grid maps usually uses the vertices of the area boundary as path points. The generated path is close to the wall in the actual environment, which is unreasonable for AR navigation and is prone to AR object penetration.
[0004] Currently, in the case of AR navigation of paths, there are problems such as inflexible routes, tortuous paths, limited use of mobile terminals, and poor user experience, and no effective solutions have been proposed. Summary of the invention
[0005] The embodiments of the present application provide a method, system, electronic device and storage medium for generating an AR navigation path, so as to at least solve the problems of inflexible routes, tortuous paths, limited use of mobile terminals, and poor user experience in the case of AR navigation of paths in the related art.
[0006] In a first aspect, an embodiment of the present application provides a method for generating an AR navigation path, the method comprising:
[0007] Acquire location information and area information of a starting point and an end point, and obtain an area from the starting point to the end point through an area search algorithm, wherein the areas passed through are connected by common edges;
[0008] Obtaining a path consisting of vertices in the passed area by using a funnel algorithm, wherein the path consists of a plurality of continuous path vectors;
[0009] Adjacent vectors are obtained from the multiple continuous path vectors to form a vector pair, the angle between the vector pair is calculated, and the vertices of the vector pair are moved in the opposite direction along the angle by a target length to obtain a first path point, and the target path is generated through the first path point.
[0010] In some embodiments, moving the vertices of the vector pair in the opposite direction along the angle by a target length distance comprises:
[0011] Obtaining the length of a common side of the vector pair, and comparing the length of the common side with a preset threshold;
[0012] When it is determined that the length of the common side is greater than the preset threshold, the target length distance is half of the preset threshold;
[0013] When it is determined that the length of the common side is less than the preset threshold, the target length distance is half of the length of the common side.
[0014] In some embodiments, before obtaining the location information of the starting point and the end point, the method includes:
[0015] The scene map is divided into a plurality of traversable areas by a region segmentation algorithm, and the traversable areas are convex polygons.
[0016] In some embodiments, after generating the target path, the method includes:
[0017] All continuous path vectors constituting the target path are traversed, and it is determined whether the path vectors are located within a traversable area.
[0018] In some embodiments, determining whether the path vector is located within a traversable area includes:
[0019] Judgment condition 1: judging whether the two ends of the path vector are located in the same passable area;
[0020] Judgment condition 2: judging whether one end of the path vector is located inside the passable area;
[0021] Judgment condition 3: obtain the common edge set of all adjacent areas between the area where the starting endpoint of the path vector is located and the area where the ending endpoint is located, and determine whether the path vector intersects with any common edges in the common edge set.
[0022] In some embodiments, when the path vectors all satisfy the judgment condition 1, the path vectors are all located inside the passable area, and the target path is output;
[0023] When the path vector does not satisfy the judgment condition 1, judging the judgment condition 2 includes: when the judgment condition 2 is not satisfied, processing the path vector to obtain a new target path, or when the judgment condition 2 is satisfied, judging the judgment condition 3 includes: when the judgment condition 3 is satisfied, the path vectors are all located inside the passable area, and the target path is output, or when the judgment condition 3 is not satisfied, processing the path vector to obtain a new target path.
[0024] In some embodiments, processing the path vector to obtain a new target path includes:
[0025] Inserting a second path point along the path vector and between two ends of the path vector, wherein the distance between the second path point and the end points of the path vector can be set by a user-defined setting;
[0026] A new target path is generated by using the second path points, and it is determined whether all continuous path vectors in the new target path are located within the traversable area.
[0027] In a second aspect, an embodiment of the present application provides a system for generating an AR navigation path, the system comprising:
[0028] An acquisition module is used to acquire the location information and area information of the starting point and the end point, and obtain the area passed from the starting point to the end point through an area search algorithm, wherein the passed areas are connected by common edges;
[0029] A path generation module is used to obtain a path consisting of vertices in the passed area through a funnel algorithm, wherein the path consists of a plurality of continuous path vectors.
[0030] Adjacent vectors are obtained from the multiple continuous path vectors to form a vector pair, the angle between the vector pair is calculated, and the vertices of the vector pair are moved in the opposite direction along the angle by a target length to obtain a first path point, and the target path is generated through the first path point.
[0031] In a third aspect, an embodiment of the present application provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the method for generating an AR navigation path as described in the first aspect above is implemented.
[0032] In a fourth aspect, an embodiment of the present application provides a storage medium having a computer program stored thereon, which, when executed by a processor, implements the method for generating an AR navigation path as described in the first aspect above.
[0033] Compared with the related art, the method for generating an AR navigation path provided in an embodiment of the present application obtains the location information and area information of the starting point and the end point, and obtains the area passed from the starting point to the end point through an area search algorithm, wherein the passed areas are connected by common edges; then, a path composed of vertices is obtained in the passed area through a funnel algorithm, and the path is composed of multiple continuous path vectors; finally, adjacent vectors are obtained from the above multiple continuous path vectors and form vector pairs, the angle between these vector pairs is calculated, and the vertices of the above vector pairs are moved in the opposite direction of the angle by the target length to obtain a first path point, and the target path is generated through the first path point.
[0034] This application adopts a navigation grid map, which avoids the loss of undirected node map information and the memory limitation of the grid map, and also has the advantage of low distortion of environmental information in the grid map. In addition, this application also proposes a vector expansion method to solve the problem of the path generated by the navigation grid map in the prior art being close to the region boundary. The algorithm only needs to use the geometric relationship between the paths to move the path composed of vertices from the edge of the region to the middle of the region. It has low computational complexity, strong versatility and is not affected by environmental changes. Furthermore, based on the vector expansion method, this application also proposes an iterative vector expansion method to solve the problem that some paths generated by the vector expansion method are not in the passable area. At the same time, in order to avoid the problem of processing each path segment and generating o(n 2), the present application also proposes three path judgment screening conditions, so that most of the paths in the passable area do not need to be processed, and the low computational complexity of the iterative vector expansion method can be maintained. The problems of inflexible routes, tortuous paths, limited use of mobile terminals, and poor user experience in the case of AR navigation of paths in the related art are solved, which not only improves the path flexibility and navigation efficiency, but also improves the user experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:
[0036] Figure 1 is a schematic diagram of an application environment of a method for generating an AR navigation path according to an embodiment of the present application;
[0037] Figure 2 is a flowchart of a method for generating an AR navigation path according to an embodiment of the present application;
[0038] Figure 3 is a schematic diagram of generating a path based on a vector expansion method according to an embodiment of the present application;
[0039] Figure 4 is a flow chart of path generation based on iterative vector expansion method according to an embodiment of the present application;
[0040] Figure 5 is a schematic diagram of generating a path based on an iterative vector expansion method according to an embodiment of the present application;
[0041] Figure 6 is a schematic diagram of generating another path based on the iterative vector expansion method according to an embodiment of the present application;
[0042] Figure 7 is a structural block diagram of a system for generating an AR navigation path according to an embodiment of the present application;
[0043] Figure 8 It is a schematic diagram of the internal structure of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION
[0044] In order to make the purpose, technical solutions and advantages of the present application clearer, the present application is described and illustrated below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not intended to limit the present application. Based on the embodiments provided in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present application. In addition, it can also be understood that although the efforts made in this development process may be complex and lengthy, for ordinary technicians in the field related to the contents disclosed in the present application, some changes such as design, manufacturing or production based on the technical contents disclosed in the present application are only conventional technical means, and should not be understood as insufficient contents disclosed in the present application.
[0045] Reference to "embodiments" in this application means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those of ordinary skill in the art that the embodiments described in this application may be combined with other embodiments without conflict.
[0046] Unless otherwise defined, the technical terms or scientific terms involved in this application should be understood by people with ordinary skills in the technical field to which this application belongs. The words "one", "a", "a", "the" and the like involved in this application do not indicate a quantitative limitation, and may represent the singular or plural. The terms "include", "comprise", "have" and any of their variations involved in this application are intended to cover non-exclusive inclusions; for example, a process, method, system, product or device that includes a series of steps or modules (units) is not limited to the listed steps or units, but may also include steps or units that are not listed, or may also include other steps or units inherent to these processes, methods, products or devices. The words "connect", "connected", "coupled" and the like involved in this application are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. The "multiple" involved in this application refers to greater than or equal to two. "And / or" describes the association relationship of associated objects, indicating that there can be three relationships, for example, "A and / or B" can represent: A exists alone, A and B exist at the same time, and B exists alone. The terms "first", "second", "third" and the like involved in the present application are merely used to distinguish similar objects and do not represent a specific ordering of the objects.
[0047] The method for generating an AR navigation path provided in this application can be applied to Figure 1 In the application environment shown, Figure 1 The AR navigation according to the embodiment of the present application obtains the area from the starting point to the end point through the area search algorithm, wherein the areas passed through are connected by common edges; then, a path consisting of vertices is obtained in the passed area through the funnel algorithm, and the path consists of multiple continuous path vectors; finally, adjacent vectors are obtained from the above multiple continuous path vectors and form vector pairs, the angle between these vector pairs is calculated, and the vertices of the above vector pairs are moved in the opposite direction along the angle by the target length distance to obtain the first path point, and the target path is generated through the first path point and displayed on the server 10. Among them, the terminal device 11 can be, but is not limited to, various personal computers, laptops, smart phones, tablet computers and portable wearable devices, and the server 10 can be implemented by an independent server or a server cluster consisting of multiple servers.
[0048] This embodiment provides a method for generating an AR navigation path. Figure 2 is a flowchart of a method for generating an AR navigation path according to an embodiment of the present application. Figure 2 As shown, the process includes the following steps:
[0049] Step S201, obtaining the location information and area information of the starting point and the end point, and obtaining the area from the starting point to the end point through an area search algorithm, wherein the areas passed through are connected by common edges;
[0050] Figure 3 is a schematic diagram of generating a path based on a vector expansion method according to an embodiment of the present application, such as Figure 3 As shown, before obtaining the location information and area information of the starting point S and the end point G, this embodiment divides the scene map into multiple passable areas [R1, R2, ..., Rn] by a region segmentation algorithm, wherein these passable areas are all convex polygons;
[0051] Next, this embodiment uses the location information of the starting point S and the end point G to obtain the regions where the starting point S and the end point G are located, namely R1 and R4, and then uses the region search algorithm to obtain all the regions that need to be passed from the starting point S to the end point G as [R1, R5, R4], and these passed regions are connected by the common edges [R1, R5: V1V2] and [R5, R4: V3V4];
[0052] This embodiment selects the navigation grid map as the navigation map, and divides the scene into multiple passable areas. These passable areas are convex polygons, and the characteristic of convex polygons is that the line between any two points inside the polygon is still inside the polygon. This property can ensure that the path formed by the convex polygon remains as straight as possible, thereby solving the problem of path winding. In addition, dividing the passable area in the scene into multiple convex polygons can avoid the problem of excessive memory usage of the grid map, and also has the advantage of low distortion of environmental information in the grid map, which can not only improve the user experience, but also transplant the navigation method of the present application to a mobile terminal with relatively small memory, and its use is not restricted;
[0053] Step S202, obtaining a path consisting of vertices in the passed area by using a funnel algorithm, where the path consists of multiple continuous path vectors;
[0054] Specifically, by Figure 3 It can be seen that this embodiment uses the funnel algorithm to obtain a path consisting of vertices in the area [R1, R5, R4] that needs to be passed through<S,P1,P2,G> , where the path consists of multiple consecutive path vectors [<S,P1> ,<P1,P2> ,<P2,G> ]composition;
[0055] Step S203, obtain adjacent vectors from multiple continuous path vectors and form vector pairs, calculate the angle between the vector pairs, and move the vertices of the vector pairs in the opposite direction of the angle by the target length to obtain the first path point, and generate the target path through the first path point.
[0056] Specifically, by Figure 3 It can be seen that in this embodiment, multiple continuous path vectors [<S,P1> ,<P1,P2> ,<P2,G> ] to obtain adjacent path vectors in sequence to form vector pairs [[<S,P1> ,<P1,P2> ],[<P1,P2> ,<P2,G> ]], calculate the angles between the two vector pairs as θ1 and θ2, then move the vertices P1 and P2 of the above vector pairs in the opposite direction of the vector angles θ1 and θ2 by the target length, thereby obtaining the first path points P1' and P2' respectively, and generate a new path through the first path points<S,P1’,P2’,G> ;
[0057] Preferably, in this embodiment, the method for calculating the target length distance of the vertex moving in the opposite direction of the angle includes: obtaining the common side length of the vector pair, and comparing the common side length with a preset threshold; when it is judged that the common side length is greater than the preset threshold, the target length distance is half of the preset threshold; when it is judged that the common side length is less than the preset threshold, the target length distance is half of the common side length.
[0058] Specifically, Figure 3 As shown, take the corresponding vector pair [[<S,P1> ,<P1,P2> ],[<P1,P2> ,<P2,G> ]]’s common side [V1V2, V3V4], if the common side length Lc is greater than the preset threshold value Lmax, then the target length distance is half of the preset threshold value, that is, Lmax / 2; if the common side length Lc is less than the preset threshold value Lmax, then the target length distance is half of the common side length, that is, Lc / 2.
[0059] Compared with the problem in the prior art that the path generated by the navigation grid map is close to the region boundary, this embodiment proposes a vector expansion method. Through this algorithm, the path composed of vertices can be moved from the edge of the region to the middle of the region by simply utilizing the geometric relationship between the paths. It has low computational complexity, strong versatility and is not affected by environmental changes.
[0060] Through the above steps S201 to S203, the present application adopts a navigation grid map, which avoids the loss of undirected node map information and the memory limitation of the grid map, and also has the advantage of low distortion of environmental information in the grid map; in addition, the present application also proposes a vector expansion method to solve the problem that the path generated by the navigation grid map in the prior art is close to the region boundary. Through this algorithm, only the geometric relationship between the paths can be used to move the path composed of vertices from the edge of the region to the middle of the region. It has low computational complexity, strong versatility and is not affected by environmental changes; it solves the problems of inflexible routes, tortuous paths, limited mobile terminal use, and poor user experience in the case of AR navigation of the path, which not only improves the path flexibility and navigation efficiency, but also improves the user experience, and can be ported to mobile terminals.
[0061] In some of the embodiments, in order to solve the above-mentioned problem that the path generated by the vector expansion method sometimes exceeds the scope of the passable area, after the target path is generated, all continuous path vectors constituting the target path are traversed, and it is determined whether these path vectors are located within the passable area.
[0062] Figure 4 is a flow chart of path generation based on iterative vector expansion method according to an embodiment of the present application, such as Figure 4 As shown in FIG. 1 , the specific steps of determining whether the path vector is located within the traversable area by the iterative vector expansion method and constraining the path generated by the vector expansion method within the traversable area are as follows:
[0063] S1, obtain the starting point S and the end point G, and use the above vector expansion method to obtain the path near the middle of the road Path_set = [<S,P1> ,<P1,P2> ,…,<Pn,G> ], where the first path vector Path_1 in the set Path_set =<S,P1> , the last path vector Path_n =<Pn,G> , the middle path vector is Path_m=<Pm,Pm+1> ;
[0064] S2, determine whether all path vectors have been traversed, if yes, then jump directly to S6, otherwise continue to S3,;
[0065] S3, judging whether the current path vector is located within the passable area, the judging conditions include:
[0066] Judgment condition 1: Determine whether the two ends of the current path vector Path_m are located in the same passable area;
[0067] Judgment condition 2: Determine whether one end of the current path vector Path_m is located inside the passable area [R1, R2, …, Rn];
[0068] Judgment condition 3: Get the common edge set [VmVm+1,…,VkVk+1] of all adjacent areas between the area Rm where the starting endpoint Pm of the current path vector Path_m is located and the area Rk where the ending endpoint Pm+1 is located, and determine whether the current path vector intersects with any common edges in the common edge set.
[0069] S4, when the path vector Path_m satisfies judgment condition 1, the path vector is located inside the passable area [R1, R2, …, Rn], and directly returns to S2;
[0070] When the path vector Path_m does not satisfy the judgment condition 1, the judgment condition 2 is judged including:
[0071] If the judgment condition 2 is not satisfied, the path vector Path_m does not satisfy the condition of being located in the passable area, and then the process continues to execute S5;
[0072] Or when judgment condition 2 is met, judgment condition 3 includes:
[0073] When the judgment condition 3 is met, the path vector Path_m is located inside the passable area, and the process directly returns to S2;
[0074] Or when the judgment condition 3 is not satisfied, the path vector Path_m does not satisfy the condition of being located in the passable area, and then the process continues to execute S5;
[0075] S5, inserting a second path point P_InS along the current path vector Path_m and between the two ends of Path_m, wherein the distance between the second path point P_InS and the endpoints of the path vector Path_m can be customized, but the maximum distance cannot exceed the length of the path Path_m;
[0076] The second path point P_InS is used as the starting point S=P_InS of the new path planning, and the new target path is obtained by returning to S1 and regenerating;
[0077] S6, output the new target path [<S,P_In1> ,<P_In1,P_In2> ,…,<P_Inn,G> ] and ends.
[0078] Specifically, Figure 5 is a schematic diagram of generating a path based on an iterative vector expansion method according to an embodiment of the present application, such as Figure 5 As shown, according to the above steps S1-S6, this embodiment uses the iterative vector expansion method to finally output the target path [<S,P_In1> ,<P_In1,P_In2> ,<P_In2,G> ].
[0079] It should be noted that the path generated by the above iterative vector expansion method is not unique. In the path generated by the vector expansion method, only some path vectors may not be within the passable area. In this case, there is no need to correct the constraints of all path vectors. The output new target path can be [<S,P1> ,<P1,P2> ,…<P_Ini,P_Inj> ,…,<P_Inn,G> ]wait. Specifically, Figure 6 is a schematic diagram of generating another path based on the iterative vector expansion method according to an embodiment of the present application, that is, the new target path output by this embodiment can be as follows: Figure 6 The path shown.
[0080] Through the above steps S1 to S6, this embodiment proposes an iterative vector expansion method based on the vector expansion method to solve the problem that some paths generated by the vector expansion method are not in the passable area. At the same time, in order to avoid processing each path segment, o(n 2 ), this embodiment also proposes three path judgment screening conditions to avoid wasting time to process qualified paths, which can maintain the low computational complexity of the iterative vector expansion method and improve navigation efficiency.
[0081] It should be noted that the steps shown in the above process or the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.
[0082] This embodiment also provides a system for generating an AR navigation path, which is used to implement the above-mentioned embodiments and preferred implementation modes, and will not be repeated here. As used below, the terms "module", "unit", "subunit", etc. can be a combination of software and / or hardware that implements a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.
[0083] Figure 7 is a structural block diagram of a system for generating an AR navigation path according to an embodiment of the present application, such as Figure 7 As shown, the system includes an acquisition module 71 and a path generation module 72:
[0084] The acquisition module 71 is used to obtain the position information and area information of the starting point and the end point, and obtain the area passed from the starting point to the end point through an area search algorithm, wherein the passed areas are connected by common edges; the path generation module 72 is used to obtain a path composed of vertices in the passed area through a funnel algorithm, wherein the path is composed of multiple continuous path vectors, adjacent vectors are obtained from the multiple continuous path vectors and formed into vector pairs, the angle between the vector pairs is calculated, and the vertices of the vector pairs are moved in the opposite direction of the angle by a target length to obtain a first path point, and the target path is generated through the first path point.
[0085] Through the above system, the present application adopts a navigation grid map, which avoids the loss of undirected node map information and the memory limitation of the grid map, and also has the advantage of low distortion of environmental information in the grid map; in addition, the present application proposes a vector expansion method to solve the problem that the path generated by the navigation grid map in the prior art is close to the region boundary. The algorithm only needs to use the geometric relationship between the paths to move the path composed of vertices from the edge of the region to the middle of the region. It has low computational complexity, strong versatility and is not affected by environmental changes; further, based on the vector expansion method, an iterative vector expansion method is proposed to solve the problem that some paths generated by the vector expansion method are not in the passable area. At the same time, in order to avoid the generation of o(n 2 ), the present application also proposes three path judgment screening conditions, so that most of the paths in the passable area do not need to be processed, and the low computational complexity of the iterative vector expansion method can be maintained. The problems of inflexible routes, tortuous paths, limited use of mobile terminals, and poor user experience in the case of AR navigation of paths in the related art are solved, which not only improves the path flexibility and navigation efficiency, but also improves the user experience.
[0086] It should be noted that the specific examples in some other embodiments of the present application can refer to the examples described in the embodiment and optional implementation manner of the above-mentioned method for generating an AR navigation path, and this embodiment will not be repeated here.
[0087] In addition, it should be noted that the above modules can be functional modules or program modules, and can be implemented by software or hardware. For modules implemented by hardware, the above modules can be located in the same processor; or the above modules can be located in different processors in any combination.
[0088] This embodiment further provides an electronic device, including a memory and a processor, wherein the memory stores a computer program, and the processor is configured to run the computer program to execute the steps in any one of the above method embodiments.
[0089] Optionally, the electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor, and the input / output device is connected to the processor.
[0090] In addition, in combination with the method for generating an AR navigation path in the above embodiments, the present application embodiment may provide a storage medium for implementation. The storage medium stores a computer program; when the computer program is executed by a processor, any one of the methods for generating an AR navigation path in the above embodiments is implemented.
[0091] In one embodiment, a computer device is provided, which may be a terminal. The computer device includes a processor, a memory, a network interface, a display screen, and an input device connected via a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a method for generating an AR navigation path is implemented. The display screen of the computer device may be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device may be a touch layer covered on the display screen, or a button, a trackball or a touchpad provided on the housing of the computer device, or an external keyboard, touchpad or mouse, etc.
[0092] In one embodiment, Figure 8 is a schematic diagram of the internal structure of an electronic device according to an embodiment of the present application, such as Figure 8As shown, an electronic device is provided, which may be a server, and its internal structure diagram may be as shown in Figure 8 As shown. The electronic device includes a processor, a network interface, an internal memory and a non-volatile memory connected through an internal bus, wherein the non-volatile memory stores an operating system, a computer program and a database. The processor is used to provide computing and control capabilities, the network interface is used to communicate with an external terminal through a network connection, the internal memory is used to provide an environment for the operation of the operating system and the computer program, the computer program is executed by the processor to implement a method for generating an AR navigation path, and the database is used to store data.
[0093] Those skilled in the art will understand that Figure 8 The structure shown in the figure is merely a block diagram of a partial structure related to the scheme of the present application, and does not constitute a limitation on the electronic device to which the scheme of the present application is applied. The specific electronic device may include more or fewer components than shown in the figure, or combine certain components, or have a different arrangement of components.
[0094] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
[0095] Those skilled in the art should understand that the various technical features of the above-described embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the various technical features in the above-described embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0096] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the attached claims.
Claims
1. A method for generating an AR navigation path, It is characterized in that The method comprises: Acquire location information and area information of a starting point and an end point, and obtain an area from the starting point to the end point through an area search algorithm, wherein the areas passed through are connected by common edges; Obtaining a path consisting of vertices in the passed area by using a funnel algorithm, wherein the path consists of a plurality of continuous path vectors; Acquire adjacent vectors from the plurality of continuous path vectors and form a vector pair, calculate the angle between the vector pair, and move the vertices of the vector pair in the opposite direction along the angle by a target length to obtain a first path point, and generate a target path through the first path point; Traverse all continuous path vectors constituting the target path, and determine whether the path vector is located within the passable area; wherein determining whether the path vector is located within the passable area includes: determination condition 1: determining whether both ends of the path vector are located in the same passable area; determination condition 2: determining whether one end of the path vector is located within the passable area; determination condition 3: obtaining the common edge set of all adjacent areas between the area where the starting endpoint of the path vector is located and the area where the ending endpoint is located, and determining whether the path vector intersects with any common edge in the common edge set; When the path vectors all satisfy the judgment condition 1, the path vectors are all located inside the passable area, and the target path is output; In the case where the path vector does not satisfy the judgment condition 1, judging the judgment condition 2 includes: in the case where the judgment condition 2 is not satisfied, processing the path vector to obtain a new target path, or in the case where the judgment condition 2 is satisfied, judging the judgment condition 3 includes: in the case where the judgment condition 3 is satisfied, the path vectors are all located inside the passable area, and the target path is output, or in the case where the judgment condition 3 is not satisfied, processing the path vector to obtain a new target path; The step of processing the path vector to obtain a new target path includes: Inserting a second path point along the path vector and between two ends of the path vector, wherein the distance between the second path point and the end point of the path vector can be set by a user, and the maximum distance does not exceed the length of the path vector; A new target path is generated by the second path point, and it is determined whether all continuous path vectors in the new target path are located inside the traversable area, wherein the second path point is used as the starting point of the new path planning.
2. The method according to claim 1, It is characterized in that The step of moving the vertices of the vector pair in the opposite direction along the angle by a target length comprises: Obtaining the length of a common side of the vector pair, and comparing the length of the common side with a preset threshold; When it is determined that the length of the common side is greater than the preset threshold, the target length distance is half of the preset threshold; When it is determined that the length of the common side is less than the preset threshold, the target length distance is half of the length of the common side.
3. The method according to claim 1, It is characterized in that Before obtaining the location information of the starting point and the end point, the method includes: The scene map is divided into a plurality of traversable areas by a region segmentation algorithm, and the traversable areas are convex polygons.
4. A system for generating AR navigation paths, It is characterized in that The system comprises: An acquisition module is used to acquire the location information and area information of the starting point and the end point, and obtain the area passed from the starting point to the end point through an area search algorithm, wherein the passed areas are connected by common edges; A path generation module is used to obtain a path consisting of vertices in the passed area through a funnel algorithm, wherein the path consists of a plurality of continuous path vectors. Acquire adjacent vectors from the plurality of continuous path vectors and form a vector pair, calculate the angle between the vector pair, and move the vertices of the vector pair in the opposite direction along the angle by a target length to obtain a first path point, and generate a target path through the first path point; Traverse all continuous path vectors constituting the target path, and determine whether the path vector is located within the passable area; wherein determining whether the path vector is located within the passable area includes: determination condition 1: determining whether both ends of the path vector are located in the same passable area; determination condition 2: determining whether one end of the path vector is located within the passable area; determination condition 3: obtaining the common edge set of all adjacent areas between the area where the starting endpoint of the path vector is located and the area where the ending endpoint is located, and determining whether the path vector intersects with any common edge in the common edge set; When the path vectors all satisfy the judgment condition 1, the path vectors are all located inside the passable area, and the target path is output; In the case where the path vector does not satisfy the judgment condition 1, judging the judgment condition 2 includes: in the case where the judgment condition 2 is not satisfied, processing the path vector to obtain a new target path, or in the case where the judgment condition 2 is satisfied, judging the judgment condition 3 includes: in the case where the judgment condition 3 is satisfied, the path vectors are all located inside the passable area, and the target path is output, or in the case where the judgment condition 3 is not satisfied, processing the path vector to obtain a new target path; The step of processing the path vector to obtain a new target path includes: Inserting a second path point along the path vector and between two ends of the path vector, wherein the distance between the second path point and the end point of the path vector can be set by a user, and the maximum distance does not exceed the length of the path vector; A new target path is generated by the second path point, and it is determined whether all continuous path vectors in the new target path are located inside the traversable area, wherein the second path point is used as the starting point of the new path planning.
5. An electronic device comprising a memory and a processor, It is characterized in that A computer program is stored in the memory, and the processor is configured to run the computer program to execute the method for generating an AR navigation path according to any one of claims 1 to 3.
6. A storage medium, It is characterized in that The storage medium stores a computer program, wherein the computer program is configured to execute the method for generating an AR navigation path according to any one of claims 1 to 3 when running.
Citation Information
Patent Citations
Robot path planning method and dust collector with same
CN108827309A
A method of generating navigation path based on ground model
CN111815778A
Navigation path planning method and system of sweeping robot and electronic equipment
CN112180946A
Method and apparatus for trip routing with configurable constraints
US20080010006A1
KR20210007406A
