Scene rendering method, device and equipment and computer readable storage medium

By classifying and aggregating the data in scene reconstruction, a target set is created to optimize the rendering mesh creation process, solving the CPU burden problem caused by excessive Draw Call instructions and improving rendering efficiency.

CN121564167APending Publication Date: 2026-02-24CHANGCHUN ZHONGKE CHUANGDA SOFTWARE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511766938.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-27
Publication Date
2026-02-24

AI Technical Summary

Technical Problem

During scene reconstruction, the increased number of Draw Call instructions leads to excessive CPU load, resulting in performance overhead and affecting rendering efficiency, especially when processing a large number of objects.

Method used

The raw data is categorized according to data identifier type, data with the same material type are aggregated to create a target set, and a rendering mesh is created based on the target set. This reduces the number of Draw Call instructions and improves rendering efficiency by optimizing the rendering mesh creation process.

Benefits of technology

By reducing the number of rendering meshes created, performance overhead is reduced, rendering efficiency is improved, CPU computational burden is reduced, and system rendering performance is enhanced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121564167A_ABST
    Figure CN121564167A_ABST
Patent Text Reader

Abstract

The invention discloses a scene rendering method, device and equipment and a computer readable storage medium. The method obtains original data. Classifying the original data according to the data identification type to obtain initial classification data; and aggregating the data with the same material type in the initial classification data to obtain a target set. And creating a rendering grid corresponding to the target set based on the data identification type corresponding to the target set. And rendering the rendering grid to obtain a target scene. According to the method, one rendering grid is constructed by the data of the same material type, so that the number of constructed rendering grids is reduced, the performance overhead is reduced, and the rendering efficiency is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of computer graphics, and more particularly to a scene rendering method, apparatus, device, and computer-readable storage medium. Background Technology

[0002] As a popular technology, Surrounding Reality (SR) technology can perform 3D modeling and rendering based on real-time collected information about the surrounding environment, and finally build a 3D model scene on the display device that is similar to the surrounding environment.

[0003] However, during scene reconstruction, typically one Draw Call instruction is required to render the rendering mesh. For example, if there are 100 people in the surrounding environment, 100 Draw Call instructions are needed to render the rendering mesh (model) for each of the 100 people. As the number of Draw Call instructions increases, the burden on system hardware resources, such as the Central Processing Unit (CPU), becomes increasingly heavy, resulting in more performance overhead and impacting subsequent rendering operations. Rendering based on the rendering mesh is therefore inefficient. Summary of the Invention

[0004] This invention provides a scene rendering method, apparatus, device, computer-readable storage medium, and computer program product that can improve rendering efficiency.

[0005] In a first aspect, embodiments of the present invention provide a scene rendering method, the method comprising: Obtain the raw data; The raw data is classified according to the data identifier type to obtain the initial classified data; Aggregate data with the same material type from the initial classification data to obtain the target set; Create a rendering mesh corresponding to the target set based on the data identifier type corresponding to the target set; The target scene is obtained by rendering the rendering mesh.

[0006] In one feasible embodiment, the data identifier type includes linear data. The raw data is classified according to the data identifier type to obtain initial classified data, including: The raw data is classified according to the data identifier type to obtain the first category of data; If the data identifier type of the first category data is detected to be linear data, the angle between the line connecting adjacent data in the first category data and the target direction is detected, and whether the distance difference between adjacent data is greater than or equal to the corresponding threshold is detected. If the angle between the line connecting adjacent data in the first category and the target direction is less than a preset angle threshold, or the distance difference between adjacent data is less than a preset distance threshold, the target number of adjacent data is deleted to obtain the initial category data.

[0007] In one feasible embodiment, creating a rendering mesh corresponding to the target set based on the data identifier type corresponding to the target set includes: If the data identifier type corresponding to the target set is detected to be linear data, a translation and expansion operation is performed on the data in the target set to obtain the expanded data. The expanded data is converted into coordinate-transformed data corresponding to the preset coordinate system; Create vertex data based on the coordinate transformation data; Add the business data included in the target set to the corresponding vertex data to obtain new vertex data; Create a vertex buffer layout according to the preset specifications; Construct a rendering mesh based on vertex data and vertex buffer layout; The target scene is obtained by rendering the rendering mesh, including: The target scene is obtained by rendering the rendering mesh based on the business data in the rendering mesh.

[0008] In one feasible embodiment, a translation and expansion operation is performed on the data in the target set to obtain expanded data, including: Obtain the first direction vector and the second direction vector, which are composed of data in the target set and adjacent data before and after them; Obtain the first weight and the second weight, which are based on the distance difference between the data in the target set and the data before and after it; Add the product of the first weight and the first direction vector to the product of the second weight and the corresponding second direction vector to obtain the updated direction vector; The data at the endpoints of the updated direction vector are translated by a preset distance along the normal direction perpendicular to the direction vector to obtain the expanded data.

[0009] In one feasible embodiment, creating vertex data based on the coordinate-transformed data includes: Calculate the corresponding normal vector based on the coordinates of the data after coordinate transformation; The texture coordinates corresponding to the coordinate-transformed data are generated based on the length of the line segments composed of the coordinate-transformed data and the preset texture repetition frequency. Arrange the coordinate-transformed data in a preset order to obtain index data; Vertex data is created based on the coordinate-transformed data, normal vectors, texture coordinates, and index data.

[0010] In one feasible embodiment, the data identifier type further includes non-linear data, and a rendering mesh corresponding to the target set is created based on the data identifier type corresponding to the target set, including: If the data identifier type corresponding to the target set is detected to be nonlinear data, obtain the rendering mesh corresponding to the nonlinear data; Transform the data in the target set into target data with coordinate transformation corresponding to the preset coordinate system; Create a vertex buffer layout according to the preset specifications; Build an optimized rendering mesh based on the rendering mesh, target data, and vertex buffer layout; The target scene is obtained by rendering the rendering mesh, including: The target scene is obtained by rendering the rendering mesh based on the business data in the optimized rendering mesh.

[0011] In one feasible embodiment, the method further includes: If no new raw data is received within a preset time period, clear the historical raw data and the data related to the historical raw data.

[0012] In one feasible embodiment, the method further includes: If the target element information exists in the original data but does not exist in the historical original data, perform a creation operation on the data corresponding to the target element information. If the target element information does not exist in the original data but exists in the historical original data, perform a deletion operation on the data corresponding to the target element information. If the target element information exists in both the original data and the historical original data, perform an update operation on the data corresponding to the target element information.

[0013] Secondly, embodiments of the present invention provide a scene rendering apparatus, the apparatus comprising: The acquisition module is used to acquire raw data; The classification module is used to classify the raw data according to the data identifier type to obtain the initial classification data; The aggregation module is used to aggregate data with the same material type from the initial classification data to obtain the target set; A creation module is used to create a rendering mesh corresponding to the target set based on the data identifier type corresponding to the target set. The rendering module is used to render the rendering mesh to obtain the target scene.

[0014] Thirdly, embodiments of the present invention provide an electronic device, the device including a processor and a memory storing computer program instructions; the processor reads and executes the computer program instructions to implement a scene rendering method as described in any of the first aspects.

[0015] Fourthly, embodiments of the present invention provide a computer-readable storage medium storing computer program instructions, which, when executed by a processor, implement a scene rendering method as described in any of the first aspects.

[0016] Fifthly, embodiments of the present invention provide a computer program product, including a computer program that, when executed by a processor, implements a scene rendering method as described in any of the first aspects.

