Graphics processing method and vehicle

By dividing the polygons of road-aware data into multiple tile areas in the vehicle perception system and performing ear-cut triangulation, the problem of low efficiency of polygon triangulation in the prior art is solved, and more efficient road-aware image generation and update are achieved.

CN119888127APending Publication Date: 2025-04-25CHENGDU GREAT WALL MOTOR R&D CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411863033.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-17
Publication Date
2025-04-25

AI Technical Summary

Technical Problem

In the prior art, when a vehicle triangulates polygons based on road perception data during driving, the efficiency is low, making it difficult to meet the timeliness requirements of road perception images in dynamic environments.

Method used

By dividing the polygons generated by road-aware data into multiple tile areas and performing ear-cut triangulation tasks based on these tile areas, the ear-shaped characteristics of the triangle are dynamically determined and verified, thereby improving the efficiency of triangulation.

Benefits of technology

Through fine spatial division and dynamic verification, this method significantly reduces the amount of calculation, improves the efficiency of polygon triangulation, and can generate and update road-aware images more quickly.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119888127A_ABST
    Figure CN119888127A_ABST
Patent Text Reader

Abstract

The invention provides a graph processing method and a vehicle, and the method is applied to the technical field of vehicles, and the method comprises the steps: obtaining road perception data collected by a target vehicle, and generating an initial polygon based on the road perception data; determining a bounding rectangle corresponding to the initial polygon, and determining a plurality of tile areas from the bounding rectangle; executing process information corresponding to an ear-cut triangulation task of the initial polygon based on the plurality of tile regions to obtain an ear-shaped triangle in the initial polygon; and determining a triangulation grid corresponding to the initial polygon based on the ear-shaped triangle, and rendering and displaying the road perception image based on the triangulation grid. On the basis of the scheme of the invention, more precise space division can be provided for the triangulation process by using the plurality of tile regions, the calculation amount can be reduced, and the efficiency of polygon triangulation can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of vehicle technology, and more specifically, to a graphics processing method and a vehicle in the field of vehicle technology. Background Art

[0002] At present, some vehicles with perception capabilities will display corresponding road perception images based on road perception data during driving, providing reference for drivers or providing decision-making basis for assisted driving systems. Before rendering the image, it is generally necessary to obtain polygons based on road perception data processing, and triangulate the polygons to obtain triangulated meshes, and use the triangulated meshes as one of the basic data for rendering the image. However, the environment in which the vehicle is located is dynamically changing, and the timeliness requirements for road perception images are relatively strong. Therefore, how to improve the efficiency of polygon triangulation has become an urgent problem to be solved. Summary of the invention

[0003] The present application provides a graphics processing method and a vehicle, which can utilize multiple tile areas to provide a more refined spatial division for the triangulation process, thereby helping to reduce the amount of calculation and improve the efficiency of polygon triangulation.

[0004] In a first aspect, a graphics processing method is provided, the method comprising:

[0005] Acquire road perception data collected by the target vehicle, and generate an initial polygon based on the road perception data;

[0006] Determine the bounding rectangle corresponding to the initial polygon, and determine multiple tile areas from the bounding rectangle;

[0007] Execute the process information corresponding to the ear-cut triangulation task of the initial polygon based on the multiple tile regions to obtain the ear-shaped triangle in the initial polygon;

[0008] A triangulated mesh corresponding to the initial polygon is determined based on the ear-shaped triangle, and a road perception image is rendered and displayed based on the triangulated mesh.

[0009] Through the above scheme, multiple tile areas provide a more refined spatial division for the triangulation process, which helps to reduce the amount of calculation and improve the efficiency of polygon triangulation.

[0010] In combination with the first aspect, in some possible implementations, performing process information corresponding to an ear-cut triangulation task of an initial polygon based on multiple tile regions to obtain an ear-shaped triangle in the initial polygon includes:

[0011] Determine the order of each vertex in the initial polygon based on a preset clock direction, and traverse each vertex in the initial polygon according to the order of each vertex in the initial polygon;

[0012] For the target vertex in the traversed initial polygon, determine the target iteration polygon corresponding to the target vertex based on the initial polygon, and determine the target triangle to be checked corresponding to the target vertex from the target iteration polygon;

[0013] Determine a target tile area corresponding to the target triangle to be checked from multiple tile areas, and check the target triangle to be checked based on the target tile area to determine whether the target triangle to be checked is an ear-shaped triangle corresponding to the target vertex;

[0014] If there is a determined ear-shaped triangle, and the determined ear-shaped triangle meets the preset conditions, the traversal of each vertex in the initial polygon is terminated.

[0015] Through the above scheme, the vertex order is first determined and traversed based on the preset clock direction, ensuring the consistency and orderliness of the processing. Secondly, for each traversed target vertex, the corresponding target iteration polygon and target triangle to be verified are dynamically determined. This dynamic processing method improves the flexibility and accuracy of the processing. Furthermore, the target triangle to be verified is verified through the target tile area, and it is quickly and accurately determined whether it is an ear-shaped triangle, which effectively avoids incorrect subdivision and ensures the correctness of triangulation. Finally, the end of the traversal is controlled by preset conditions, which not only ensures the integrity of the subdivision, but also avoids unnecessary calculations and improves processing efficiency.

[0016] In combination with the first aspect and the above implementation manner, in some possible implementation manners, determining a target iteration polygon corresponding to a target vertex based on an initial polygon includes:

[0017] If there is an ear-shaped triangle corresponding to a historical vertex that is before the target vertex, then the ear-shaped triangle corresponding to the historical vertex is removed from the initial polygon to obtain a target iteration polygon corresponding to the target vertex;

[0018] If there is no ear-shaped triangle corresponding to the historical vertex that is sequentially before the target vertex, the initial polygon is determined as the target iteration polygon corresponding to the target vertex.

[0019] Through the above scheme, when there are ear-shaped triangles corresponding to historical vertices, these identified ear-shaped triangles can be accurately removed from the initial polygon, so as to dynamically update the target iteration polygon, providing an accurate basis for subsequent processing. This dynamic update mechanism avoids repeated calculations and error accumulation, ensuring the correctness of the segmentation. At the same time, in the case where there are no ear-shaped triangles corresponding to historical vertices, the initial polygon is directly used as the target iteration polygon, which simplifies the processing flow and saves computing resources.

[0020] In combination with the first aspect and the above-mentioned implementation methods, in some possible implementation methods, a target triangle to be checked corresponding to a target vertex is determined from a target iteration polygon, including: determining two adjacent vertices that are sequentially adjacent to the target vertex from the target iteration polygon; and constructing a target triangle to be checked corresponding to the target vertex based on the target vertex and the two adjacent vertices.

[0021] Through the above scheme, by accurately comparing the order of vertices, the two adjacent vertices of the target vertex can be quickly located, providing an accurate basis for constructing the target triangle to be verified. Using the coordinate information of these three vertices to construct a triangle is not only intuitive and easy to implement, but also ensures that the constructed triangle matches the actual shape of the target iteration polygon.

[0022] In combination with the first aspect and the above-mentioned implementation methods, in some possible implementation methods, a target tile area corresponding to the target triangle to be checked is determined from multiple tile areas, and the target triangle to be checked is checked based on the target tile area to determine whether the target triangle to be checked is an ear-shaped triangle corresponding to the target vertex, including: from multiple tile areas, determining the tile area where the target vertex and two adjacent vertices sequentially adjacent to the target vertex are located as the target tile area; performing internal vertex check on the target triangle to be checked based on the target tile area to obtain the internal vertex check result of the target triangle to be checked; performing convexity check on the target triangle to be checked to obtain the convexity check result of the target triangle to be checked; if the internal vertex check result indicates that the interior of the target triangle to be checked contains vertices other than the target vertex and the two adjacent vertices sequentially adjacent to the target vertex, or the convexity check result indicates that the target triangle to be checked is not a convex triangle, then it is determined that the target triangle to be checked is not an ear-shaped triangle corresponding to the target vertex; if the internal vertex check result indicates that the interior of the target triangle to be checked does not contain vertices other than the target vertex and the two adjacent vertices, and the convexity check result indicates that the target triangle to be checked is a convex triangle, then it is determined that the target triangle to be checked is an ear-shaped triangle corresponding to the target vertex.

[0023] Through the above scheme, the target tile area is first determined to narrow the verification range and reduce the computational complexity. Then, the internal vertex check and convexity check are combined to comprehensively evaluate whether the target triangle to be verified meets the conditions of the ear-shaped triangle. The internal vertex check ensures that the closure and planarity of the polygon are not destroyed after the triangle is removed, while the convexity check ensures that the convexity of the polygon is maintained. This dual verification mechanism effectively avoids the misidentification of ear-shaped triangles and improves the accuracy of triangulation.

[0024] In combination with the first aspect and the above-mentioned implementation methods, in some possible implementation methods, the internal vertex verification result is divided into a first internal vertex verification result and a second internal vertex verification result; the internal vertex verification result of the target triangle to be verified is obtained based on the target tile area, including: determining a first-order verification vertex outside the target vertex and two adjacent vertices and located in the target tile area from multiple vertices in the target iteration polygon; if at least one first-order verification vertex is located inside the target triangle to be verified, a first internal vertex verification result is obtained; if the first-order verification vertex is not located inside the target triangle to be verified, determining a second-order verification vertex outside the target vertex and two adjacent vertices and not located in the target tile area from multiple vertices in the target iteration polygon; if at least one second-order verification vertex is located inside the target triangle to be verified, a first internal vertex verification result is obtained; if the second-order verification vertex is not located inside the target triangle to be verified, a second internal vertex verification result is obtained.

[0025] Through the above scheme, the concepts of first-order check vertices and second-order check vertices are introduced, and the internal vertex check of the triangle to be checked is performed in stages, taking into account both the vertices that are close in space and the vertices that may be far away, thereby comprehensively evaluating the internal situation of the triangle to be checked. This phased verification method not only reduces the risk of misjudgment, but also improves the precision of verification.

