A multi-thread update method for pathfinding grid
An update method and multi-threaded technology, applied in the field of pathfinding, can solve the problem of high delay and achieve the effect of improving efficiency
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0047] like figure 1 As shown, a multi-thread update method for the pathfinding grid, including:
[0048] S110: Obtain pathfinding grid block information, where the pathfinding grid block information includes pathfinding grid block coordinates;
[0049] S120: Initiate an update task process to N sub-threads based on the coordinates of the pathfinding grid block, where N is an integer greater than 1.
[0050]Obtaining pathfinding grid block information, said pathfinding grid block information including: pathfinding grid block coordinates, height field data, success signal; assigning corresponding pathfinding grid block information in advance according to the number of threads in the multi-threaded computing architecture; The main thread collects the pathfinding grid block coordinates affected by obstacles into the corresponding pathfinding grid block information; initiates the pathfinding grid update task process on each sub-thread, and waits for the sub-thread to generate the...
Embodiment 2
[0052] like figure 2 As shown, a multi-thread update method for the pathfinding grid, including:
[0053] S210. Acquire pathfinding grid block information, where the pathfinding grid block information includes pathfinding grid block coordinates;
[0054] S220. Obtain obstacle information, where the obstacle information includes obstacle position and geometric information;
[0055] S230. According to the obstacle information, acquire the pathfinding grid block information that overlaps with the obstacle information, and the pathfinding grid block information also includes height field data and a completion signal, wherein the height The field data is composed of multiple voxels;
[0056] S240. Initiate an update task process to N sub-threads based on the pathfinding grid block coordinates, where N is an integer greater than 1.
[0057] It can be known from Embodiment 2 that when an obstacle is input into the map, the specific steps of obtaining the pathfinding grid block in...
Embodiment 3
[0059] like image 3 As shown, a multi-thread update method for the pathfinding grid, including:
[0060] S310. Acquire pathfinding grid block information, where the pathfinding grid block information includes pathfinding grid block coordinates;
[0061] S320. Based on the height field data, mark an obstacle coverage area, where the obstacle coverage area is used to represent impassable voxels;
[0062] S330. In the sub-thread, calculate and generate a new pathfinding grid block according to the obstacle coverage area, and send a completion signal to the main thread;
[0063] S340. After receiving the completion signals of the N sub-threads, the main thread sequentially integrates the new pathfinding grid block into the pathfinding grid block information.
[0064] In Embodiment 3, the pathfinding grid block information affected by obstacles is obtained; the pathfinding grid block information also includes the memory address of the newly generated pathfinding grid block, the ...
PUM
Login to View More Abstract
Description
Claims
Application Information
Login to View More 