[0017] This invention acquires raw data. The raw data is categorized according to data identifier type to obtain initial categorized data. Data with the same material type in the initial categorized data is aggregated to obtain a target set. A rendering mesh corresponding to the target set is created based on the data identifier type of the target set. The rendering mesh is then rendered to obtain the target scene. This invention reduces the number of rendering meshes to be constructed by building a single rendering mesh for data of the same material type, thereby reducing performance overhead and improving rendering efficiency. Attached Figure Description

[0018] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present invention and, together with the description, serve to explain the principles of the invention. They do not constitute an undue limitation of the invention. To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0019] Figure 1 This is a flowchart illustrating a scene rendering method provided in an embodiment of this disclosure.

[0020] Figure 2 This is a schematic diagram of lane line coordinates provided in an embodiment of this disclosure.

[0021] Figure 3 This is a flowchart illustrating a method for obtaining initial classification data according to an embodiment of this disclosure.

[0022] Figure 4This is a flowchart illustrating a method for obtaining a rendering mesh provided in an embodiment of this disclosure.

[0023] Figure 5 This is a schematic diagram illustrating an embodiment of obtaining expanded data provided in this disclosure.

[0024] Figure 6 This is a flowchart illustrating another method for obtaining a rendering mesh provided in an embodiment of this disclosure.

[0025] Figure 7 This is a flowchart illustrating a method for performing corresponding operations on data corresponding to target element information, provided in an embodiment of this disclosure.

[0026] Figure 8 This is a flowchart illustrating another data processing method provided in an embodiment of this disclosure.

[0027] Figure 9 This is a schematic diagram of the structure of a scene rendering device provided in an embodiment of this disclosure.

[0028] Figure 10 This is a schematic diagram of the structure of a scene rendering device provided in an embodiment of this disclosure. Detailed Implementation

[0029] To enable those skilled in the art to better understand the technical solutions of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings.

[0030] It should be noted that the terms "first," "second," etc., used in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this invention. Rather, they are merely examples of apparatuses and methods consistent with some aspects of the invention as detailed in the appended claims.

[0031] Before describing the technical solutions provided by the embodiments of the present invention, in order to facilitate understanding of the embodiments of the present invention, the present invention will specifically explain the problems existing in the related technologies: As a popular technology, scene reconstruction technology can perform 3D modeling and rendering based on real-time collected information about the surrounding environment, and finally build a 3D model scene on the display device that is similar to the surrounding environment.

[0032] In practical applications, this technology can be used in the field of intelligent vehicles. For example, intelligent vehicles use their sensors to collect various information about the surrounding environment, including the positions of pedestrians, other vehicles, and obstacles, the vehicle's speed and direction, and the status of traffic lights. Based on the sensor data, a 3D model is then created for each relevant object. Finally, these 3D models are rendered into animated scenes for display on a screen to assist the driver in making appropriate decisions about driving the vehicle.

[0033] During scene reconstruction, the CPU typically sends a Draw Call instruction to the Graphics Processing Unit (GPU) to command the GPU to draw and render a specific graphics object or model. Specifically, the CPU needs to prepare the data for the object to be drawn and rendered. This data includes, but is not limited to, vertex data, material information, shader programs, and transformation matrices. Vertex data contains information about the object's shape, such as position, normals, and texture coordinates. Material information describes how to color or apply textures to the object. Shader programs tell the GPU how to process these vertices and pixels to generate the final image. Transformation matrices determine the object's position, rotation, and scaling in 3D space. Once all the necessary data and state are ready, the CPU sends a Draw Call instruction to the GPU via an API (such as OpenGL, DirectX, Vulkan, etc.). This instruction contains all the aforementioned information and instructs the GPU to use this information to draw and render the specified 3D model. After receiving the Draw Call instruction, the GPU performs the actual drawing and rendering operations based on the provided vertex data and rendering state, outputting the corresponding image fragment to the frame buffer.

[0034] In existing technologies, the number of Draw Call instructions is directly proportional to the number of element objects. For example, in a scene containing 50 vehicles, 20 pedestrians, and 10 trees, the CPU needs to prepare the shape information and corresponding material information for each vehicle, pedestrian, and tree. Based on this information, corresponding Draw Call instructions are then created for each vehicle, pedestrian, and tree to draw and render the corresponding 3D model. Ultimately, the CPU sends 80 Draw Call instructions. However, the more Draw Call instructions there are, the heavier the CPU load becomes, resulting in significant performance overhead on system resources, impacting subsequent rendering operations, and leading to low rendering efficiency.

[0035] In addition, during scene reconstruction, if the scene needs to realize actions such as walking, running, and riding bicycles, it is usually necessary to calculate skeletal animation. When there are a large number of pedestrians in the scene, since the action states of each pedestrian are different (for example, one person raises their left hand, and another person raises their right hand), skeletal animation needs to be calculated independently for each pedestrian, which also generates a huge amount of computation and causes significant consumption of CPU resources.

[0036] In existing technologies, the steps for calculating and displaying character skeletal animation in a reconstructed scene are as follows: First, accurate pre-defined resources are acquired, including the rendering mesh and skeletal animation curve data. The rendering engine calculates the world coordinate matrix for each bone in real-time based on the current frame number. Specifically, it obtains the corresponding local coordinate matrix from the animation curve of each bone, and then recursively multiplies it by the transformation matrix of the parent node until the root node to calculate the world coordinate matrix. The skeletal world coordinate matrix is ​​then transferred from the CPU to the GPU via a uniform variable. This calculation process is repeated until the rendering mesh with the skeletal animation is destroyed. Finally, in the shader, the skeletal world coordinate matrix transferred via uniform, combined with the bone weights associated with the vertices, is used to calculate the final vertex coordinates, and the character skeletal animation is calculated based on these final vertex coordinates.

[0037] The present invention provides a scene rendering method, apparatus, device, computer-readable storage medium, and computer program product, which can solve at least one of the above-mentioned technical problems existing in the related art.

[0038] This invention acquires raw data. The raw data is categorized according to data identifier type to obtain initial categorized data. Data with the same material type in the initial categorized data is aggregated to obtain a target set. A rendering mesh corresponding to the target set is created based on the data identifier type of the target set. The rendering mesh is then rendered to obtain the target scene. This invention reduces the number of rendering meshes to be constructed by building a single rendering mesh for data of the same material type, thereby reducing performance overhead and improving rendering efficiency.

[0039] Figure 1 A flowchart illustrating a scene rendering method according to an embodiment of the present invention is shown. Figure 1 As shown, the method includes steps S110-S150.

[0040] S110: Obtain raw data.

[0041] In one embodiment, the sensor module uses sensor elements to collect raw data and sends the raw data to the rendering module. The rendering module obtains the raw data through a receiving component.

[0042] The raw data represents the external environmental data of the system in which the sensor module is located, such as data on pedestrians and vehicles. The rendering module is used to render the acquired raw data to obtain the target scene.

[0043] In one example, the sensor module in the vehicle system uses sensor elements to collect environmental data outside the vehicle and sends the environmental data to the rendering module in the vehicle system. After receiving the environmental data, the rendering module in the vehicle system uses the environmental data as raw data.

[0044] In another embodiment, the sensor module collects raw data using sensor elements and sends the raw data for serialization and classification / packetization to the rendering module. The rendering module receives the raw data through a receiving component and performs deserialization processing on the raw data.

[0045] In another example, the sensor module in the vehicle system uses sensor elements to collect environmental data outside the vehicle, such as lane line data, guide line data, obstacle data, and drivable area data. It then serializes and categorizes the environmental data according to data type and sends the serialized and categorized environmental data to the rendering module in the vehicle system. The rendering module in the vehicle system receives the environmental data and uses it as the raw data.