[0026] In combination with the first aspect and the above-mentioned implementation methods, in some possible implementation methods, if there is a determined ear-shaped triangle and the determined ear-shaped triangle meets the preset conditions, then the traversal of each vertex in the initial polygon is terminated, including: if there is a determined ear-shaped triangle and the number of determined ear-shaped triangles reaches a preset number threshold, then the traversal of each vertex in the initial polygon is terminated, and the preset number threshold is the number of vertices of the initial polygon minus two.

[0027] Through the above scheme, by setting the preset number threshold as the number of initial polygon vertices minus two, the quantitative relationship between the number of polygon vertices and the triangulation result is directly associated, ensuring the integrity and accuracy of the triangulation process. During the traversal process, the number of determined ear-shaped triangles is compared with the preset threshold, and the traversal is stopped once it is reached, avoiding unnecessary calculations and saving time costs.

[0028] In combination with the first aspect and the above implementations, in some possible implementations, generating an initial polygon based on road perception data includes: extracting road features from the road perception data; and generating an initial polygon based on the road features.

[0029] Through the above scheme, road features are extracted from road perception data, and initial polygons are generated based on the extracted road features, ensuring the closure and planarity of the initial polygons, accurately depicting the contours and position information of key elements such as roads, lane lines, obstacles, and drivable areas, and providing a precise foundation for subsequent graphics processing steps.

[0030] In combination with the first aspect and the above-mentioned implementation methods, in some possible implementation methods, the triangulation mesh corresponding to the initial polygon is determined based on the ear-shaped triangle, including: screening the ear-shaped triangles to obtain the target ear-shaped triangle, any internal angle of the target ear-shaped triangle is greater than a preset angle threshold; based on the target ear-shaped triangle, determining the triangulation mesh corresponding to the initial polygon.

[0031] Through the above scheme, by introducing a preset angle threshold to screen the ear-shaped triangles, those triangles that may have a negative impact on the rendering display can be effectively excluded, thereby obtaining a higher quality and more regular triangulation mesh.

[0032] In a second aspect, a graphics processing device is provided, the device comprising:

[0033] An acquisition unit, used to acquire road perception data collected by the target vehicle, and generate an initial polygon based on the road perception data;

[0034] A determination unit, used to determine a bounding rectangle corresponding to the initial polygon, and determine a plurality of tile areas from the bounding rectangle;

[0035] An execution unit, configured to execute process information corresponding to an ear-cut triangulation task of an initial polygon based on a plurality of tile regions, to obtain ear-shaped triangles in the initial polygon;

[0036] The display unit is used to determine a triangulated mesh corresponding to the initial polygon based on the ear-shaped triangle, and render and display the road perception image based on the triangulated mesh.

[0037] In a third aspect, a vehicle is provided, wherein the vehicle comprises:

[0038] A memory for storing executable program codes;

[0039] A processor is used to call and run the executable program code from the memory so that the vehicle executes the method in the above-mentioned first aspect or any possible implementation of the first aspect.

[0040] In a fourth aspect, a computer program product is provided, comprising: a computer program code, which, when executed on a computer, enables the computer to execute the method in the first aspect or any possible implementation of the first aspect.

[0041] In a fifth aspect, a computer-readable storage medium is provided, which stores a computer program code. When the computer program code runs on a computer, the computer executes the method in the above-mentioned first aspect or any possible implementation manner of the first aspect. BRIEF DESCRIPTION OF THE DRAWINGS

[0042] Figure 1 It is a schematic diagram of a scene of graphics processing provided by an embodiment of the present application;

[0043] Figure 2 It is a flowchart of a graphics processing method provided in an embodiment of the present application;

[0044] Figure 3 This is an example schematic diagram of determining a bounding rectangle and a tile area provided in an embodiment of the present application;

[0045] Figure 4 It is a schematic diagram of a process for performing an ear cutting triangulation task provided in an embodiment of the present application;

[0046] Figure 5 It is a schematic diagram of a process of verifying a target triangle provided by an embodiment of the present application;

[0047] Figure 6 is an example schematic diagram of performing ear-cut triangulation based on a tile region provided in an embodiment of the present application;

[0048] Figure 7 is an example schematic diagram of performing ear-cut triangulation based on a tile region provided in an embodiment of the present application;

[0049] Figure 8 is an example schematic diagram of performing ear-cut triangulation based on a tile region provided in an embodiment of the present application;

[0050] Fig. 9 It is a schematic diagram of a process for screening ear-shaped triangles provided in an embodiment of the present application;

[0051] Fig.10 is a structural schematic diagram of a graphics processing device provided in an embodiment of the present application;

[0052] Fig.11 It is a structural schematic diagram of a vehicle provided in an embodiment of the present application.

[0053] Description of Figure Numbers:

[0054] Label name Label name 001 vehicle 002 Polygon 003 Triangulation mesh 004A First tile area 004B Second tile area 004C Third tile area 004D Fourth tile area 002A First Iteration Polygon 002B Second Iteration Polygon DETAILED DESCRIPTION

[0055] The technical solution in the present application will be described clearly and in detail below in conjunction with the accompanying drawings. In the description of the embodiments of the present application, unless otherwise specified, " / " means or, for example, A / B can mean A or B: "and / or" in the text is only a description of the association relationship of associated objects, indicating that there can be three relationships, for example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. In addition, in the description of the embodiments of the present application, "multiple" means two or more than two.

[0056] In the following, the terms "first" and "second" are used for descriptive purposes only and should not be understood as suggesting or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features.

[0057] See also Figure 1 , Figure 1 It is a scene diagram of a graphic processing provided by an embodiment of the present application. With the development of autonomous driving and assisted driving technology, more and more vehicles 001 have perception capabilities. During driving, these vehicles 001 will display corresponding road perception images in real time based on road perception data, providing intuitive visual references for drivers, or providing accurate decision-making basis for assisted driving systems.

[0058] Before rendering the final road perception image, it is necessary to first process the road perception data to obtain polygons 002. These polygons 002 are usually extracted from the road perception data through a specific algorithm, and they can accurately depict key information such as roads, lane lines, obstacles, and drivable areas. However, polygons 002 themselves are not suitable for direct image rendering because they may contain a large number of vertices and edges, resulting in low rendering efficiency.

[0059] To this end, it is necessary to introduce triangulation technology. Triangulation is a process of dividing polygon 002 into a number of non-overlapping triangles. The collection of these triangles constitutes a triangulation mesh 003, which can completely cover the original polygon 002. Through triangulation, the complex polygon 002 is converted into a series of simple triangles, which greatly simplifies the subsequent rendering calculations. At the same time, as the most basic geometric unit, the triangle has the characteristics of simple calculation and high rendering efficiency.

[0060] However, in the dynamic environment where vehicle 001 is traveling, the timeliness of road perception images is extremely high. Vehicle 001 needs to perceive changes in the surrounding environment in real time and quickly generate accurate road perception images for the driver or the auxiliary driving system. This requires that the triangulation of polygon 002 must have a high efficiency to ensure real-time generation and updating of images. Therefore, how to improve the efficiency of triangulation of polygon 002 has become a problem that needs to be solved urgently.

[0061] In response to the above problems, the solution provided by the embodiment of the present application mainly includes: first, obtaining the road perception data collected by the target vehicle, and generating an initial polygon based on the road perception data. Then, determine the circumscribed rectangle corresponding to the initial polygon, and determine multiple tile areas from the circumscribed rectangle. Furthermore, based on the multiple tile areas, the process information corresponding to the ear-cut triangulation task of the initial polygon is executed to obtain the ear-shaped triangle in the initial polygon. Finally, based on the ear-shaped triangle, determine the triangulation mesh corresponding to the initial polygon, and render and display the road perception image based on the triangulation mesh. Among them, multiple tile areas provide a more refined spatial division for the triangulation process, which helps to reduce the amount of calculation and improve the efficiency of polygon triangulation.

[0062] based on Figure 1 The scene shown is shown below. Figure 2 - Fig. 9 , the graphics processing method provided in the embodiment of the present application is introduced in detail.

[0063] See also Figure 2 , Figure 2 A flowchart of a graphics processing method provided in an embodiment of the present application is shown in FIG. Figure 2 As shown, the method of the embodiment of the present application may include the following steps S101-S104.

[0064] S101, obtaining road perception data collected by a target vehicle, and generating an initial polygon based on the road perception data.

[0065] Specifically, the target vehicle involved in this embodiment is provided with relevant sensors for collecting road perception data. For example, when the sensor of the target vehicle includes a laser radar, the road perception data collected by the laser radar may be point cloud data, and the point cloud data may include three-dimensional coordinate information of the surrounding environment such as roads, lane lines, obstacles, and drivable areas. When the sensor of the target vehicle includes a camera, the road perception data collected by the camera may be image data, and the image data records the visual information of the surrounding environment such as roads, lane lines, obstacles, and drivable areas in the form of two-dimensional images. In addition, the target vehicle may also be equipped with other types of sensors, such as millimeter wave radar, ultrasonic radar, etc., which can also provide rich road perception data.

[0066] First, it is necessary to obtain the road perception data collected by the target vehicle. The acquisition process of road perception data can be carried out in real time, that is, the sensor continuously collects data during the vehicle's driving and transmits it to the relevant processing system through a data line or wireless network.

[0067] Then, the initial polygon is generated based on the road perception data. More specifically, road features can be extracted from the road perception data. These road features may include roads, lane lines, obstacles, drivable areas, etc. Using the road features, the initial polygon can be generated through a specific algorithm or model. The process can be expressed as: first pre-process the road perception data, such as denoising, filtering, etc.; then use the feature extraction algorithm to extract key road feature points (a form of road feature); finally, construct the initial polygon based on these road feature points.

[0068] It is understandable that a polygon is a closed, planar graphic composed of straight line segments connected end to end. In the processing of road perception images, the initial polygon is usually used to represent the contour and position information of key elements such as roads, lane lines, obstacles, and drivable areas, which is the basis for subsequent processing steps such as triangulation and rendering.