[0046] In the steps of the above embodiments, data processing of the raw data can improve the efficiency and integrity of data transmission, and classification and packaging of the raw data can achieve orderly transmission and accurate docking of the raw data.

[0047] S120: Classify the raw data according to the data identifier type to obtain the initial classified data.

[0048] In one embodiment, after obtaining the raw data, the rendering module can determine the data identifier type of the raw data based on the characteristics of the location data in the raw data, and then classify the raw data according to the data identifier type to obtain the initial classification data.

[0049] Among them, the location data represents the coordinates of the object corresponding to the original data.

[0050] In one example, after obtaining the raw data, the rendering module detects that the positional data included in a certain raw data set is a changing coordinate dataset [(1,0), (2,0), (3,0)], and then identifies the raw data as a linear data type. If the positional data included in a certain raw data set is detected as a single coordinate data (15,1), then the raw data is identified as a non-linear data type.

[0051] It's important to note that the reason linear data represents the original data as a series of coordinate data is because the original data may include lane line data. To accurately represent that the original data is lane line data, multiple coordinate data can be combined to obtain a coordinate dataset. These coordinate data change according to a certain pattern, essentially changing in a specific direction, thus representing the direction of the lane line. For example... Figure 2 In the diagram, the coordinates of the lane lines are arranged sequentially as (0,100), (0,101), and (0,102), representing the direction of the lane lines. The reason why non-linear data represents the coordinates of the original data as a single coordinate is that, in addition to linear data such as lane lines, the original data may also include data on pedestrians, trees, utility poles, etc., and these data can represent the current position status using only a single coordinate.

[0052] In the process flow of this invention embodiment, since the steps for creating rendering meshes are different for raw data of different data identifier types, in order to improve the efficiency of creating rendering meshes, it is necessary to classify the raw data according to the data identifier type to obtain initial classification data.

[0053] S130: Aggregate data with the same material type from the initial classification data to obtain the target set.

[0054] In one embodiment, after obtaining the initial classification data, the determination module can determine whether the element objects (element information) represented by the data in the initial classification data are the same. If the element objects are the same, it can be determined that the data with the same element objects have the same material type, and the data with the same material type are aggregated to obtain the target set.

[0055] The material type represents the color and texture structure used in the subsequent rendering of this data.

[0056] In one example, the initial classification data includes initial classification data corresponding to pedestrian 1, initial classification data corresponding to pedestrian 2, and initial classification data corresponding to tree 3. The element objects corresponding to the initial classification data for pedestrian 1 and pedestrian 2 are both pedestrians. Therefore, it can be determined that the initial classification data for pedestrian 1 and pedestrian 2 have the same material type. These initial classification data are then aggregated into a single dataset to obtain the target set.

[0057] In another embodiment, after obtaining the initial classification data, the determination module can determine the type of the element object (element information) represented by the data in the initial classification data, create new initial classification data corresponding to the new element information, and aggregate the data with the same material type in the initial classification data of the new element information to obtain the target set.

[0058] In one example, the initial classification data includes initial classification data corresponding to passerby 12 and initial classification data corresponding to passerby 32. Based on the initial classification data corresponding to passerby 12 and passerby 32, corresponding shadow data is created. Since the shadow data have the same material type, the shadow data can be aggregated to obtain a target set.

[0059] In existing technologies, even if the corresponding element objects and material types among the initial classification data are the same, a corresponding Draw Call instruction needs to be created for each initial classification data for rendering, resulting in an excessive number of Draw Call instructions. It is understandable that if the corresponding element objects and material types among the initial classification data are the same, a single Draw Call instruction can be created for rendering, similar to using the same brush to color objects of the same shape. Because this embodiment of the invention aggregates data with the same material type from the initial classification data to obtain a target set, subsequent rendering meshes can be created based on the target set for rendering, reducing the number of rendering meshes created, thereby reducing the number of Draw Call instructions related to the rendering meshes and reducing unnecessary performance overhead.

[0060] S140: Create a rendering mesh corresponding to the target set based on the data identifier type corresponding to the target set.

[0061] In one embodiment, after obtaining the target set, the data identifier type corresponding to the target set can be determined. If the data identifier type corresponding to the target set is linear data, the coordinate data in the target set can be expanded to obtain expanded coordinate data. Then, vertex data can be created based on the expanded coordinate data and the business data in the target set. Finally, a rendering mesh can be created based on the vertex data for subsequent rendering of the rendering mesh. If the data identifier type corresponding to the target set is non-linear data, a preset rendering mesh corresponding to the target set can be selected from pre-stored rendering meshes. The preset rendering mesh can be optimized based on the business data in the target set to obtain an optimized rendering mesh for subsequent rendering of the optimized rendering mesh.

[0062] Among them, the rendering mesh represents the basic data structure that describes the geometry of an object. It can be understood as the core geometric foundation of a 3D model, that is, the "skeleton" of a 3D model.

[0063] Understandably, linear data is dynamic, indicating different directions at different times. This means the model shape corresponding to linear data is uncertain; for example, lane lines are sometimes straight and sometimes curved. Therefore, pre-stored rendering meshes cannot be applied to linear data to render the corresponding scene; a new rendering mesh must be created. Non-linear data, on the other hand, is static, indicating no direction. For example, a pedestrian is always a pedestrian, with no change in shape. This means the model shape corresponding to non-linear data is fixed. Therefore, pre-stored rendering meshes can be reused for non-linear data to improve rendering efficiency.

[0064] S150: Render the rendering mesh to obtain the target scene.

[0065] In one embodiment, after obtaining the rendering mesh, the rendering mesh can be rendered using shaders in the rendering module to obtain the target scene.

[0066] This invention acquires raw data. The raw data is categorized according to data identifier type to obtain initial categorized data. Data with the same material type in the initial categorized data is aggregated to obtain a target set. A rendering mesh corresponding to the target set is created based on the data identifier type of the target set. The rendering mesh is then rendered to obtain the target scene. This invention reduces the number of rendering meshes to be constructed by building a single rendering mesh for data of the same material type, thereby reducing performance overhead and improving rendering efficiency.

[0067] In one embodiment, the data identifier type includes linear data. The raw data is classified according to the data identifier type to obtain initial classified data, such as... Figure 3 As shown, it includes steps S121-S123.

[0068] S121: Classify the original data according to the data identifier type to obtain the first category of data.

[0069] In one embodiment, after obtaining the raw data, it can be classified according to the data identifier type to obtain first category data related to linear data and first category data related to non-linear data.

[0070] S122: When the data identifier type of the first category data is detected to be linear data, the angle between the line connecting adjacent data in the first category data and the target direction is detected, and whether the distance difference between adjacent data is greater than or equal to the corresponding threshold is detected.

[0071] In one embodiment, after obtaining the first classification data, the data identifier type of the first classification data can be detected by the detection module. If the data identifier type of the first classification data is linear data, the detection module can detect whether the angle between the line connecting adjacent first classification data included in the coordinate data and the target direction is greater than or equal to a preset angle threshold and whether the distance difference between adjacent first classification data included in the coordinate data is greater than or equal to a preset distance threshold.

[0072] It is understandable that linear data is usually represented by a series of coordinate data. If the coordinate data collected by the sensor module is relatively dense, then it is conceivable that the shape of the linear data will not change in a short period of time, which means that the coordinate data of the linear data is too redundant. Therefore, it is possible to detect the angle between the line connecting adjacent data in the first category and the target direction, and whether the distance difference between adjacent data is greater than or equal to the corresponding threshold, to determine whether the coordinate data belongs to redundant data for subsequent deletion.