[0069] S102, determining a circumscribed rectangle corresponding to the initial polygon, and determining a plurality of tile areas from the circumscribed rectangle.

[0070] Specifically, the circumscribed rectangle corresponding to the initial polygon involved in this embodiment is a minimum rectangular figure with four sides that are tangent to or intersect with the initial polygon and can completely contain the initial polygon. The circumscribed rectangle provides a basic framework for subsequent tile area division.

[0071] Determine the circumscribed rectangle corresponding to the initial polygon, specifically by calculating the maximum and minimum x-coordinates (or horizontal coordinates) and the maximum and minimum y-coordinates (or vertical coordinates) of all vertices of the initial polygon, to determine the coordinates of the four corner points of the circumscribed rectangle. The four corner point coordinates correspond to the upper left corner, upper right corner, lower right corner and lower left corner of the circumscribed rectangle, respectively, thus forming a circumscribed rectangle that completely surrounds the initial polygon.

[0072] Further, a plurality of tile regions are determined from the bounding rectangle. The tile region refers to a plurality of small rectangular regions into which the bounding rectangle is divided according to certain rules. The size and number of tile regions can be adjusted according to actual needs, usually to divide a complex initial polygon into smaller, easier to handle parts.

[0073] The specific process of determining multiple tile areas from the bounding rectangle is as follows: First, the number of rows and columns of the tile area is calculated according to the size of the bounding rectangle and the preset tile size. Then, each tile area is divided in sequence from left to right and from top to bottom. Each tile area corresponds to a specific area in the bounding rectangle, and all tile areas together cover the entire bounding rectangle. When dividing the tile area, ensure that each tile area is completely inside the bounding rectangle and that the tile areas do not overlap.

[0074] by Figure 3 For example, Figure 3 : This is an example schematic diagram of determining a bounding rectangle and a tile area provided by an embodiment of the present application. Among them, the coordinates of the four corner points of the bounding rectangle 003 corresponding to the polygon 002 are determined by calculating the maximum and minimum x-coordinates (or horizontal coordinates) and the maximum and minimum y-coordinates (or vertical coordinates) of all vertices of the polygon 002. The bounding rectangle 003 is divided into four tile areas of the same size, namely the first tile area 004A, the second tile area 004B, the third tile area 004C, and the fourth tile area 004D. The multiple vertices of the polygon 002 are distributed in each tile area of ​​the bounding rectangle 003.

[0075] S103, executing process information corresponding to the ear-cut triangulation task of the initial polygon based on the multiple tile regions to obtain ear-shaped triangles in the initial polygon.

[0076] Specifically, multiple tile areas provide a more refined spatial division for the triangulation process, which helps to reduce the amount of calculation. After determining multiple tile areas, the process information corresponding to the ear-cut triangulation task of the initial polygon can be further executed based on the multiple tile areas. Among them, the process information corresponding to the ear-cut triangulation task of the initial polygon refers to a set of a series of steps to gradually identify and remove the "ear-shaped triangle" part of the initial polygon from the initial polygon until the entire initial polygon is completely decomposed into triangles. In the ear-cut triangulation, the "ear-shaped triangle" part refers to a triangle composed of a vertex and its two adjacent vertices, which will not destroy the closure and planarity of the polygon after removal.

[0077] During the execution of the process information corresponding to the ear-cut triangulation task of the initial polygon, multiple tile areas provide important basis for spatial division. Because in the ear-cut triangulation process, a series of triangles to be checked will be identified in the initial polygon, and these triangles to be checked need to be further determined whether they are ear-shaped triangles. Due to the existence of tile areas, in the process of determining whether the triangle to be checked is an ear-shaped triangle, the information corresponding to part of the tile area can be used as the basis for verification, without having to use the information corresponding to the entire initial polygon (or the iterative polygon that appears in the triangulation process of the initial polygon) as the basis for verification. In this way, the amount of calculation required for each verification can be significantly reduced, because the tile area is usually smaller than the entire initial polygon, thereby speeding up the ear-cut triangulation. At the same time, since the tile areas do not overlap, it can be ensured that the information provided by different tile areas does not overlap, avoiding repeated calculations.

[0078] After the process information corresponding to the ear-cut triangulation task of the initial polygon is executed, the ear-shaped triangles in the initial polygon can be obtained. Among them, the ear-shaped triangles in the initial polygon refer to the triangles composed of a vertex of the initial polygon and its two adjacent vertices that are identified and removed during the ear-cut triangulation process. These ear-shaped triangles are simple to calculate and easy to process, and their collection can completely cover the original polygon to form a triangulation mesh. Through ear-cut triangulation, complex polygons are converted into a series of simple triangles, which facilitates subsequent rendering and display.

[0079] S104, determining a triangulation grid corresponding to the initial polygon based on the ear-shaped triangle, and rendering and displaying the road perception image based on the triangulation grid.

[0080] Specifically, the number of ear-shaped triangles is generally multiple. Regarding determining the triangulation mesh corresponding to the initial polygon based on the ear-shaped triangles, in a possible implementation, all ear-shaped triangles can be directly combined to form a complete triangulation mesh by connecting their shared edges or vertices, that is, obtaining the triangulation mesh corresponding to the initial polygon.

[0081] In a possible implementation, the ear-shaped triangles may be screened to obtain target ear-shaped triangles, and the screening basis may include features such as shape, size, position, orientation, and internal angle of the ear-shaped triangles. After screening, all target ear-shaped triangles are combined and a complete triangulation mesh is formed by connecting their shared edges or vertices, that is, the triangulation mesh corresponding to the initial polygon is obtained.

[0082] After obtaining the triangulated mesh corresponding to the initial polygon, the road perception image can be rendered and displayed based on the triangulated mesh. The specific implementation method is as follows: First, each triangle in the triangulated mesh is used as a basic rendering unit, and the graphics rendering engine is used to render according to the vertex coordinates, color, texture and other properties of the triangle. Then, the rendered triangles are combined to form a complete road perception image. Finally, the road perception image is output to a display screen (which can be the display screen of the target vehicle) for use by the user (which can be the driver) or the auxiliary driving system.

[0083] In a possible implementation, the vertices involved in this embodiment are stored in the form of a linked list array. Among them, the linked list array refers to a data structure that combines the characteristics of an array with a linked list, retaining the advantages of fast random access of an array and having the ability of a linked list to flexibly insert and delete elements. In the linked list array, each element is a node, and the node stores data (in this case, vertex information) and a pointer to the next node. In this way, all nodes can be connected in series through a pointer to form a linked list, and the entire linked list can be accessed and managed in the form of an array. The vertices involved in this embodiment have specific positions and orders, so they can be stored in different nodes in the linked list array respectively. Each node corresponds to a vertex, and the node stores the coordinates, color, texture and other attribute information of the vertex, as well as a pointer to the next vertex. Using the form of a linked list array to store vertices can accelerate the traversal and access speed of vertices, because the linked list array combines the advantages of arrays and linked lists, supporting both fast random access and flexible insertion and deletion operations. This is beneficial for subsequent processing steps such as triangulation and rendering display, because vertex information can be quickly accessed and processed, improving the efficiency of the entire graphics processing method.

[0084] In a possible implementation, the UnityMath library is used to accelerate the efficiency of floating-point operations. Wherein, the UnityMath library refers to a mathematical operation library provided in the Unity game engine, which contains a series of efficient mathematical operation functions and algorithms, specifically used to process common mathematical operation tasks such as floating-point operations, vector operations, matrix operations, etc. The UnityMath library is highly optimized and can make full use of the computing power of the hardware to provide extremely high computing efficiency. The UnityMath library is referenced in the scheme of this embodiment, which can accelerate floating-point operations. In this embodiment, a large number of floating-point operations are involved, such as vertex coordinate calculations, triangle area calculations, vector dot product and cross product calculations, etc. If these operations directly use standard floating-point operation functions, a large amount of computing time and resources may be consumed. After introducing the UnityMath library, the efficient operation functions and algorithms provided by it can be used to significantly speed up the speed of these floating-point operations, thereby improving the efficiency of the entire graphics processing method. For example, the vector operation function in the UnityMath library can quickly calculate the length of a vector, normalize a vector, calculate the dot product and cross product of two vectors, etc., and these operations are also one of the key factors affecting the processing speed. By introducing the UnityMath library, these problems can be effectively solved and the efficiency and quality of graphics processing can be improved.

[0085] In this embodiment, the road perception data collected by the target vehicle is first obtained, and an initial polygon is generated based on the road perception data. Then, the circumscribed rectangle corresponding to the initial polygon is determined, and multiple tile areas are determined from the circumscribed rectangle. Furthermore, the process information corresponding to the ear-cut triangulation task of the initial polygon is executed based on the multiple tile areas to obtain the ear-shaped triangle in the initial polygon. Finally, the triangulation mesh corresponding to the initial polygon is determined based on the ear-shaped triangle, and the road perception image is rendered and displayed based on the triangulation mesh. Among them, multiple tile areas provide a more refined spatial division for the triangulation process, which helps to reduce the amount of calculation and improve the efficiency of polygon triangulation.

[0086] In one embodiment, Figure 2 The “generating an initial polygon based on road perception data” in step S101 of the illustrated embodiment is further refined to obtain the following steps:

[0087] Extracting road features from road perception data;

[0088] Generate initial polygons based on road features.

[0089] Specifically, the road features involved in this embodiment refer to the outline, position, shape, size and mutual relationship of key elements such as roads, lane lines, obstacles and drivable areas. These road features are the basis for forming the initial polygon.

[0090] Regarding the process of extracting road features from road perception data, first, the road perception data is preprocessed, including denoising and filtering, to improve the quality and accuracy of the data. Then, feature extraction algorithms, such as edge detection algorithms and region growing algorithms, are used to extract key road feature points from the preprocessed road perception data, where road feature points may include turning points of the road, intersections of lane lines, contour points of obstacles, etc. By connecting road feature points, contour segments describing key elements such as roads, lane lines, obstacles, and drivable areas can be formed.

[0091] Regarding the process of generating initial polygons based on road features, firstly, the initial polygons are constructed based on the extracted road features using polygon generation algorithms, such as the convex hull algorithm and the Graar algorithm. During the construction process, it is ensured that the initial polygons are closed and planar, and are composed of straight line segments connected end to end. At the same time, the initial polygons need to accurately depict the contours and location information of key elements such as roads, lane lines, obstacles, and drivable areas.

[0092] In this embodiment, the process of first extracting road features from road perception data effectively removes noise and redundant information through preprocessing and feature extraction algorithms, retains key road feature points, and improves data accuracy and reliability. Secondly, the initial polygon is generated based on the extracted road features. The polygon generation algorithm is used to ensure the closure and planarity of the initial polygon, and it is composed of straight line segments connected end to end, which conforms to the basic definition and properties of polygons. At the same time, the initial polygon accurately depicts the contours and position information of key elements such as roads, lane lines, obstacles, and drivable areas, providing an accurate basis for subsequent graphics processing steps.

[0093] See also Figure 4 , which is a schematic diagram of a process for performing an ear cutting triangulation task according to an embodiment of the present application, such as Figure 4 As shown, the method of the embodiment of the present application may include the following steps S201-S204, and steps S201-S204 may be used as Figure 2 The detailed steps of step S103 of the illustrated embodiment.

[0094] S201, determining the order of each vertex in the initial polygon based on a preset clock direction, and traversing each vertex in the initial polygon according to the order of each vertex in the initial polygon;

[0095] S202, for a target vertex in the traversed initial polygon, determine a target iteration polygon corresponding to the target vertex based on the initial polygon, and determine a target triangle to be checked corresponding to the target vertex from the target iteration polygon;

[0096] S203, determining a target tile region corresponding to the target triangle to be checked from the multiple tile regions, and checking the target triangle to be checked based on the target tile region to determine whether the target triangle to be checked is an ear-shaped triangle corresponding to the target vertex;

[0097] S204: If there is a determined ear-shaped triangle, and the determined ear-shaped triangle meets the preset conditions, then the traversal of each vertex in the initial polygon is terminated.

[0098] Specifically, the preset clock direction involved in this embodiment can be divided into a clockwise direction and a counterclockwise direction. Therefore, the order of the vertices in the initial polygon is determined based on the preset clock direction, specifically: first select a starting vertex in the initial polygon, and then determine the order of other vertices in the initial polygon in turn according to the preset clock direction (clockwise or counterclockwise). This starting vertex can be any vertex in the initial polygon, and the selection method can be random or based on a certain rule (such as selecting the leftmost vertex as the starting point).

[0099] Then, the vertices in the initial polygon are traversed according to the order of the vertices in the initial polygon, that is, starting from the starting vertex, each vertex in the initial polygon is visited in turn according to the determined order of the vertices, and subsequent processing steps (such as steps S202-S204) are performed on each vertex.

[0100] For the target vertex in the traversed initial polygon, the target iteration polygon corresponding to the target vertex is determined based on the initial polygon. The iteration polygon refers to a polygon obtained by continuously removing the determined ear-shaped triangles from the initial polygon during the ear-cut triangulation process. The target iteration polygon corresponding to the target vertex refers to the polygon remaining after all the previously determined ear-shaped triangles have been removed from the initial polygon when the target vertex is currently traversed.

[0101] Determine the target triangle to be checked corresponding to the target vertex from the target iteration polygon, specifically: determine the target vertex and two adjacent vertices sequentially adjacent to the target vertex from the target iteration polygon, these three vertices constitute a triangle, which is the target triangle to be checked.

[0102] It is understandable that the target triangle to be checked may be an ear-shaped triangle or may not be an ear-shaped triangle. To this end, it is necessary to determine the target tile area corresponding to the target triangle to be checked from multiple tile areas. The target tile area can be the tile area where the vertex of the target triangle to be checked is located, or it can be a tile area that overlaps with the target triangle to be checked (i.e., has at least one common point or one common edge).

[0103] During the verification process, the target tile area provides the information required for verification. By using this information, it can be determined whether the target triangle to be verified meets the conditions of the ear-shaped triangle, that is, whether the removal of the triangle will destroy the closure and planarity of the polygon. After verification, it can be determined whether the target triangle to be verified is the ear-shaped triangle corresponding to the target vertex.

[0104] Furthermore, if there are confirmed ear-shaped triangles, and the confirmed ear-shaped triangles meet the preset conditions (such as the number reaches a certain threshold, or the entire initial polygon has been completely decomposed into triangles, etc.), the traversal of the vertices in the initial polygon is terminated. At this point, the ear-cut triangulation process has been completed, and the triangulation mesh corresponding to the initial polygon can be obtained. If there are no confirmed ear-shaped triangles, or there are confirmed ear-shaped triangles but the confirmed ear-shaped triangles do not meet the preset conditions, it is necessary to continue to traverse the next vertex in the initial polygon, and repeat steps S202-S204 until the end condition is met.

[0105] In this embodiment, firstly, the vertex order is determined and traversed based on the preset clock direction, thereby ensuring the consistency and orderliness of the processing. Secondly, for each traversed target vertex, its corresponding target iteration polygon and target triangle to be verified are dynamically determined. This dynamic processing method improves the flexibility and accuracy of the processing. Furthermore, the target triangle to be verified is verified through the target tile area, and it is quickly and accurately determined whether it is an ear-shaped triangle, which effectively avoids incorrect triangulation and ensures the correctness of the triangulation. Finally, the end of the traversal is controlled by preset conditions, which not only ensures the integrity of the triangulation, but also avoids unnecessary calculations and improves the processing efficiency. On the whole, this embodiment not only improves the accuracy and efficiency of triangulation, but also provides a reliable foundation for subsequent graphics processing and calculations.

[0106] In one embodiment, Figure 4 Further refinement of "determining the target iteration polygon corresponding to the target vertex based on the initial polygon" in step S202 of the illustrated embodiment can provide the following steps:

[0107] If there is an ear-shaped triangle corresponding to a historical vertex that is before the target vertex, then the ear-shaped triangle corresponding to the historical vertex is removed from the initial polygon to obtain a target iteration polygon corresponding to the target vertex;

[0108] If there is no ear-shaped triangle corresponding to the historical vertex that is sequentially before the target vertex, the initial polygon is determined as the target iteration polygon corresponding to the target vertex.

[0109] Specifically, the historical vertices of this embodiment refer to the vertices in the initial polygon that are before the target vertex in sequence. Since the traversal process is performed according to the order of each vertex, the historical vertices can also be regarded as vertices that have been traversed.

[0110] If there are ear-shaped triangles corresponding to historical vertices, it means that some ear-shaped triangles have been identified and removed during the previous traversal process, so the current target iteration polygon is the result of the initial polygon after removing these ear-shaped triangles. It is necessary to remove the ear-shaped triangles corresponding to the historical vertices from the initial polygon to obtain the target iteration polygon corresponding to the target vertex. Specifically, first locate the ear-shaped triangles corresponding to the historical vertices. These triangles are composed of the historical vertices and their two adjacent vertices, and have been confirmed as ear-shaped triangles. Then, by updating the vertex list or edge list of the polygon, these ear-shaped triangles are removed from the initial polygon to obtain a new polygon, that is, the target iteration polygon corresponding to the target vertex. This new polygon will serve as the basis for subsequent processing to continue to identify and remove other ear-shaped triangles.

[0111] In some possible implementations, the historical vertices corresponding to the ear-shaped triangle can also be recorded, the historical vertices corresponding to the ear-shaped triangle can be removed from the vertex set of the initial polygon, and the target iterative polygon corresponding to the target vertex can be constructed based on the remaining vertices after removing the historical vertices corresponding to the ear-shaped triangle.

[0112] If there is no ear-shaped triangle corresponding to the historical vertex, it means that no ear-shaped triangle was identified and removed during the previous traversal process, or the current target vertex is the first vertex in the traversal process. The initial polygon needs to be determined as the target iteration polygon corresponding to the target vertex. Specifically, the initial polygon is directly used as the current target iteration polygon without any removal operation. In this case, the target iteration polygon is exactly the same as the initial polygon, and subsequent processing will be based on this initial polygon to identify and remove the ear-shaped triangle.

[0113] In this embodiment, when there are ear-shaped triangles corresponding to historical vertices, these identified ear-shaped triangles can be accurately removed from the initial polygon, thereby dynamically updating the target iterative polygon, providing an accurate basis for subsequent processing. This dynamic update mechanism avoids repeated calculations and error accumulation, ensuring the correctness of the segmentation. At the same time, in the case where there are no ear-shaped triangles corresponding to historical vertices, the initial polygon is directly used as the target iterative polygon, which simplifies the processing flow and saves computing resources. In addition, this embodiment also takes into account the sequential nature of the traversal process, and uses the information of historical vertices to guide the determination of the current target iterative polygon, thereby improving the consistency of the processing.

[0114] In one embodiment, Figure 4 The step S202 of the embodiment shown in the figure is further refined to obtain the following steps:

[0115] From the target iteration polygon, determine two adjacent vertices that are sequentially adjacent to the target vertex;

[0116] Construct a target triangle to be checked corresponding to the target vertex according to the target vertex and two adjacent vertices.

[0117] Specifically, from the target iteration polygon, determine two adjacent vertices in order to the target vertex, that is, compare the order of the target vertex with the order of other vertices in the target iteration polygon except the target vertex, and find two vertices in order adjacent to the current target vertex in the target iteration polygon according to the comparison result.

[0118] The target triangle to be verified corresponding to the target vertex is constructed according to the target vertex and its two adjacent vertices, that is, a triangle can be clearly defined using the coordinate information of these three vertices. In a two-dimensional plane, a triangle is uniquely determined by three non-collinear points. Therefore, by connecting the target vertex and its two adjacent vertices, the target triangle to be verified corresponding to the target vertex is constructed. This triangle will be used in the next step to verify whether it is an ear-shaped triangle, that is, to determine whether removing this triangle will destroy the closure and planarity of the target iterative polygon. If it is an ear-shaped triangle, it will be removed in the subsequent triangulation process, thereby gradually decomposing the initial polygon into smaller triangles until the entire polygon is completely triangulated.