[0073] S123: If the angle between the line connecting adjacent data in the first classification data and the target direction is less than a preset angle threshold, or the distance difference between adjacent data is less than a preset distance threshold, delete the number of adjacent data of the target to obtain the initial classification data.

[0074] In one embodiment, if the angle between the line connecting adjacent data in the first classification data and the target direction is less than a preset angle threshold, or the distance difference between adjacent data is less than a preset distance threshold, it indicates that there is redundant data between adjacent first classification data. The adjacent data representing the target number of redundant data in the first classification data can be deleted to obtain the initial classification data.

[0075] In one embodiment of the above embodiments, if the angle between the line connecting adjacent data in the first classification data and the target direction is less than a preset angle threshold, it indicates that there is redundant data between adjacent first classification data. The adjacent data representing the target number of redundant data in the first classification data can be deleted to obtain the initial classification data.

[0076] In one embodiment of the above embodiments, if the distance difference between adjacent data is less than a preset distance threshold, it indicates that there is redundant data between adjacent first-class data. The adjacent data representing the target number of redundant data in the first-class data can be deleted to obtain the initial classification data.

[0077] In one embodiment of the above embodiments, if it is detected that the angle between the line connecting adjacent data in the first classification data and the target direction is less than a preset angle threshold and the distance difference between adjacent data is less than a preset distance threshold, it indicates that there is redundant data between adjacent first classification data. The adjacent data representing the target number of redundant data in the first classification data can be deleted to obtain the initial classification data.

[0078] In this embodiment of the invention, when the data identifier type of the first category data is detected to be linear data, the target number of adjacent data is deleted by detecting whether the angle between the line connecting adjacent data in the first category data and the target direction is greater than or equal to a preset angle threshold, or whether the distance difference between adjacent data is greater than or equal to a preset distance threshold. This reduces the computational performance overhead required for creating rendering meshes based on the first category data with the data identifier type of linear data and rendering based on the rendering mesh.

[0079] In one embodiment, if the coordinate data of the first category data collected by the sensor module is relatively sparse, that is, the distance difference between adjacent first category data in the coordinate data is greater than the target preset distance threshold, a quadratic Bézier curve interpolation algorithm can be used to supplement the first category data, improve the smoothness of the lines, and thus improve the quality of subsequent rendering.

[0080] In one embodiment, a rendering mesh corresponding to the target set is created based on the data identifier type corresponding to the target set, such as... Figure 4 As shown, steps S141-S146 may be included.

[0081] S141: If the data identifier type corresponding to the target set is detected to be linear data, perform a translation and expansion operation on the data in the target set to obtain the expanded data.

[0082] In one embodiment, step S141 may include steps S1411-S1414.

[0083] S1411: Obtain the first direction vector and the second direction vector.

[0084] The first direction vector and the second direction vector are derived from the data in the target set and the adjacent data.

[0085] In one embodiment, after obtaining the target set, the data in the target set can be combined with the positions of other adjacent data before and after the coordinate data of the target set to form a first direction vector and a second direction vector.

[0086] In one example, the target set includes three data points, each containing a coordinate data point: (6,0), (7,0), and (8,0). The coordinate data point (7,0) is adjacent to both the coordinate data points (6,0) and (8,0). A first direction vector can be determined based on the coordinate data points (6,0) and (7,0), and a second direction vector can be determined based on the coordinate data points (7,0) and (8,0).

[0087] S1412: Obtain the first weight and the second weight.

[0088] The first and second weights are obtained based on the distance difference between the data in the target set and the data before and after them.

[0089] In one embodiment, the calculation module can use the difference between the distances between the data in the target set and the distances between the coordinate data of the data and other adjacent data as the first and second weights.

[0090] S1413: Add the product of the first weight and the first direction vector to the product of the second weight and the corresponding second direction vector to obtain the updated direction vector.

[0091] In one embodiment, after obtaining the first weight and the second weight, the product of the first weight and the first direction vector can be added to the product of the second weight and the corresponding second direction vector to obtain the updated direction vector.

[0092] S1414: Along the normal direction perpendicular to the direction vector, translate the data of the endpoints that make up the updated direction vector by a preset distance to obtain the expanded data.

[0093] In one embodiment, after obtaining the updated direction vector, the coordinate data of the endpoints of the first and second direction vectors that make up the updated direction vector can be translated by a preset distance along the normal direction perpendicular to the direction vector to obtain the expanded data.

[0094] In one example, a translation and expansion operation is performed on the data in the target set, and the resulting diagram of the expanded data is shown below. Figure 5 As shown in the diagram, the target set includes a first point, a second point, and a third point. A first direction vector is determined based on the position coordinates of the first and second points, and a second direction vector is determined based on the position coordinates of the second and third points. The first and second direction vectors are multiplied by their corresponding weights and summed to obtain an update vector. Then, along the normal direction perpendicular to the update vector, the data at the endpoints of the update vector are translated by a preset distance to obtain the expanded data.

[0095] It's understandable that the linear data collected by the sensor module represents the shape of a line. However, in the actual reconstructed scene, the model corresponding to the linear data still has length and width. That is, the reconstructed model shape of the collected linear data should be a "line" with a planar structure containing length and width. Therefore, it is necessary to perform a translation and expansion operation on the coordinate data of the collected linear data so that the coordinate data after the translation and expansion operation can form a planar structure. This facilitates the subsequent creation of the corresponding rendering mesh, which is then used to render the rendering mesh as a "line" model including length and width.

[0096] S142: Convert the expanded data into data with coordinate transformation corresponding to the preset coordinate system.

[0097] In one embodiment, the direction of the coordinate system corresponding to the coordinate data of the expanded data can be aligned with the direction of the preset coordinate system, so that the expanded data can be transformed into data with coordinate transformation corresponding to the preset coordinate system.

[0098] In one example, the coordinate system of the expanded data corresponds to (length, width, height), while the default coordinate system has the same orientation (length, height, width). Therefore, the orientation of the coordinate system corresponding to the expanded data can be changed from (length, width, height) to the default coordinate system (length, height, width), thus transforming the expanded data into data with coordinates corresponding to the default coordinate system.

[0099] Since the coordinate system used for rendering inside the rendering module is different from the coordinate system of the original data collected by the sensor module, the steps in this embodiment of the invention need to convert the expanded data into coordinate-transformed data corresponding to the preset coordinate system to improve the accuracy of rendering.

[0100] S143: Create vertex data based on the coordinate transformation data.

[0101] In one embodiment, step S143 includes S1431-S1434.

[0102] S1431: Calculate the corresponding normal vector based on the coordinates of the data after coordinate transformation.

[0103] In one embodiment, after obtaining the coordinate-transformed data, the corresponding normal vector can be calculated based on the coordinate data contained in the coordinate-transformed data.

[0104] The normal vector is used to characterize the orientation of the surface where the vertex data is located.

[0105] S1432: Generate texture coordinates corresponding to the coordinate-transformed data based on the length of the line segments composed of the coordinate-transformed data and the preset texture repetition frequency.

[0106] In one embodiment, texture coordinates corresponding to the coordinate-transformed data can be generated based on the length of the line segment formed by adjacent data in the coordinate-transformed data and a preset texture repetition frequency.

[0107] Texture coordinates are used to draw texture maps based on vertex data.

[0108] S1433: Arrange the coordinate-transformed data in a preset order to obtain index data.

[0109] In one embodiment, after obtaining the coordinate-transformed data, the coordinate-transformed data can be arranged sequentially according to a preset order to obtain index data.