[0119] In this embodiment, by accurately comparing the order of vertices, two adjacent vertices of the target vertex are quickly located, providing an accurate basis for constructing the target triangle to be verified. Using the coordinate information of these three vertices to construct a triangle is not only intuitive and easy to implement, but also ensures that the constructed triangle matches the actual shape of the target iteration polygon. This refinement process makes the subsequent ear-shaped triangle verification more accurate, effectively avoids incorrect triangulation, and ensures the correctness of triangulation.

[0120] In one embodiment, Figure 4 The step S204 of the embodiment shown is further refined to obtain the following steps:

[0121] If there are confirmed ear-shaped triangles, and the number of confirmed ear-shaped triangles reaches a preset number threshold, the traversal of each vertex in the initial polygon is terminated, and the preset number threshold is the number of vertices of the initial polygon minus two.

[0122] Specifically, the preset quantity threshold involved in this embodiment refers to a quantity standard determined according to the number of vertices of the initial polygon and used to determine whether the ear-cut triangulation is completed. This quantity standard is based on a basic property of polygon triangulation: a polygon with n vertices can be decomposed into n-2 triangles through ear-cut triangulation. Therefore, the preset quantity threshold is set to the number of vertices of the initial polygon minus two, that is, when the number of determined ear-shaped triangles reaches this threshold, it means that the initial polygon has been completely decomposed into triangles, and the ear-cut triangulation process can be ended.

[0123] In the last step of each traversal, if there are determined ear-shaped triangles, then it is necessary to compare the number of determined ear-shaped triangles with the preset number threshold. The purpose of this comparison is to determine whether the ear-cut triangulation has been completed, that is, whether the initial polygon has been completely decomposed into triangles. If the number of determined ear-shaped triangles is equal to the preset number threshold, then it means that the ear-cut triangulation has been completed, and the traversal of each vertex in the initial polygon can be ended. At this point, the initial polygon has been completely decomposed into a series of non-overlapping triangles, and the collection of these triangles constitutes the triangulation mesh corresponding to the initial polygon. If the number of determined ear-shaped triangles has not reached the preset number threshold, then it means that the ear-cut triangulation has not been completed, and it is necessary to continue to traverse the next vertex in the initial polygon and repeat the relevant steps of the ear-cut triangulation until the number of determined ear-shaped triangles reaches the preset number threshold.

[0124] In this embodiment, by setting the preset number threshold to the number of initial polygon vertices minus two, the quantitative relationship between the number of polygon vertices and the triangulation result is directly associated, ensuring the integrity and accuracy of the triangulation process. During the traversal process, the number of ear-shaped triangles that have been determined is compared with the preset threshold in real time. Once the threshold is reached, the traversal is stopped, avoiding unnecessary calculations and saving time costs.

[0125] See also Figure 5 , a schematic diagram of a process for verifying a target triangle is provided for an embodiment of the present application, such as Figure 5 As shown, the method of the embodiment of the present application may include the following steps S301-S305, and steps S301-S305 may be used as Figure 4 The detailed steps of step S203 in the illustrated embodiment.

[0126] S301, determining, from a plurality of tile regions, a tile region where a target vertex and two adjacent vertices sequentially adjacent to the target vertex are located as a target tile region;

[0127] S302, performing internal vertex verification on the target triangle to be verified based on the target tile area to obtain an internal vertex verification result of the target triangle to be verified;

[0128] S303, performing convexity check on the target triangle to be checked, and obtaining a convexity check result of the target triangle to be checked;

[0129] S304, if the internal vertex check result indicates that the interior of the target triangle to be checked contains vertices other than the target vertex and two adjacent vertices sequentially adjacent to the target vertex, or the convexity check result indicates that the target triangle to be checked is not a convex triangle, then determine that the target triangle to be checked is not an ear-shaped triangle corresponding to the target vertex;

[0130] S305, if the internal vertex check result indicates that the interior of the target triangle to be checked does not contain vertices other than the target vertex and two adjacent vertices, and the convexity check result indicates that the target triangle to be checked is a convex triangle, then determine that the target triangle to be checked is an ear-shaped triangle corresponding to the target vertex.

[0131] Specifically, with respect to determining the target vertex and the tile region where two adjacent vertices sequentially adjacent to the target vertex are located from multiple tile regions as the target tile region, first, based on the coordinate information of the target vertex and its adjacent vertices, the positions of these vertices in the multiple tile regions are located. Then, the tile regions containing the target vertex and its adjacent vertices are selected, and these tile regions are determined as the target tile regions. The target tile region may be one or more, depending on the distribution of the target vertex and its adjacent vertices and the division method of the tile region.

[0132] Furthermore, an internal vertex check is performed on the target triangle to be checked based on the target tile area to obtain an internal vertex check result of the target triangle to be checked. The internal vertex check refers to checking whether the interior of the target triangle to be checked contains other vertices except the target vertex and its adjacent vertices within the target tile area. This check process is to ensure that the target triangle to be checked will not destroy the closure and planarity of the polygon after removal, because if there are other vertices, then removing the target triangle to be checked may leave a hole or generate new edges, thereby destroying the structure of the polygon.

[0133] Furthermore, a convexity check is performed on the target triangle to be checked to obtain the convexity check result of the target triangle to be checked. Convexity check refers to determining whether the target triangle to be checked is a convex triangle. A convex triangle means that the lines connecting any point inside the triangle to the three vertices of the triangle are located inside or on the edge of the triangle, that is, the triangle has no concave part. Convexity check is to ensure that the target triangle to be checked can maintain the convexity of the polygon after removal, because convex polygons have some good properties, such as easy processing and high rendering efficiency. The convex triangle in the convexity check process refers to the triangle that meets the above definition of convexity.

[0134] It can be understood that the internal vertex check result of the target triangle to be checked indicates whether the interior of the target triangle to be checked contains vertices other than the target vertex and two adjacent vertices, which is an important condition for determining whether the target triangle to be checked is an ear-shaped triangle. The convexity check result of the target triangle to be checked indicates whether the target triangle to be checked is a convex triangle, which is another important condition for determining whether the target triangle to be checked is an ear-shaped triangle.

[0135] If the internal vertex check result indicates that the interior of the target triangle to be checked contains vertices other than the target vertex and two adjacent vertices in sequence to the target vertex, or the convexity check result indicates that the target triangle to be checked is not a convex triangle, then it can be determined that the target triangle to be checked is not an ear-shaped triangle corresponding to the target vertex. Because in both cases, removing the target triangle to be checked will destroy the closure, planarity or convexity of the polygon, and thus does not meet the definition of an ear-shaped triangle.

[0136] If the internal vertex check result indicates that the interior of the target triangle to be checked does not contain vertices other than the target vertex and two adjacent vertices, and the convexity check result indicates that the target triangle to be checked is a convex triangle, then it can be determined that the target triangle to be checked is an ear-shaped triangle corresponding to the target vertex. Because in both cases, after removing the target triangle to be checked, the polygon still maintains closure, planarity and convexity, satisfying the definition of an ear-shaped triangle.

[0137] In this embodiment, the target tile area is first determined to narrow the verification range and reduce the computational complexity. Then, the target triangle to be verified is comprehensively evaluated to see whether it meets the conditions of an ear-shaped triangle by combining the internal vertex verification and the convexity verification. The internal vertex verification ensures that the closure and planarity of the polygon are not destroyed after the triangle is removed, while the convexity verification ensures that the convexity of the polygon is maintained. This dual verification mechanism effectively avoids the misidentification of ear-shaped triangles and improves the accuracy of triangulation.

[0138] In one embodiment, based on Figure 5In the embodiment shown, the internal vertex check result is divided into a first internal vertex check result and a second internal vertex check result. Figure 5 The step S302 of the embodiment shown is further refined to obtain the following steps:

[0139] From a plurality of vertices in the target iteration polygon, determine a first-order check vertex that is outside the target vertex and two adjacent vertices and is located in the target tile area;

[0140] If at least one first-order check vertex is located inside the target triangle to be checked, a first internal vertex check result is obtained;

[0141] If the first-order check vertex is not located inside the target to-be-checked triangle, then determine a second-order check vertex that is outside the target vertex and two adjacent vertices and is not located in the target tile area from multiple vertices in the target iteration polygon;

[0142] If at least one second-order check vertex is located inside the target triangle to be checked, a first internal vertex check result is obtained;

[0143] If the second-order check vertex is not located inside the target triangle to be checked, a second internal vertex check result is obtained.

[0144] Specifically, due to the existence of the tile area, the triangulation process can verify whether the triangle to be verified is an ear-shaped triangle in stages. First, from multiple vertices in the target iteration polygon, determine the first-order verification vertex that is outside the target vertex and two adjacent vertices and is located in the target tile area. Among them, the first-order verification vertex is considered as the verification object first because it is close to the target triangle to be verified in space.

[0145] Furthermore, it is necessary to determine whether at least one first-order check vertex is located inside the target triangle to be checked. The determination process is implemented as follows: for each first-order check vertex, use its coordinate information and the coordinate information of the three vertices of the target triangle to be checked (i.e., the target vertex and its two adjacent vertices) to determine the geometric position relationship. Specifically, it is possible to determine whether the first-order check vertex is located inside the target triangle to be checked by calculating the positional relationship between the first-order check vertex and each edge of the target triangle to be checked (such as on the left side, right side, or on the edge), or by using methods such as vector cross multiplication.

[0146] If at least one first-order check vertex is located inside the target triangle to be checked, then a first internal vertex check result is obtained. The first internal vertex check result indicates that the interior of the target triangle to be checked contains vertices other than the target vertex and two adjacent vertices. It can be seen that the target triangle to be checked does not meet the conditions of an ear-shaped triangle because removing it will destroy the closure of the polygon.

[0147] If the first-order check vertex is not located inside the target triangle to be checked, then a second-order check vertex outside the target vertex and two adjacent vertices and not located in the target tile area is determined from multiple vertices in the target iteration polygon. The second-order check vertex refers to a vertex that may be far away from the target triangle to be checked in space, but still needs to be considered as a check object to ensure that the target triangle to be checked is a true ear-shaped triangle.

[0148] If at least one second-order check vertex is located inside the target triangle to be checked, then the first internal vertex check result is obtained, and it can be seen that the target triangle to be checked also does not meet the conditions of an ear-shaped triangle. If the second-order check vertex is not located inside the target triangle to be checked, then the second internal vertex check result is obtained. Among them, the second internal vertex check result indicates that the interior of the target triangle to be checked does not contain vertices other than the target vertex and two adjacent vertices. It can be seen that the target triangle to be checked meets a necessary condition for an ear-shaped triangle, that is, removing it will not destroy the closure of the polygon. However, further convexity verification is required to finally determine whether it is an ear-shaped triangle.

[0149] For easier understanding of this embodiment, please refer to Figure 6 - Figure 8 , Figure 6 - Figure 8 These are all example schematic diagrams of performing ear-cut triangulation based on tile regions provided in an embodiment of the present application.

[0150] exist Figure 6 In the figure, polygon 002 has 10 vertices in total, and the order of the vertices is determined in a counterclockwise direction, namely vertex 1, vertex 2, vertex 3, vertex 4, vertex 5, vertex 6, vertex 7, vertex 8, vertex 9, and vertex 10. The circumscribed rectangle 003 of polygon 002 is divided into a first tile area 004A, a second tile area 004B, a third tile area 004C, and a fourth tile area 004D.

[0151] The traversal process starts from vertex 1, and the vertices adjacent to vertex 1 in sequence are vertex 2 and vertex 10, so vertex 1, vertex 2, and vertex 10 are connected to form a triangle to be checked. Further, the first tile area 004A and the fourth tile area 004D where vertex 1, vertex 2, and vertex 10 are located are determined, and vertices 8 and vertices 9 outside vertex 1, vertex 2, and vertex 10 are determined from the first tile area 004A and the fourth tile area 004D. Through further judgment, it can be determined that vertex 9 falls in the triangle to be checked formed by vertex 1, vertex 2, and vertex 10, that is, the triangle to be checked formed by vertex 1, vertex 2, and vertex 10 is not an ear-shaped triangle. At this time, there is no need to confirm whether the vertices in the second tile area 004B and the third tile area 004C fall in the triangle to be checked formed by vertex 1, vertex 2, and vertex 10, which speeds up the verification to a certain extent.

[0152] Similarly, when traversing to vertex 2, the vertices adjacent to vertex 1 in sequence are vertex 1 and vertex 3, respectively. Then, vertex 2, vertex 1, and vertex 3 are connected to form a triangle to be checked. Further, the first tile area 004A and the second tile area 004B where vertex 2, vertex 1, and vertex 3 are located are determined, and vertices 8 and vertices 9 outside of vertex 2, vertex 1, and vertex 3 are determined from the first tile area 004A and the second tile area 004B. Through further judgment, it can be determined that vertex 8 falls in the triangle to be checked formed by vertex 2, vertex 1, and vertex 3, that is, the triangle to be checked formed by vertex 2, vertex 1, and vertex 3 is not an ear-shaped triangle. At this time, there is no need to confirm whether the vertices in the third tile area 004C and the fourth tile area 004D fall in the triangle to be checked formed by vertex 2, vertex 1, and vertex 3, which speeds up the verification to a certain extent.

[0153] Similarly, when traversing to vertex 3, the vertices adjacent to vertex 3 in sequence are vertex 2 and vertex 4, then vertex 3, vertex 2, and vertex 4 can be connected to form a triangle to be checked. Obviously, the triangle to be checked formed by vertex 3, vertex 2, and vertex 4 does not meet the characteristics of a convex triangle, so the triangle to be checked formed by vertex 3, vertex 2, and vertex 4 is not an ear-shaped triangle.

[0154] Similarly, when traversing to vertex 4, the vertices adjacent to vertex 4 in sequence are vertex 3 and vertex 5, respectively. Then, vertex 4, vertex 3, and vertex 5 are connected to form a triangle to be checked. Further, the second tile area 004B and the third tile area 004C where vertex 4, vertex 3, and vertex 5 are located are determined, and vertices 6 and vertex 7 outside vertex 4, vertex 3, and vertex 5 are determined from the second tile area 004B and the third tile area 004C. Through further judgment, it can be determined that vertex 6 and vertex 7 do not fall in the triangle to be checked formed by vertex 4, vertex 3, and vertex 5. At this time, it can be further determined that vertex 1, vertex 2, vertex 8, vertex 1, and vertex 10 in the first tile area 004A and the fourth tile area 004D do not fall in the triangle to be checked formed by vertex 4, vertex 3, and vertex 5. It can be seen that the triangle to be checked formed by vertex 4, vertex 3, and vertex 5 meets the requirement that no other vertices are contained inside. On the other hand, the triangle to be checked formed by vertex 4, vertex 3, and vertex 5 meets the characteristics of a convex triangle, so the triangle to be checked formed by vertex 4, vertex 3, and vertex 5 is an ear-shaped triangle.

[0155] When traversing to vertex 5, Figure 6 After the to-be-checked triangle consisting of vertices 4, 3, and 5 is split (it can also be considered as deleting vertex 4), we get Figure 7 The first iteration polygon 002A corresponding to vertex 5. Based on the above similar method, the to-be-checked triangle formed by vertex 5, vertex 3 and vertex 6 is determined, and it is determined that the to-be-checked triangle formed by vertex 5, vertex 3 and vertex 6 is an ear-shaped triangle.

[0156] When traversing to vertex 6, Figure 7 After the triangle to be checked consisting of vertex 5, vertex 3, and vertex 6 is split (it can also be regarded as deleting vertex 5), we get Figure 8 The second iteration polygon 002B corresponding to the vertex 6. Based on the above similar method, the to-be-checked triangle formed by the vertex 6, the vertex 3 and the vertex 7 is determined, and it is determined that the to-be-checked triangle formed by the vertex 6, the vertex 3 and the vertex 7 is an ear-shaped triangle.

[0157] Based on the above Figure 6 - Figure 8 Continue traversing in a similar manner and eventually obtain the triangulated mesh corresponding to polygon 002.

[0158] In this embodiment, by introducing the concepts of first-order check vertices and second-order check vertices, the internal vertex check of the triangle to be checked is performed in stages, taking into account both the vertices that are close in space and the vertices that may be far away, thereby comprehensively evaluating the internal situation of the triangle to be checked. This staged verification method not only reduces the risk of misjudgment, but also improves the precision of the verification. At the same time, the geometric position relationship is used to determine whether the vertex is located inside the triangle, ensuring the accuracy and efficiency of the verification.

[0159] See also Fig. 9 , a schematic diagram of a process for screening ear-shaped triangles is provided for an embodiment of the present application, such as Fig. 9 As shown, the method of the embodiment of the present application may include the following steps S401-S402, and steps S401-S402 may be used as Figure 2 The illustrated embodiment shows a refinement step of step S104 of "determining the triangulation mesh corresponding to the initial polygon based on the ear-shaped triangle".

[0160] S401, screening the ear-shaped triangles to obtain a target ear-shaped triangle, wherein any inner angle of the target ear-shaped triangle is greater than a preset angle threshold;

[0161] S402, based on the target ear-shaped triangle, determine the triangulation mesh corresponding to the initial polygon.

[0162] Specifically, some narrow and long triangles will have a negative impact on the rendering display, such as causing distortion, deformation or discontinuity in the rendering results. These narrow and long triangles usually have one or more small internal angles, making the shape of the triangles become thin and irregular. Therefore, this embodiment introduces a preset angle threshold to screen the ear-shaped triangles to obtain the target ear-shaped triangles, so as to exclude those triangles with poor shapes that may affect the rendering effect.

[0163] The preset angle threshold refers to an angle value used to determine whether the inner angle of a triangle meets a specific condition. This angle value can be set according to actual needs. It is an angle greater than 0 degrees and less than 180 degrees, and a smaller angle (such as 5 degrees, 8 degrees, 10 degrees, etc.) is preferred within the range of 0 degrees to 180 degrees. During the screening process, the inner angles of each ear-shaped triangle will be checked one by one. If any inner angle is greater than the preset angle threshold, the triangle is considered to be the target ear-shaped triangle, otherwise it will be excluded.

[0164] Regarding the screening process, first, traverse all the determined ear-shaped triangles; then, for each ear-shaped triangle, calculate the sizes of its three internal angles; then, compare each internal angle with the preset angle threshold, if any internal angle is greater than the preset angle threshold, mark the ear-shaped triangle as a target ear-shaped triangle; finally, obtain all target ear-shaped triangles that meet the conditions.

[0165] Furthermore, regarding the process of determining the triangulation mesh corresponding to the initial polygon based on the target ear-shaped triangle, all the target ear-shaped triangles are first combined to form a complete triangulation mesh framework by connecting their shared edges or vertices; then, this framework is optimized and adjusted as necessary to ensure the accuracy and continuity of the triangulation mesh; finally, the triangulation mesh corresponding to the initial polygon is obtained.

[0166] In this embodiment, by introducing a preset angle threshold to screen ear-shaped triangles, those narrow and long triangles that may have a negative impact on rendering and display can be effectively excluded, thereby obtaining a more high-quality and regular triangulation grid. This embodiment not only improves the efficiency and quality of rendering and display, but also provides a more reliable basis for subsequent image processing and analysis.