[0110] The index data includes an index array, which is used to reduce the duplication of vertex data and drawing calls.

[0111] In one example, the data after coordinate transformation can be arranged in a preset order of top to bottom and left to right to obtain an index array.

[0112] S1434: Create vertex data based on the coordinate-transformed data, normal vectors, texture coordinates, and index data.

[0113] In one embodiment, after obtaining the calculated normal vector, texture coordinates, and index data, the coordinates of the coordinate-transformed data can be used as the coordinates of the vertex data, and the normal vector, texture coordinates, and index data can be used as the attributes of the vertex data to finally obtain the vertex data.

[0114] S144: Add the business data included in the target set to the corresponding vertex data to obtain new vertex data.

[0115] The business data includes color data, type data, time parameter data, transparency data, and other rendering state control parameter data for linear data. The time parameter data is used to drive the dynamic animation effects of the target scene.

[0116] In one embodiment, business data, such as color data, type data, time parameter data, transparency data, and other rendering state control parameter data, included in the target set data can be added to the corresponding vertex data so that the subsequent rendering module can render the vertex data in the rendering mesh based on the business data.

[0117] S145: Create a vertex buffer layout according to the preset specifications.

[0118] In one embodiment, the coordinates, texture coordinates, normal vectors, index data, and business data in the vertex data can be organized in an interleaved storage manner to create an optimized vertex buffer layout.

[0119] Interleaved storage refers to storing different types of data sequentially in a contiguous block of memory. Interleaved storage can improve rendering efficiency because when the GPU accesses all relevant information for a vertex, they are in close proximity in memory. This helps to take advantage of cache locality and reduce the number of cache misses.

[0120] S146: Construct a rendering mesh based on vertex data and vertex buffer layout.

[0121] In one embodiment, a rendering mesh can be constructed based on vertex data and vertex buffer layout for use in registering the rendering mesh to the rendering tree in the rendering module.

[0122] In the case where the data identifier type corresponding to the target set is linear data, this embodiment of the invention creates a rendering mesh corresponding to the target set based on the data identifier type corresponding to the target set, which can improve the accuracy of creating the rendering mesh.

[0123] In one embodiment, rendering the rendering mesh to obtain the target scene may include step S210.

[0124] S210: Render the rendering grid based on the business data in the rendering grid to obtain the target scene.

[0125] In one embodiment, all business data in the rendering mesh can be read from the vertex shader in the rendering module, processed in real time according to specific business requirements, and then passed to the fragment shader in the rendering module. The fragment shader samples the corresponding material based on the texture coordinates, performs physically accurate lighting calculations in combination with the normal vectors, and implements logical functions such as color blending and state switching based on the business data, ultimately outputting a rendering effect that meets the requirements of visual realism, thus obtaining the target scene.

[0126] In one embodiment, the data identifier type also includes nonlinear data, and a rendering mesh corresponding to the target set is created based on the data identifier type corresponding to the target set, such as... Figure 6 As shown, steps S310-S340 may be included.

[0127] S310: If the data identifier type corresponding to the target set is detected to be non-linear data, obtain the rendering mesh corresponding to the non-linear data.

[0128] In one embodiment, the data identifier type corresponding to the target set can be detected by the detection module. If the data identifier type corresponding to the target set is detected to be non-linear data, the pre-stored rendering mesh corresponding to the non-linear data can be obtained from the storage space for loading.

[0129] S320: Convert the data in the target set into target data with coordinate transformation corresponding to the preset coordinate system.

[0130] In one embodiment, the direction of the coordinate system corresponding to the coordinate data of the target set can be aligned with the direction of the preset coordinate system, so that the data in the target set is transformed into target data with coordinate transformation corresponding to the preset coordinate system.

[0131] S330: Creates a vertex buffer layout according to the preset specifications.

[0132] In one embodiment, the world coordinate transformation matrix can be calculated based on the coordinate and pose data in the target data, and relevant business data can be obtained. The coordinates, texture coordinates, normal vectors, and index data of the vertex data in the pre-stored rendering mesh, along with the world coordinate transformation matrix and business data corresponding to the target data, are organized in an interleaved storage manner to create a vertex buffer layout that conforms to the GPU (instantiation) Instancing specification.

[0133] The business data includes element information identifiers and status flags, animation control parameters and time series data, rendering characteristic parameter data (transparency, reflectivity, etc.), and additional attribute data required by the business logic.

[0134] S340: Constructs an optimized rendering mesh based on the rendering mesh, target data, and vertex buffer layout.

[0135] In one embodiment, an optimized rendering mesh can be constructed based on the coordinates, texture coordinates, normal vectors, and index data in the vertex data of the pre-stored rendering mesh, the world coordinate transformation matrix corresponding to the target data, and the business data, as well as the vertex buffer layout.

[0136] In the case where the data identifier type corresponding to the target set is linear data, this embodiment of the invention creates a rendering mesh corresponding to the target set based on the data identifier type corresponding to the target set, which can improve the accuracy of creating the rendering mesh.

[0137] In one embodiment, rendering the rendering mesh to obtain the target scene may include step S410.

[0138] S410: Render the rendering mesh based on the business data in the optimized rendering mesh to obtain the target scene.

[0139] In one embodiment, all business data in the optimized rendering mesh can be read from the vertex shader in the rendering module, and processed in real time according to specific business requirements, as well as the data transfer from the rendering module to the fragment shader. The fragment shader samples the corresponding material based on the texture coordinates, performs physically accurate lighting calculations in combination with the normal vectors, and implements logical functions such as color blending and state switching based on the business data, ultimately outputting a rendering effect that meets the requirements of visual realism, thus obtaining the target scene.

[0140] In one embodiment, the scene rendering method further includes step S510.

[0141] S510: If no new raw data is received within a preset time period, clear the historical raw data and the data related to the historical raw data.

[0142] In one embodiment, a detection module can be used to detect whether the sensor module periodically sends new raw data to the rendering module. If the rendering module does not receive new raw data within a preset time period, the historical raw data and related data are cleared.

[0143] In this embodiment of the invention, if no new original data is received within a preset time period, historical original data and data related to historical original data are cleared, which can ensure the consistency between the system state and the target scenario and the original data.

[0144] In one embodiment, such as Figure 7 As shown, the scene rendering method also includes steps S610-S630.

[0145] S610: If the target element information exists in the original data but does not exist in the historical original data, perform a creation operation on the data corresponding to the target element information.

[0146] In one embodiment, if the detection module detects that there is data corresponding to the target element information in the original data, but there is no data corresponding to the target element information in the historical original data, it indicates that the target element information corresponding to the data is a newly appearing element. Therefore, a creation operation can be performed on the data corresponding to the target element information for subsequent rendering of the target element information corresponding to the data.

[0147] In one example, if the original data contains data for a pedestrian with ID 10001, but the original historical data does not contain data for a pedestrian with ID 10001, then a creation operation can be performed on the data for the pedestrian with ID 10001 for subsequent rendering of the pedestrian corresponding to that data.

[0148] S620: If the data corresponding to the target element information does not exist in the original data but exists in the historical original data, perform a deletion operation on the data corresponding to the target element information.

[0149] In one embodiment, if the detection module detects that there is no data corresponding to the target element information in the original data, but there is data corresponding to the target element information in the historical original data, indicating that the target element information corresponding to the data is a missing element, then a deletion operation can be performed on the data corresponding to the target element information to delete the model rendered by the target element information corresponding to the data in the target scene.

[0150] In one example, if the original data does not contain a single yellow line with ID 20001, but the historical original data does contain a single yellow line with ID 20001, indicating that the single yellow line corresponding to that data is a missing element, then a deletion operation can be performed on the data corresponding to the single yellow line to remove the model rendered by the single yellow line corresponding to that data in the target scene.

[0151] S630: If the target element information exists in both the original data and the historical original data, perform an update operation on the data corresponding to the target element information.

[0152] In one embodiment, if the detection module detects that there is data corresponding to the target element information in the original data and there is data corresponding to the target element information in the historical original data, it indicates that the target element information corresponding to the data has always existed, and the state of the target element information can be updated, and an update operation can be performed on the data corresponding to the target element information.

[0153] In one example, if the detection module detects that there is data for a truck with ID 30001 in both the original data and the historical original data, it indicates that the truck corresponding to the data has always existed, and the status of the truck can be updated, and an update operation can be performed on the data corresponding to the truck.

[0154] This invention, by performing corresponding operations based on changes in target element information between the original data and historical original data, ensures that the rendered target scene is synchronized with the currently received original data in real time.

[0155] In one embodiment, the rendering module may include a data receiving component SRBackend, a data integration component SRFrontend, and a rendering engine Kanzi Studio. The rendering engine Kanzi Studio includes image generation, texture restoration, animation generation, and pipeline management functions. The image generation function, based on computer graphics principles, precisely transforms the element information, originally in a three-dimensional coordinate system, from the created rendering mesh by using world coordinate matrices, camera matrices, and projection matrices to obtain a two-dimensional image adapted to the terminal screen. This ensures that the transformed image completely corresponds to the position of objects in the real world. The texture restoration function simulates the changes in brightness and darkness of objects under different lighting conditions using lighting processing steps and employs high-quality physically based rendering (PBR) material rendering to restore the texture of various object surfaces, such as the metallic sheen of vehicles and the rough feel of road surfaces. The animation generation function, based on native animation capabilities and combined with skeletal animation technology of the model, accurately restores the movement trajectories of various element information, such as the walking posture of pedestrians, the riding state of bicycles, and the dynamic movement of vehicles. The pipeline management function is used to implement diverse customized functions based on specific functional requirements through a customized rendering pipeline management mechanism. Examples include the semi-transparent display effect of a vehicle occluding another vehicle, and dynamic changes in background and overall lighting effects over time. The data processing flow of the rendering module is as follows: Figure 8 As shown, in S801, SRBackend divides the original data into linear and non-linear data based on the data identifier type. It then sends both linear and non-linear data to SRFrontend. In S802, SRFrontend expands and translates the linear data. In S803, SRFrontend creates vertex data from the expanded and translated linear data. In S804, SRFrontend adds the business data of the linear data to the vertex data, creates the corresponding rendering mesh, and sends the rendering mesh corresponding to the linear data to KanziStudio. In S805, Kanzi Studio renders the rendering mesh. In S806, SRFrontend obtains the pre-stored rendering mesh corresponding to the non-linear data. In S807, SRFrontend optimizes the pre-stored rendering mesh to obtain the optimized rendering mesh and executes S805 based on the optimized rendering mesh.

[0156] To reduce the performance overhead of calculating character skeletal animation in the rendering engine, in one embodiment, the scene rendering method further includes steps S710-S750.

[0157] S710: Obtain target rendering mesh and preset skeletal animation curve data.

[0158] The target rendering mesh is the rendering mesh corresponding to the character elements in the preset non-linear data. The preset skeletal animation curve data is the trajectory data of the preset skeletal movement state changing over time, and the preset skeletal animation curve data can include the animation curve data of multiple bones.

[0159] In one embodiment, the target rendering mesh and preset skeletal animation curve data can be obtained through the rendering engine.

[0160] S720: Calculates the skeletal world coordinate matrix based on preset skeletal animation curve data.

[0161] The skeletal world coordinate matrix represents the absolute position of the skeleton within the reconstructed scene.

[0162] In one embodiment, the skeletal world coordinate matrix of the current frame can be calculated based on preset skeletal animation curve data according to the current frame number.

[0163] The current frame is the currently playing frame in the animation sequence corresponding to the preset skeletal animation.

[0164] In one embodiment of the above embodiments, calculating the skeletal world coordinate matrix of the current frame based on the current frame number and preset skeletal animation curve data may include steps S721 and S722.

[0165] S721: Based on the current frame number, obtain the local coordinate matrix of the bone relative to its parent bone from the bone animation curve data corresponding to each bone.

[0166] In this context, the parent bone is the bone above the child bone; if the parent bone moves, the child bone will move accordingly. For example, if the parent bone is the pelvis, the child bone could be the femur. The local coordinate matrix of a child bone is defined relative to its parent bone. The local coordinate matrix includes scaling, rotation, and unique information.

[0167] S722: Multiply the local coordinate matrix of each bone by the transformation matrix of the parent bone to obtain the world coordinate matrix of the bone.

[0168] In one embodiment, the local coordinate matrix of each bone can be recursively multiplied by the transformation matrix of each parent bone of that bone to obtain the bone world matrix.

[0169] S730: Iteratively calculate the bone world coordinate matrix corresponding to each frame in the animation sequence corresponding to the preset skeletal animation, and obtain multiple bone world coordinate matrices.

[0170] S740: Normalize multiple skeleton world coordinate matrices to obtain normalized skeleton world coordinate matrix data.

[0171] In one embodiment, each value in each of the multiple bone world coordinate matrices is normalized to a preset range to obtain normalized bone world coordinate matrix data, which is then used to adapt to the texture storage format.

[0172] In one example, the absolute maximum value corresponding to each value in the skeletal world coordinate matrix is ​​determined. Based on the absolute maximum value and the corresponding normalization value for each value in the skeletal world coordinate matrix, a normalized value is determined, thus normalizing each value in the skeletal world coordinate matrix data, resulting in normalized skeletal world coordinate matrix data. The specific formula for calculating the normalization value is: Normalized value = Coordinate value / (2 * Maximum value) + 0.5.

[0173] S750: Store the normalized skeletal world coordinate matrix data into the corresponding texture channel to obtain texture resources.

[0174] Texture resources are used to control the rendering engine to add skeletal animation to character elements when rendering the rendering mesh corresponding to character elements in non-linear data.

[0175] In one embodiment, the coordinate values ​​in the normalized skeletal world coordinate matrix can be stored in the corresponding texture channel according to a preset rule to obtain texture resources.

[0176] In one example, the preset rules are as follows: (1) The normalized skeletal world coordinate matrix is ​​a 4*4 matrix, in which only the first 12 values, i.e. the values ​​of the first three rows, need to be stored. The last row of 4 values ​​is fixed and therefore does not need to be stored.

[0177] (2) An RGB pixel can store 3 data, that is, the first 12 values ​​of a skeleton world coordinate matrix are stored by 12 / 3=4 RGB pixels.

[0178] (3) The texture size is determined based on the total number of frames of the skeletal animation and the number of bones. The texture height is equal to the total number of frames of the animation, and the width is the number of bones * 4.

[0179] (4) Store the normalized bone world coordinate matrix data into the corresponding texture channels in sequence to obtain the corresponding texture resources.

[0180] It is understood that the steps in the embodiments of the present invention are all executed before the program, including the rendering module, runs, i.e., pre-executed, without occupying any runtime CPU resources. Through this ideal processing method, the pre-stored texture data is used to create skeletal animations for the character element model in actual rendering, which can reduce the CPU burden during program execution, while maintaining compatibility with the standard rendering process and reducing the performance overhead caused by rendering large-scale character element scenes.