[0167] Based on the above Figure 1 The following will combine Fig.10 The graphics processing device provided in the embodiment of the present application is introduced in detail. It should be noted that: Fig.10 The graphics processing device in the present application is used to execute Figure 2 - Fig. 9 For the convenience of explanation, only the part related to the embodiment of the present application is shown. For the specific technical details not disclosed, please refer to the present application. Figure 2 - Fig. 9 Specifically, the graphics processing device 800 may include an acquisition unit 801, a determination unit 802, an execution unit 803 and a display unit 804, as follows:

[0168] An acquisition unit 801 is used to acquire road perception data collected by a target vehicle and generate an initial polygon based on the road perception data;

[0169] A determining unit 802 is used to determine a bounding rectangle corresponding to the initial polygon, and determine a plurality of tile areas from the bounding rectangle;

[0170] An execution unit 803 is used to execute process information corresponding to the ear-cut triangulation task of the initial polygon based on multiple tile regions to obtain ear-shaped triangles in the initial polygon;

[0171] The display unit 804 is used to determine the triangulation mesh corresponding to the initial polygon based on the ear-shaped triangle, and render and display the road perception image based on the triangulation mesh.

[0172] Optionally, in some embodiments, the execution unit 803 may be used to: determine the order of each vertex in the initial polygon based on a preset clock direction, and traverse each vertex in the initial polygon according to the order of each vertex in the initial polygon;

[0173] For the target vertex in the traversed initial polygon, the target iteration polygon corresponding to the target vertex is determined based on the initial polygon, and the target triangle to be checked corresponding to the target vertex is determined from the target iteration polygon; the target tile area corresponding to the target triangle to be checked is determined from multiple tile areas, and the target triangle to be checked is checked based on the target tile area to determine whether the target triangle to be checked is the ear-shaped triangle corresponding to the target vertex; if there is a determined ear-shaped triangle, and the determined ear-shaped triangle meets the preset conditions, the traversal of each vertex in the initial polygon is terminated.

[0174] Optionally, in some embodiments, the execution unit 803 can be used to: if there is an ear-shaped triangle corresponding to a historical vertex that precedes the target vertex, then remove the ear-shaped triangle corresponding to the historical vertex from the initial polygon to obtain a target iteration polygon corresponding to the target vertex; if there is no ear-shaped triangle corresponding to the historical vertex that precedes the target vertex, then determine the initial polygon as the target iteration polygon corresponding to the target vertex.

[0175] Optionally, in some embodiments, the execution unit 803 may be used to: determine two adjacent vertices that are sequentially adjacent to the target vertex from the target iteration polygon; and construct a target to-be-checked triangle corresponding to the target vertex based on the target vertex and the two adjacent vertices.

[0176] Optionally, in some embodiments, the execution unit 803 can be used to: determine, from multiple tile areas, a tile area where a target vertex and two adjacent vertices sequentially adjacent to the target vertex are located as a target tile area; perform an internal vertex check on the target triangle to be checked based on the target tile area to obtain an internal vertex check result of the target triangle to be checked; perform a convexity check on the target triangle to be checked to obtain a convexity check result of the target triangle to be checked; if the internal vertex check result indicates that the interior of the target triangle to be checked contains vertices other than the target vertex and two adjacent vertices sequentially adjacent to the target vertex, or the convexity check result indicates that the target triangle to be checked is not a convex triangle, then determine that the target triangle to be checked is not an ear-shaped triangle corresponding to the target vertex; if the internal vertex check result indicates that the interior of the target triangle to be checked does not contain vertices other than the target vertex and two adjacent vertices, and the convexity check result indicates that the target triangle to be checked is a convex triangle, then determine that the target triangle to be checked is an ear-shaped triangle corresponding to the target vertex.

[0177] Optionally, in some embodiments, the internal vertex check result is divided into a first internal vertex check result and a second internal vertex check result; the execution unit 803 can be used to: determine, from multiple vertices in the target iteration polygon, a first-order check vertex that is outside the target vertex and two adjacent vertices and is located in the target tile area; if at least one first-order check vertex is located inside the target triangle to be checked, a first internal vertex check result is obtained; if the first-order check vertex is not located inside the target triangle to be checked, determine, from multiple vertices in the target iteration polygon, a second-order check vertex that is outside the target vertex and two adjacent vertices and is not located in the target tile area; if at least one second-order check vertex is located inside the target triangle to be checked, a first internal vertex check result is obtained; if the second-order check vertex is not located inside the target triangle to be checked, a second internal vertex check result is obtained.

[0178] Optionally, in some embodiments, the execution unit 803 can be used to: if there are determined ear-shaped triangles and the number of determined ear-shaped triangles reaches a preset number threshold, then end the traversal of each vertex in the initial polygon, and the preset number threshold is the number of vertices of the initial polygon minus two.

[0179] Optionally, in some embodiments, the acquisition unit 801 may be used to: extract road features from road perception data; and generate initial polygons based on the road features.

[0180] Optionally, in some embodiments, the display unit 804 can be used to: screen the ear-shaped triangles to obtain a target ear-shaped triangle, any internal angle of the target ear-shaped triangle being greater than a preset angle threshold; and determine a triangulation mesh corresponding to the initial polygon based on the target ear-shaped triangle.

[0181] The effects that can be achieved by this embodiment can be found in the relevant embodiments of the above-mentioned graphics processing method, which will not be described in detail here.

[0182] See also Fig.11 , which is a schematic diagram of the structure of a vehicle provided in the embodiment of the present application. Fig.11 As shown, the vehicle 900 includes a processor 901 and a memory 902. The processor 901 is electrically connected to the memory 902.

[0183] The processor 901 is the control center of the vehicle 900 and may include one or more processing cores. The processor 901 uses various interfaces and lines to connect various parts of the entire vehicle 900, and executes various functions and processes data of the vehicle 900 by running or calling computer programs stored in the memory 902, and calling data stored in the memory 902, so as to control the vehicle 900 as a whole. Optionally, the processor 901 may be implemented in at least one hardware form of digital signal processing (DSP), field programmable gate array (FPGA), and programmable logic array (PLA). The processor 901 may integrate one or a combination of CPU, graphics processing unit (GPU), modem, etc. Among them, the CPU mainly processes the operating system, user pages, and applications; the GPU is responsible for rendering and drawing display content; and the modem is used to process wireless communications. It is understandable that the above-mentioned modem may not be integrated into the processor 901, but may be implemented separately through a communication chip.

[0184] The memory 902 may be used to store software programs and modules, and the processor 901 executes various functional applications and data processing by running the computer programs and modules stored in the memory 902. The memory 902 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, a computer program required for at least one function, etc.; the data storage area may store data created according to the use of the vehicle 900, etc.

[0185] In addition, the memory 902 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other volatile solid-state storage devices. Accordingly, the memory 902 may also include a memory controller to provide the processor 901 with access to the memory 902.

[0186] In this embodiment, the processor 901 in the vehicle 900 loads instructions corresponding to the processes of one or more computer programs into the memory 902 according to the following steps, and the processor 901 runs the computer program stored in the memory 902 to implement various functions, as follows:

[0187] Acquire road perception data collected by the target vehicle, and generate an initial polygon based on the road perception data;

[0188] Determine the bounding rectangle corresponding to the initial polygon, and determine multiple tile areas from the bounding rectangle;

[0189] Execute the process information corresponding to the ear-cut triangulation task of the initial polygon based on the multiple tile regions to obtain the ear-shaped triangle in the initial polygon;

[0190] A triangulated mesh corresponding to the initial polygon is determined based on the ear-shaped triangle, and a road perception image is rendered and displayed based on the triangulated mesh.

[0191] Optionally, when the processor 901 executes the process information corresponding to the ear-cut triangulation task of performing the initial polygon based on multiple tile areas to obtain the ear-shaped triangle in the initial polygon, it specifically performs the following steps: determining the order of each vertices in the initial polygon based on a preset clock direction, and traversing each vertex in the initial polygon according to the order of each vertices in the initial polygon; for the target vertex in the traversed initial polygon, determining the target iteration polygon corresponding to the target vertex based on the initial polygon, and determining the target triangle to be checked corresponding to the target vertex from the target iteration polygon; determining the target tile area corresponding to the target triangle to be checked from multiple tile areas, and checking the target triangle to be checked based on the target tile area to determine whether the target triangle to be checked is the ear-shaped triangle corresponding to the target vertex; if there is a determined ear-shaped triangle and the determined ear-shaped triangle meets the preset conditions, then the traversal of each vertices in the initial polygon is terminated.

[0192] Optionally, when the processor 901 determines the target iteration polygon corresponding to the target vertex based on the initial polygon, it specifically performs the following steps: if there is an ear-shaped triangle corresponding to a historical vertex that precedes the target vertex, then the ear-shaped triangle corresponding to the historical vertex is removed from the initial polygon to obtain the target iteration polygon corresponding to the target vertex; if there is no ear-shaped triangle corresponding to the historical vertex that precedes the target vertex, then the initial polygon is determined as the target iteration polygon corresponding to the target vertex.

[0193] Optionally, when the processor 901 determines the target triangle to be checked corresponding to the target vertex from the target iteration polygon, it specifically performs: determining two adjacent vertices in sequence to the target vertex from the target iteration polygon; and constructing the target triangle to be checked corresponding to the target vertex based on the target vertex and the two adjacent vertices.

[0194] Optionally, when the processor 901 determines the target tile area corresponding to the target triangle to be checked from multiple tile areas, and checks the target triangle to be checked based on the target tile area to determine whether the target triangle to be checked is an ear-shaped triangle corresponding to the target vertex, the processor 901 specifically executes: determining, from multiple tile areas, a tile area where the target vertex and two adjacent vertices sequentially adjacent to the target vertex are located as the target tile area; performing an internal vertex check on the target triangle to be checked based on the target tile area to obtain an internal vertex check result of the target triangle to be checked; performing a convexity check on the target triangle to be checked to obtain a convexity check result of the target triangle to be checked; if the internal vertex check result indicates that the interior of the target triangle to be checked contains vertices other than the target vertex and two adjacent vertices sequentially adjacent to the target vertex, or the convexity check result indicates that the target triangle to be checked is not a convex triangle, then it is determined that the target triangle to be checked is not an ear-shaped triangle corresponding to the target vertex; if the internal vertex check result indicates that the interior of the target triangle to be checked does not contain vertices other than the target vertex and two adjacent vertices, and the convexity check result indicates that the target triangle to be checked is a convex triangle, then it is determined that the target triangle to be checked is an ear-shaped triangle corresponding to the target vertex.