[0181] In one embodiment, the rendering engine renders based on texture data as follows: In the shader, based on the association between vertices and bones (up to 4 bones), and combined with the current frame number and bone ID, the corresponding data is read from the texture. Inverse normalization calculation is performed. The data in the R, G, and B channels are restored to the world coordinate matrix. The final vertex coordinates are calculated and applied by combining the associated bones and their respective weights.

[0182] Figure 9 This is a schematic diagram of a scene rendering device provided in an embodiment of the present invention. The device 900 includes an acquisition module 901, a classification module 902, an aggregation module 903, a creation module 904, and a rendering module 905.

[0183] Module 901 is used to acquire raw data; The classification module 902 is used to classify the raw data according to the data identifier type to obtain the initial classification data; Aggregation module 903 is used to aggregate data with the same material type in the initial classification data to obtain the target set; Create module 904, which is used to create a rendering mesh corresponding to the target set based on the data identifier type corresponding to the target set; Rendering module 905 is used to render the rendering mesh to obtain the target scene.

[0184] This invention acquires raw data. The raw data is categorized according to data identifier type to obtain initial categorized data. Data with the same material type in the initial categorized data is aggregated to obtain a target set. A rendering mesh corresponding to the target set is created based on the data identifier type of the target set. The rendering mesh is then rendered to obtain the target scene. This invention reduces the number of rendering meshes to be constructed by building a single rendering mesh for data of the same material type, thereby reducing performance overhead and improving rendering efficiency.

[0185] In one embodiment, the classification module 902 is specifically used for: The raw data is classified according to the data identifier type to obtain the first category of data; If the data identifier type of the first category data is detected to be linear data, the angle between the line connecting adjacent data in the first category data and the target direction is detected, and whether the distance difference between adjacent data is greater than or equal to the corresponding threshold is detected. If the angle between the line connecting adjacent data in the first category and the target direction is less than a preset angle threshold, or the distance difference between adjacent data is less than a preset distance threshold, the target number of adjacent data is deleted to obtain the initial category data.

[0186] In one embodiment, the apparatus 900 further includes an extension module, which is used to perform a translation and extension operation on the data in the target set when the data identifier type corresponding to the target set is detected to be linear data, so as to obtain the extended data; The expanded data is converted into coordinate-transformed data corresponding to the preset coordinate system; Create vertex data based on the coordinate transformation data; Add the business data included in the target set to the corresponding vertex data to obtain new vertex data; Create a vertex buffer layout according to the preset specifications; Construct a rendering mesh based on vertex data and vertex buffer layout; The target scene is obtained by rendering the rendering mesh, including: The target scene is obtained by rendering the rendering mesh based on the business data in the rendering mesh.

[0187] In one embodiment, the device 900 further includes a calculation module, which is used to obtain a first direction vector and a second direction vector, the first direction vector and the second direction vector being obtained based on data in the target set and adjacent data before and after it; Obtain the first weight and the second weight, which are based on the distance difference between the data in the target set and the data before and after it; Add the product of the first weight and the first direction vector to the product of the second weight and the corresponding second direction vector to obtain the updated direction vector; The data at the endpoints of the updated direction vector are translated by a preset distance along the normal direction perpendicular to the direction vector to obtain the expanded data.

[0188] In one embodiment, the device 900 further includes a calculation module, which is used to calculate the corresponding normal vector based on the coordinates corresponding to the coordinates of the data after coordinate transformation. The texture coordinates corresponding to the coordinate-transformed data are generated based on the length of the line segments composed of the coordinate-transformed data and the preset texture repetition frequency. Arrange the coordinate-transformed data in a preset order to obtain index data; Vertex data is created based on the coordinate-transformed data, normal vectors, texture coordinates, and index data.

[0189] In one embodiment, the acquisition module 901 is specifically used for: If the data identifier type corresponding to the target set is detected to be nonlinear data, obtain the rendering mesh corresponding to the nonlinear data; Transform the data in the target set into target data with coordinate transformation corresponding to the preset coordinate system; Create a vertex buffer layout according to the preset specifications; Build an optimized rendering mesh based on the rendering mesh, target data, and vertex buffer layout; The target scene is obtained by rendering the rendering mesh, including: The target scene is obtained by rendering the rendering mesh based on the business data in the optimized rendering mesh.

[0190] In one embodiment, the device 900 further includes a clearing module, which is used to clear historical raw data and data related to historical raw data when no new raw data is received within a preset time period.

[0191] In one embodiment, the device 900 further includes an execution module, which is used to perform a creation operation on the data corresponding to the target element information when the data corresponding to the target element information exists in the original data but the data corresponding to the target element information does not exist in the historical original data. If the target element information does not exist in the original data but exists in the historical original data, perform a deletion operation on the data corresponding to the target element information. If the target element information exists in both the original data and the historical original data, perform an update operation on the data corresponding to the target element information.

[0192] Figure 10 A schematic diagram of the scene rendering hardware structure provided in an embodiment of the present invention is shown.

[0193] The scene rendering device may include a processor 1001 and a memory 1002 storing computer program instructions.

[0194] Specifically, the processor 1001 may include a central processing unit (CPU), an application specific integrated circuit (ASIC), or one or more integrated circuits that can be configured to implement the embodiments of the present invention.

[0195] Memory 1002 may include mass storage for data or instructions. For example, and not limitingly, memory 1002 may include a hard disk drive (HDD), floppy disk drive, flash memory, optical disk, magneto-optical disk, magnetic tape, or Universal Serial Bus (USB) drive, or a combination of two or more of these. Where appropriate, memory 1002 may include removable or non-removable (or fixed) media. Where appropriate, memory 1002 may be internal or external to the integrated gateway disaster recovery device. In a particular embodiment, memory 1002 is non-volatile solid-state memory.

[0196] Memory 1002 may include read-only memory (ROM), random access memory (RAM), disk storage media device, optical storage media device, flash memory device, electrical, optical, or other physical / tangible memory storage device. Therefore, generally, memory includes one or more tangible (non-transitory) computer-readable storage media (e.g., memory devices) encoded with software including computer-executable instructions, and when the software is executed (e.g., by one or more processors), it is operable to perform the operations described with reference to the method according to one aspect of this disclosure.

[0197] The processor 1001 reads and executes computer program instructions stored in the memory 1002 to implement any of the scene rendering methods in the above embodiments.

[0198] In one example, the scene rendering device may also include a communication interface 1003 and a bus 1004. For example, Figure 10 As shown, the processor 1001, memory 1002, and communication interface 1003 are connected through bus 1004 and complete communication with each other.

[0199] The communication interface 1003 is mainly used to realize communication between various modules, devices, units and / or equipment in the embodiments of the present invention.

[0200] Bus 1004 includes hardware, software, or both, that couples components of an online data traffic metering device together. For example, and not limitingly, the bus may include an Accelerated Graphics Port (AGP) or other graphics bus, an Extended Industry Standard Architecture (EISA) bus, a Front Side Bus (FSB), a Hyper Transport (HT) interconnect, an Industry Standard Architecture (ISA) bus, an Infinite Bandwidth Interconnect, a Low Pin Count (LPC) bus, a memory bus, a Microchannel Architecture (MCA) bus, a Peripheral Component Interconnect (PCI) bus, a PCI-Express (PCI-X) bus, a Serial Advanced Technology Attachment (SATA) bus, a Video Electronics Standards Association Local (VLB) bus, or other suitable buses, or combinations of two or more of these. Where appropriate, bus 1004 may include one or more buses. Although specific buses are described and illustrated in embodiments of the invention, the invention contemplates any suitable bus or interconnect. Additionally, in conjunction with the scene rendering method in the above embodiments, embodiments of the invention also provide a computer storage medium for implementation. The computer storage medium stores computer program instructions; when the computer program instructions are executed by the processor, they implement any of the scene rendering methods in the above embodiments.

[0201] This invention also provides a computer program product, including a computer program that, when executed by a processor, implements any of the scene rendering methods described in the above embodiments. This invention further provides a vehicle, including a control device and a terminal. The terminal is used to implement the scene rendering methods described in the above embodiments, and the control device is used to implement the scene rendering methods described in the above embodiments.

[0202] It should be clarified that the present invention is not limited to the specific configurations and processes described above and shown in the figures. For the sake of brevity, detailed descriptions of known methods are omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of the present invention is not limited to the specific steps described and shown. Those skilled in the art can make various changes, modifications, and additions, or change the order of steps, after understanding the spirit of the present invention.

[0203] The functional blocks shown in the above structural diagram can be implemented as hardware, software, firmware, or a combination thereof. When implemented in hardware, they can be, for example, electronic circuits, application-specific integrated circuits (ASICs), appropriate firmware, plug-ins, function cards, etc. When implemented in software, the elements of this invention are programs or code segments used to perform the required tasks. Programs or code segments can be stored on a machine-readable medium or transmitted over a transmission medium or communication link via data signals carried on a carrier wave. "Machine-readable medium" can include any medium capable of storing or transmitting information. Examples of machine-readable media include electronic circuits, semiconductor memory devices, read-only memory (ROM), flash memory, erasable read-only memory (EROM), floppy disks, compact disc read-only memory (CD-ROM), optical disks, hard disks, fiber optic media, radio frequency (RF) links, etc. Code segments can be downloaded via computer networks such as the Internet, intranets, etc.

[0204] It should also be noted that the exemplary embodiments mentioned in this invention describe methods or systems based on a series of steps or apparatus. However, this invention is not limited to the order of the steps described above; that is, the steps can be performed in the order mentioned in the embodiments, or in a different order, or several steps can be performed simultaneously.

[0205] The aspects of this disclosure have been described above with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this disclosure. It should be understood that each block in the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing apparatus to produce a machine such that these instructions, executable via the processor of the computer or other programmable data processing apparatus, enable the implementation of the functions / actions specified in one or more blocks of the flowchart illustrations and / or block diagrams. Such a processor can be, but is not limited to, a general-purpose processor, a special-purpose processor, a special application processor, or a field-programmable logic circuit. It is also understood that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can also be implemented by special-purpose hardware performing the specified functions or actions, or can be implemented by a combination of special-purpose hardware and computer instructions.

[0206] The above are merely specific embodiments of the present invention. Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, modules, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here. It should be understood that the protection scope of the present invention is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in the present invention, and these modifications or substitutions should all be covered within the protection scope of the present invention.

Claims

1. A scene rendering method, characterized in that, The method includes: Obtain the raw data; The raw data is classified according to data identifier type to obtain initial classified data; Aggregate data with the same material type from the initial classification data to obtain the target set; Create a rendering mesh corresponding to the target set based on the data identifier type corresponding to the target set; The target scene is obtained by rendering the rendering mesh.

2. The method according to claim 1, characterized in that, The data identifier type includes linear data. The process of classifying the original data according to the data identifier type to obtain initial classified data includes: The raw data is classified according to data identifier type to obtain the first category of data; If the data identifier type of the first category data is detected to be linear data, the angle between the line connecting adjacent data in the first category data and the target direction is detected, and whether the distance difference between adjacent data is greater than or equal to the corresponding threshold is detected. If the angle between the line connecting adjacent data in the first classification data and the target direction is less than a preset angle threshold, or the distance difference between the adjacent data is less than a preset distance threshold, the target number of adjacent data is deleted to obtain the initial classification data.

3. The method according to claim 2, characterized in that, The step of creating a rendering mesh corresponding to the target set based on the data identifier type corresponding to the target set includes: If the data identifier type corresponding to the target set is detected to be linear data, a translation and expansion operation is performed on the data in the target set to obtain the expanded data. The expanded data is converted into coordinate-transformed data corresponding to a preset coordinate system; Create vertex data based on the coordinate transformation data; Add the business data included in the target set to the corresponding vertex data to obtain new vertex data; Create a vertex buffer layout according to the preset specifications; Construct a rendering mesh based on the vertex data and the vertex buffer layout; The process of rendering the rendering mesh to obtain the target scene includes: The target scene is obtained by rendering the rendering grid based on the business data in the rendering grid.

4. The method according to claim 3, characterized in that, The step of performing a translation and expansion operation on the data in the target set to obtain the expanded data includes: A first direction vector and a second direction vector are obtained, wherein the first direction vector and the second direction vector are composed of data in the target set and adjacent data; Obtain a first weight and a second weight, which are derived based on the distance difference between the data in the target set and its adjacent data. Add the product of the first weight and the first direction vector to the product of the second weight and the corresponding second direction vector to obtain the updated direction vector; The data of the endpoints that make up the updated direction vector are translated by a preset distance along the normal direction perpendicular to the direction vector to obtain the expanded data.

5. The method according to claim 3, characterized in that, Creating vertex data based on the coordinate-transformed data includes: Calculate the corresponding normal vector based on the coordinates of the data after coordinate transformation; Based on the line segment length of the data after coordinate transformation and the preset texture repetition frequency, generate the texture coordinates corresponding to the data after coordinate transformation; The data after coordinate transformation are arranged in a preset order to obtain index data; The vertex data is created based on the coordinate-transformed data, the normal vector, the texture coordinates, and the index data.

6. The method according to any one of claims 1-5, characterized in that, The data identifier type also includes nonlinear data, and the step of creating a rendering mesh corresponding to the target set based on the data identifier type corresponding to the target set includes: If the data identifier type corresponding to the target set is detected to be nonlinear data, obtain the rendering mesh corresponding to the nonlinear data; The data in the target set is converted into target data with coordinate transformation corresponding to the preset coordinate system; Create a vertex buffer layout according to the preset specifications; An optimized rendering mesh is constructed based on the rendering mesh, the target data, and the vertex buffer layout; The process of rendering the rendering mesh to obtain the target scene includes: The target scene is obtained by rendering the rendering mesh based on the business data in the optimized rendering mesh.

7. The method according to any one of claims 1-5, characterized in that, The method further includes: If no new raw data is received within a preset time period, the historical raw data and data related to the historical raw data are cleared.

8. The method according to any one of claims 1-5, characterized in that, The method further includes: If the original data contains data corresponding to the target element information but the historical original data does not contain data corresponding to the target element information, a creation operation is performed on the data corresponding to the target element information. If the original data does not contain data corresponding to the target element information but the historical original data does contain data corresponding to the target element information, a deletion operation is performed on the data corresponding to the target element information. If the original data contains data corresponding to the target element information and the historical original data contains data corresponding to the target element information, then an update operation is performed on the data corresponding to the target element information.

9. A scene rendering device, characterized in that, The device includes: The acquisition module is used to acquire raw data; A classification module is used to classify the raw data according to the data identifier type to obtain initial classification data; The aggregation module is used to aggregate data with the same material type in the initial classification data to obtain a target set; A creation module is used to create a rendering mesh corresponding to the target set based on the data identifier type corresponding to the target set. A rendering module is used to render the rendering mesh to obtain the target scene.

10. An electronic device, characterized in that, The device includes: a processor and a memory storing computer program instructions; the processor reads and executes the computer program instructions to implement the scene rendering method as described in any one of claims 1-8.