[0195] Optionally, the internal vertex check result is divided into a first internal vertex check result and a second internal vertex check result; when the processor 901 performs internal vertex check on the target triangle to be checked based on the target tile area to obtain the internal vertex check result of the target triangle to be checked, it specifically performs: from multiple vertices in the target iteration polygon, determine the first-order check vertex that is outside the target vertex and two adjacent vertices and is located in the target tile area; if at least one first-order check vertex is located inside the target triangle to be checked, obtain the first internal vertex check result; if the first-order check vertex is not located inside the target triangle to be checked, determine the second-order check vertex that is outside the target vertex and two adjacent vertices and is not located in the target tile area from multiple vertices in the target iteration polygon; if at least one second-order check vertex is located inside the target triangle to be checked, obtain the first internal vertex check result; if the second-order check vertex is not located inside the target triangle to be checked, obtain the second internal vertex check result.

[0196] Optionally, when the processor 901 executes if there is a determined ear-shaped triangle and the determined ear-shaped triangle satisfies a preset condition, then the traversal of each vertex in the initial polygon is terminated, the specific execution is: if there is a determined ear-shaped triangle and the number of the determined ear-shaped triangles reaches a preset number threshold, then the traversal of each vertex in the initial polygon is terminated, and the preset number threshold is the number of vertices of the initial polygon minus two.

[0197] Optionally, when the processor 901 generates the initial polygon based on the road perception data, the processor 901 specifically performs: extracting road features from the road perception data; and generating the initial polygon based on the road features.

[0198] Optionally, when the processor 901 determines the triangulation mesh corresponding to the initial polygon based on the ear-shaped triangle, it specifically performs: screening the ear-shaped triangles to obtain a target ear-shaped triangle, any internal angle of the target ear-shaped triangle is greater than a preset angle threshold; based on the target ear-shaped triangle, determining the triangulation mesh corresponding to the initial polygon.

[0199] The effects that can be achieved by this embodiment can be found in the relevant embodiments of the above-mentioned graphics processing method, which will not be described in detail here.

[0200] It should be understood that the device provided in the embodiment of the present application is used to execute the above-mentioned graphics processing method, and thus can achieve the same effect as the above-mentioned implementation method.

[0201] In the case of an integrated unit, the device may include a processing module and a storage module. When the device is applied to a vehicle, the processing module may be used to control and manage the actions of the vehicle. The storage module may be used to support the vehicle in executing relevant program codes, etc.

[0202] The processing module may be a processor or a controller, which may implement or execute various exemplary logic blocks, modules and circuits described in conjunction with the disclosure of this application. The processor may also be a combination that implements computing functions, such as a combination of one or more microprocessors, a combination of digital signal processing (DSP) and a microprocessor, etc. The storage module may be a memory.

[0203] In addition, the device provided in the embodiment of the present application may specifically be a chip, component or module, and the chip may include a connected processor and memory; wherein the memory is used to store instructions, and when the processor calls and executes the instructions, the chip can execute a graphics processing method provided in the above embodiment.

[0204] An embodiment of the present application also provides a computer-readable storage medium, in which a computer program code is stored. When the computer program code is executed on a computer, the computer executes the above-mentioned related method steps to implement a graphics processing method provided by the above-mentioned embodiment.

[0205] This embodiment further provides a computer program product. When the computer program product is run on a computer, the computer is enabled to execute the above-mentioned related steps to implement a graphics processing method provided by the above-mentioned embodiment.

[0206] Among them, the device, computer-readable storage medium, computer program product or chip provided in this embodiment is used to execute the corresponding method provided above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding method provided above, and will not be repeated here.

[0207] Through the description of the above implementation methods, technical personnel in the relevant field can understand that for the convenience and simplicity of description, only the division of the above-mentioned functional modules is used as an example. In actual applications, the above-mentioned 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.

[0208] In the embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0209] The above contents are only specific implementation methods of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

Claims

1. A graphics processing method, characterized in that: The method comprises: Acquire road perception data collected by the target vehicle, and generate an initial polygon based on the road perception data; Determine a bounding rectangle corresponding to the initial polygon, and determine a plurality of tile areas from the bounding rectangle; Executing the process information corresponding to the ear-cut triangulation task of the initial polygon based on the plurality of tile regions to obtain ear-shaped triangles in the initial polygon; A triangulation mesh corresponding to the initial polygon is determined based on the ear-shaped triangle, and a road perception image is rendered and displayed based on the triangulation mesh.

2. The method according to claim 1, characterized in that The process information corresponding to the ear-cut triangulation task of performing the ear-cut triangulation of the initial polygon based on the plurality of tile regions to obtain the ear-shaped triangle in the initial polygon includes: Determining the order of each vertex in the initial polygon based on a preset clock direction, and traversing each vertex in the initial polygon according to the order of each vertex in the initial polygon; For the target vertex in the traversed initial polygon, determine the target iteration polygon corresponding to the target vertex based on the initial polygon, and determine the target triangle to be checked corresponding to the target vertex from the target iteration polygon; Determine a target tile region corresponding to the target to-be-checked triangle from the plurality of tile regions, and verify the target to-be-checked triangle based on the target tile region to determine whether the target to-be-checked triangle is the ear-shaped triangle corresponding to the target vertex; If the determined ear-shaped triangle exists and the determined ear-shaped triangle meets the preset condition, the traversal of each vertex in the initial polygon is terminated.

3. The method according to claim 2, characterized in that The step of determining a target iterative polygon corresponding to the target vertex based on the initial polygon comprises: If there is an ear-shaped triangle corresponding to a historical vertex that is sequentially before the target vertex, then the ear-shaped triangle corresponding to the historical vertex is removed from the initial polygon to obtain a target iteration polygon corresponding to the target vertex; If the ear-shaped triangle corresponding to the historical vertex that sequentially precedes the target vertex does not exist, the initial polygon is determined as the target iteration polygon corresponding to the target vertex.

4. The method according to claim 2, characterized in that: The step of determining the target to-be-checked triangle corresponding to the target vertex from the target iteration polygon comprises: From the target iteration polygon, determine two adjacent vertices that are sequentially adjacent to the target vertex; A target triangle to be checked corresponding to the target vertex is constructed according to the target vertex and the two adjacent vertices.

5. The method according to claim 2, characterized in that: The step of determining a target tile region corresponding to the target triangle to be checked from the plurality of tile regions, and checking the target triangle to be checked based on the target tile region to determine whether the target triangle to be checked is the ear-shaped triangle corresponding to the target vertex, comprises: From the plurality of tile regions, determine the tile region where the target vertex and two adjacent vertices sequentially adjacent to the target vertex are located as the target tile region; Performing internal vertex verification on the target triangle to be verified based on the target tile area to obtain an internal vertex verification result of the target triangle to be verified; Performing a convexity check on the target triangle to be checked to obtain a convexity check result of the target triangle to be checked; If the internal vertex check result indicates that the interior of the target to-be-checked triangle contains vertices other than the target vertex and two adjacent vertices sequentially adjacent to the target vertex, or the convexity check result indicates that the target to-be-checked triangle is not a convex triangle, it is determined that the target to-be-checked triangle is not the ear-shaped triangle corresponding to the target vertex; If the internal vertex check result indicates that the interior of the target triangle to be checked does not contain any vertices other than the target vertex and the two adjacent vertices, and the convexity check result indicates that the target triangle to be checked is a convex triangle, then it is determined that the target triangle to be checked is the ear-shaped triangle corresponding to the target vertex.

6. The method according to claim 5, characterized in that The internal vertex verification result is divided into a first internal vertex verification result and a second internal vertex verification result; The performing internal vertex verification on the target triangle to be verified based on the target tile area to obtain the internal vertex verification result of the target triangle to be verified includes: Determine, from a plurality of vertices in the target iteration polygon, a first-order check vertex that is outside the target vertex and two adjacent vertices and is located in the target tile area; If at least one of the first-order check vertices is located inside the target triangle to be checked, obtaining the first internal vertex check result; If the first-order check vertex is not located inside the target to-be-checked triangle, determine, from a plurality of vertices in the target iteration polygon, a second-order check vertex that is outside the target vertex and two adjacent vertices and is not located in the target tile area; If at least one of the second-order verification vertices is located inside the target triangle to be verified, obtaining the first internal vertex verification result; If the second-order verification vertex is not located inside the target triangle to be verified, the second internal vertex verification result is obtained.

7. The method according to claim 2, characterized in that If the determined ear-shaped triangle exists and the determined ear-shaped triangle satisfies a preset condition, then traversing each vertex in the initial polygon is terminated, including: If there are confirmed ear-shaped triangles, and the number of confirmed ear-shaped triangles reaches a preset number threshold, the traversal of each vertex in the initial polygon is terminated, and the preset number threshold is the number of vertices of the initial polygon minus two.

8. The method according to claim 1, characterized in that: The generating an initial polygon based on the road perception data comprises: extracting road features from the road perception data; Based on the road features, an initial polygon is generated.

9. The method according to claim 1, characterized in that: The determining of the triangulation mesh corresponding to the initial polygon based on the ear-shaped triangle comprises: Screening the ear-shaped triangles to obtain target ear-shaped triangles, wherein any inner angle of the target ear-shaped triangle is greater than a preset angle threshold; Based on the target ear-shaped triangle, a triangulation mesh corresponding to the initial polygon is determined.

10. A vehicle, characterized in that: include: A memory for storing executable program codes; A processor, configured to call and run the executable program code from the memory, so that the vehicle executes the method as claimed in any one of claims 1 to 9.