Dynamic target display method, device and electronic equipment

By performing dynamic target display on the graphics processor and utilizing GPU accelerated operations and Alpha blending technology, the problems of slow dynamic target display speed and poor effect in the existing technology are solved, and a fast and interactive dynamic target display effect is achieved.

CN114359018BActive Publication Date: 2024-09-13CHINESE PEOPLES LIBERATION ARMY UNIT 63891
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202111634992.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-29
Publication Date
2024-09-13
Estimated Expiration
2041-12-29

AI Technical Summary

Technical Problem

The existing CPU-based dynamic target image display method has the problems of slow operation speed and poor display effect, and cannot meet the real-time display needs of large batches of dynamic targets.

Method used

A graphics processor (GPU) is used for dynamic target display. By reading the primitive vertices and textures from the vertex buffer and texture buffer, the model view matrix operation, visibility and coincidence judgment are performed, and Alpha blending is used for real-time rendering. Quick display of dynamic targets.

Benefits of technology

It improves the calculation speed and display effect of dynamic target display, enables interactive real-time display on ordinary computers, and greatly reduces costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114359018B
    Figure CN114359018B
Patent Text Reader

Abstract

The present application provides a method, device and electronic device for displaying a dynamic target, and relates to the field of computer technology, specifically: reading primitive vertices and primitive textures from a pre-established vertex buffer and texture buffer as primitive vertices and primitive textures of a current drawing target; performing model view matrix operations on primitive vertices of the current drawing target, and calculating the viewpoint coordinates of primitive vertices of the current drawing target; making visible and coincidence judgments on the current drawing primitives according to the viewpoint coordinates of primitive vertices of the current drawing target, and performing corresponding processing; calculating rasterized pixel shading values ​​of primitive textures of the current drawing target; and performing real-time rendering of dynamic targets through Alpha blending based on rasterized pixel shading values ​​of primitive textures of the current drawing target, and synthesizing them into dynamic target images. The present application improves the computing speed and display effect of dynamic target display.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to a dynamic target display method, device and electronic equipment. Background Art

[0002] As the number of devices increases and the scale becomes larger, thousands or even tens of thousands of large quantities of entity unit symbols need to be displayed in real time.

[0003] The CPU-based dynamic target image display method has the disadvantages of slow computing speed and poor display effect. The traditional CPU volume rendering technology can no longer meet the real-time display requirements of large quantities of dynamic targets. Summary of the invention

[0004] In view of this, the present application provides a dynamic target display method, device and electronic device to solve the technical problems of slow computing speed and poor display effect in the CPU-based dynamic target image display method of the prior art.

[0005] On the one hand, an embodiment of the present application provides a dynamic target display method, which is applied to a graphics processor, including:

[0006] Read primitive vertices and primitive textures from the pre-established vertex buffer and texture buffer as the primitive vertices and primitive textures of the current drawing target;

[0007] Perform model view matrix operations on the primitive vertices of the current drawing target to calculate the viewpoint coordinates of the primitive vertices of the current drawing target;

[0008] According to the viewpoint coordinates of the primitive vertices of the current drawing target, the visibility and coincidence of the current drawing primitive are judged and processed accordingly;

[0009] Calculate the rasterized pixel shading value of the primitive texture of the current drawing target;

[0010] Based on the rasterized pixel shading value of the primitive texture of the current drawing target, the dynamic target is rendered in real time through Alpha blending and synthesized into a dynamic target image.

[0011] Furthermore, reading primitive vertices and primitive textures from the pre-established vertex buffer and texture buffer includes:

[0012] The dynamic target data is read in by the CPU and saved to the system memory in the form of an array sequence;

[0013] Create a vertex buffer through the CPU and bind the initial position of the dynamic target in the system memory to the vertex buffer;

[0014] Create a texture buffer through the CPU, and bind the primitive texture of the dynamic target in the system memory to the texture buffer;

[0015] The vertex buffer and the texture buffer are transferred to the video memory of the graphics processor through the CPU.

[0016] Furthermore, according to the viewpoint coordinates of the primitive vertices of the current drawing target, the visibility and coincidence of the current drawing primitive are judged, and corresponding processing is performed; including:

[0017] According to the viewpoint coordinates of the primitive vertices of the current drawing target, determine whether the current drawing primitive is within the window range, if not, remove the current drawing target;

[0018] Determine whether the current drawing primitive overlaps with other target primitives. If yes, aggregate the current drawing primitive and the overlapping target primitives into the same primitive.

[0019] Furthermore, judging whether the currently drawn primitive is within the window range according to the viewpoint coordinates of the primitive vertices of the currently drawn target, includes:

[0020] Get the current camera Cartesian coordinates and model view matrix;

[0021] According to the Cartesian coordinates of the camera and the viewpoint coordinates of the primitive vertices of the current drawing target, the normal of the window plane is calculated. If the normal is less than 0 degrees, the current drawing target is behind the display scene and is not within the window range; otherwise,

[0022] The screen coordinate point of the current drawing target is calculated according to the model view matrix and the viewpoint coordinates of the primitive vertices of the current drawing target. If the screen coordinate point is within the display window, it is determined that the current drawing primitive is within the window range.

[0023] Furthermore, it is determined whether the currently drawn primitive overlaps with other target primitives, including:

[0024] Through the depth buffer, it is determined whether the depth value of the pixel of the current drawing primitive is the same as the depth value of the pixel of other target primitives. If so, the current drawing primitive coincides with the other target primitives, otherwise the current drawing primitive does not coincide with the other target primitives.

[0025] Furthermore, the rasterized pixel shading value of the primitive texture of the current drawing target is calculated, including:

[0026] Calculate the viewpoint coordinates of the primitive texture of the current drawing target;

[0027] According to the Phong lighting model, the rasterized pixel shading value of each pixel of the primitive texture of the current drawing target is calculated.

[0028] Furthermore, the method further comprises:

[0029] After obtaining the updated position of the dynamic target, the data in the vertex buffer is updated.

[0030] On the other hand, an embodiment of the present application provides a dynamic target display device, including:

[0031] A reading unit, used for reading primitive vertices and primitive textures from a pre-established vertex buffer and texture buffer as primitive vertices and primitive textures of a current drawing target;

[0032] A viewpoint coordinate calculation unit, used to perform model view matrix operations on the primitive vertices of the current drawing target to calculate the viewpoint coordinates of the primitive vertices of the current drawing target;

[0033] A visible and coincidence processing unit, used to make a visible and coincidence judgment on the current drawing primitive according to the viewpoint coordinates of the primitive vertices of the current drawing target, and perform corresponding processing;

[0034] A rasterized pixel shading value calculation unit, used for calculating a rasterized pixel shading value of a primitive texture of a current drawing target;

[0035] The rendering unit is used to perform real-time rendering of the dynamic target through Alpha blending based on the rasterized pixel shading value of the primitive texture of the current drawing target, and synthesize it into a dynamic target image.

[0036] On the other hand, the present application implements an electronic device, including: a memory, a graphics processor, and a computer program stored in the memory and executable on the graphics processor, wherein the graphics processor implements the dynamic target display method of the embodiment of the present application when executing the computer program.

[0037] Compared with the existing CPU-based dynamic target image display method, the dynamic target display method of the embodiment of the present application has a faster computing speed and better display effect. BRIEF DESCRIPTION OF THE DRAWINGS

[0038] In order to more clearly illustrate the specific implementation methods of the present application or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0039] Figure 1 A flowchart of a dynamic target display method provided in an embodiment of the present application;

[0040] Figure 2 A schematic diagram of the functional structure of a dynamic target display device provided in an embodiment of the present application;

[0041] Figure 3 A schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0042] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all the embodiments. The components of the embodiments of the present application described and shown in the drawings here can be arranged and designed in various different configurations.

[0043] Therefore, the following detailed description of the embodiments of the present application provided in the accompanying drawings is not intended to limit the scope of the present application for which protection is sought, but merely represents selected embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in the field without creative work are within the scope of protection of the present application.

[0044] First, the design concept of the embodiments of the present application is briefly introduced.

[0045] The existing CPU-based dynamic target image display method has the disadvantages of slow computing speed and inability to perform interactively.

[0046] With the rapid development of GPU technology, more and more graphics and image computing and processing applications have been ported to GPU for processing. By utilizing the scale advantage of GPU parallel processing units and having an incomparable speed advantage over CPU, interactive visualization of large-scale data can be achieved on ordinary computer devices.

[0047] In order to solve the above technical problems, the present application provides a dynamic target display method based on a graphics processing unit (GPU), which uses the powerful stream computing capability of the GPU for acceleration, thereby achieving interactive real-time drawing effects of large quantities of dynamic targets. Compared with the existing CPU-based dynamic target image display method, the method of the embodiment of the present application has a very high computing speed and can achieve real-time interactive display on an ordinary computer; without the need to use a graphics workstation, the cost can be reduced. The present application is for fast real-time display of large quantities of dynamic target image sequences, and has good display effects.

[0048] After introducing the application scenarios and design concepts of the embodiments of the present application, the technical solutions provided by the embodiments of the present application are described below.

[0049] like Figure 1As shown, an embodiment of the present application provides a dynamic target display method, which is applied to a graphics processor and includes the following steps:

[0050] Step 101: Reading primitive vertices and primitive textures from the pre-established vertex buffer and texture buffer as primitive vertices and primitive textures of the current drawing target;

[0051] Prior to this step, the target data is read in by the CPU, a vertex buffer and a texture buffer are created, the target data is placed in the corresponding buffers, and then the vertex buffer and the texture buffer are transferred to the video memory of the graphics processor; including:

[0052] Read the target data and save it to the system memory in the form of array sequence;

[0053] Among them, the target data is composed of a series of two-dimensional target image sequences. The relevant information of these dynamic target images is read into the system memory. In order to improve the display effect of the target symbol graphics, preprocessing is required. Noise is removed by using image filters, and image clarity is enhanced by image enhancement.

[0054] Through the OpenGL interface function, create a vertex buffer and a texture buffer, bind the dynamic target initial position and the primitive texture to the corresponding buffer, and transfer the vertex buffer and the texture buffer to the GPU video memory.

[0055] A texture buffer is created as a normal buffer and becomes a real texture buffer when it is bound to a texture or GL_TEXTURE_BUFFER binding point.

[0056] glBindBuffer(GL_TEXTURE_BUFFER,texBO[0]);

[0057] glBufferData(GL_TEXTURE_BUFFER,Sizeof(float)*count,fileData,GL_STATIC_DRAW);

[0058] texBO must be bound to a texture unit to be useful. To bind a texBO to a texture you can call glTexBuffer, but first make sure the texture you want to use has been bound.

[0059] glActiveTexture(GL_TEXTURE1);

[0060] glBindTexture(GL_TEXTURE_BUFFER,texBOTexture);

[0061] glTexBuffer(GL_TEXTURE_BUFFER,GL_R32F,texBO[0]);

[0062] After the vertex buffer data passes through the bound buffer, call the OpenGL drawing interface function as follows:

[0063] / / Bind and load vertex array

[0064] glBindBuffer(GL_ARRAY_BUFFER,buffers[FOR_VERTICES]);

[0065] glBufferData(GL_ARRAY_BUFFER,sizeof(vertices),vertices,GL_STATIC_DRAW);

[0066] To use the texture buffer, you can use texelFetch to read from the texture buffer as follows:

[0067] uniform samplerBuffer lumCurveSampler;

[0068] void main(void)

[0069] {

[0070] int offset=int(vColor.r*(1024-1));

[0071] lumFactor.r=texelFetch(lumCurveSampler,offset).r

[0072] }

[0073] Step 102: Perform model view matrix operation on the primitive vertices of the current drawing target to calculate the viewpoint coordinates of the primitive vertices of the current drawing target;

[0074] Step 103: according to the viewpoint coordinates of the primitive vertices of the current drawing target, the visibility and coincidence judgment of the current drawing primitive is performed, and corresponding processing is performed;

[0075] Specifically, the step includes:

[0076] According to the viewpoint coordinates of the primitive vertices of the current drawing target, determine whether the current drawing primitive is within the window range, if not, remove the current drawing target;

[0077] In this embodiment, judging whether the currently drawn primitive is within the window range includes:

[0078] Get the current camera Cartesian coordinates and model view matrix;

[0079] According to the Cartesian coordinates of the camera and the viewpoint coordinates of the primitive vertices of the current drawing target, the normal of the window plane is calculated. If the normal is less than 0 degrees, the current drawing target is behind the display scene and is not within the window range; otherwise,

[0080] The screen coordinate point of the current drawing target is calculated according to the model view matrix and the viewpoint coordinates of the primitive vertices of the current drawing target. If the screen coordinate point is within the display window, it is determined that the current drawing primitive is within the window range.

[0081] Determine whether the current drawing primitive overlaps with other target primitives. If yes, aggregate the current drawing primitive and the overlapping target primitives into the same primitive.

[0082] The depth buffer is used to test whether the current drawing target coincides with other target primitives. The depth of the pixel of the currently drawn primitive is compared with the depth value of the corresponding point in the depth buffer to decide whether to draw the current pixel. If the depth test is TRUE, the current pixel is drawn and the depth buffer is updated with the current pixel depth value. Otherwise, it is not drawn.

[0083] Step 104: Calculate the rasterized pixel shading value of the primitive texture of the current drawing target;

[0084] Through the vertex coordinate transformation operation, the vertex coordinates of the target primitive texture data are transformed from the local coordinate system to the viewpoint coordinate system. First, the local coordinates of the four corner vertices of the target data are transformed into world coordinates, and then the world coordinates of the four vertices of the target data are transformed into the viewpoint coordinate system through the viewpoint world coordinate parameter matrix.

[0085] Read the target primitive texture and calculate the rasterized pixel shading value for each pixel of each polygon slice in the proxy geometry according to the Phong lighting model.

[0086] Reflected light is divided into three parts: ambient light, diffuse light and specular light.

[0087] Ambient light essentially refers to the indirect effect of light sources on objects after being affected by the environment. The intensity of this light is different at different points on the object, but in a simple lighting model, it is approximately considered that the intensity distribution of ambient light in the same environment is uniform, and the intensity of ambient light in any direction is the same, which is expressed as a constant.

[0088] Diffuse reflected light: The definition of diffuse reflected light is as follows: when the light source comes from one direction, diffuse reflected light will reflect and spread the light evenly in all directions, regardless of the intensity of the reflected light and the viewpoint, because diffuse reflected light is essentially caused by the uneven micro-surface of the reflective surface, and therefore the spatial distribution of diffuse reflected light is uniform.

[0089] Specular reflection light: The most typical example is that for an ideal mirror, the reflected light of the mirror is concentrated in one direction and obeys the law of reflection. Generalizing it, for a general smooth surface, the reflected light is concentrated in a spatial range, and the light intensity in the reflected direction determined by the law of reflection is the largest. Therefore, for the same point, the intensity of the specular reflection light observed from different positions is different, which is related to the line of sight and the direction of the specular reflection light.

[0090] Step 105: Based on the rasterized pixel shading value of the primitive texture of the current drawing target, the dynamic target is rendered in real time through Alpha blending to synthesize into a dynamic target image;

[0091] Alpha blending is a method of blending the colors of several polygon layers of the proxy geometry. The lighting model used by the GPU is for polygon vertices and cannot be used for volume rendering, so lighting must be turned off. Also, since Alpha blending is turned on, each polygon layer in the proxy geometry must be rendered, so depth testing must be turned off.

[0092] With depth testing turned off, turn on Alpha blending and synthesize all polygon slices in the proxy geometry into a large batch of dynamic targets in real time. To increase rendering speed, the proxy geometry can be saved to the display list, so that multiple vertices can be rendered with a single instruction, thereby improving drawing efficiency.

[0093] After this step, the method further comprises:

[0094] When the CPU obtains the updated position of the dynamic target, it updates the data in the vertex buffer.

[0095] Based on the above embodiments, the present application provides a dynamic target display device. Figure 2 As shown, the dynamic target display device 200 provided in the embodiment of the present application at least includes:

[0096] The reading unit 201 is used to read primitive vertices and primitive textures from the pre-established vertex buffer and texture buffer as primitive vertices and primitive textures of the current drawing target;

[0097] A viewpoint coordinate calculation unit 202, used to perform model view matrix operations on the primitive vertices of the current drawing target to calculate the viewpoint coordinates of the primitive vertices of the current drawing target;

[0098] A visible and coincidence processing unit 203, used to make a visibility and coincidence judgment on the current drawing primitive according to the viewpoint coordinates of the primitive vertices of the current drawing target, and perform corresponding processing;

[0099] The rasterized pixel shading value calculation unit 204 is used to calculate the rasterized pixel shading value of the primitive texture of the current drawing target;

[0100] The rendering and display unit 205 is used to render the dynamic target in real time through Alpha blending based on the rasterized pixel shading value of the primitive texture of the current drawing target, and synthesize it into a dynamic target image.

[0101] It should be noted that since the principle of solving the technical problem by the dynamic target display device 200 provided in the embodiment of the present application is similar to the dynamic target display method provided in the embodiment of the present application, the implementation of the dynamic target display device 200 provided in the embodiment of the present application can refer to the implementation of the dynamic target display method provided in the embodiment of the present application, and the repeated parts will not be repeated.

[0102] Based on the above embodiments, the present application also provides an electronic device, referring to Figure 3 As shown, the electronic device 300 provided in the embodiment of the present application includes at least: a processor 301, a memory 302, and a computer program stored in the memory 302 and executable on the processor 301. When the processor 301 executes the computer program, the dynamic target display method provided in the embodiment of the present application is implemented.

[0103] The electronic device 300 provided in the embodiment of the present application may further include a bus 303 connecting different components (including the processor 301 and the memory 302). The bus 303 represents one or more of several types of bus structures, including a memory bus, a peripheral bus, a local bus, and the like.

[0104] The memory 302 may include a readable medium in the form of a volatile memory, such as a random access memory (RAM) 3021 and / or a cache memory 3022 , and may further include a read-only memory (ROM) 3023 .

[0105] The memory 302 may also include a program tool 3024 having a set (at least one) of program modules 3025, the program modules 3025 including but not limited to: an operating subsystem, one or more applications, other program modules and program data, each of which or some combination may include the implementation of a network environment.

[0106] The electronic device 300 may also communicate with one or more external devices 304 (e.g., keyboards, remote controls, etc.), and may also communicate with one or more devices that enable a user to interact with the electronic device 300 (e.g., mobile phones, computers, etc.), and / or communicate with any device that enables the electronic device 300 to communicate with one or more other electronic devices 300 (e.g., routers, modems, etc.). Such communication may be performed through an input / output (I / O) interface 305. Furthermore, the electronic device 300 may also communicate with one or more networks (e.g., a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) through a network adapter 306. Figure 3 As shown, the network adapter 306 communicates with other modules of the electronic device 300 via the bus 303. It should be understood that although Figure 3 Not shown, other hardware and / or software modules may be used in conjunction with the electronic device 300, including but not limited to: microcode, device drivers, redundant processors, external disk drive arrays, disk arrays (Redundant Arrays of Independent Disks, RAID) subsystems, tape drives, and data backup storage subsystems.

[0107] It should be noted that Figure 3 The electronic device 300 shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.

[0108] It should be noted that, although several units or subunits of the device are mentioned in the above detailed description, this division is merely exemplary and not mandatory. In fact, according to the embodiments of the present application, the features and functions of two or more units described above can be embodied in one unit. Conversely, the features and functions of one unit described above can be further divided into multiple units to be embodied.

[0109] In addition, although the operations of the method of the present application are described in a specific order in the drawings, this does not require or imply that the operations must be performed in this specific order, or that all the operations shown must be performed to achieve the desired results. Additionally or alternatively, some steps may be omitted, multiple steps may be combined into one step, and / or one step may be decomposed into multiple steps.

[0110] Although the preferred embodiments of the present application have been described, those skilled in the art may make other changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications falling within the scope of the present application.

[0111] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit it. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein with equivalents. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present application.

Claims

1. A dynamic target display method, characterized in that: Applicable to graphics processors, including: Read primitive vertices and primitive textures from the pre-established vertex buffer and texture buffer as the primitive vertices and primitive textures of the current drawing target; Perform model view matrix operations on the primitive vertices of the current drawing target to calculate the viewpoint coordinates of the primitive vertices of the current drawing target; According to the viewpoint coordinates of the primitive vertices of the current drawing target, determine whether the current drawing primitive is within the window range. If not, remove the current drawing target; Determine whether the current drawing primitive overlaps with other target primitives. If yes, aggregate the current drawing primitive and the overlapping target primitives into the same primitive. Calculate the rasterized pixel shading value of the primitive texture of the current drawing target; Based on the rasterized pixel shading value of the primitive texture of the current drawing target, the dynamic target is rendered in real time through Alpha blending to be synthesized into a dynamic target image; Among them, judging whether the current drawing primitive is within the window range according to the viewpoint coordinates of the primitive vertex of the current drawing target includes: Get the current camera Cartesian coordinates and model view matrix; According to the Cartesian coordinates of the camera and the viewpoint coordinates of the primitive vertices of the current drawing target, the normal of the window plane is calculated. If the normal is less than 0 degrees, the current drawing target is not within the window range; otherwise, The screen coordinate point of the current drawing target is calculated according to the model view matrix and the viewpoint coordinates of the primitive vertices of the current drawing target. If the screen coordinate point is within the display window, it is determined that the current drawing primitive is within the window range.

2. The dynamic target display method according to claim 1, characterized in that: Reading primitive vertices and primitive textures from pre-built vertex buffers and texture buffers previously included: The dynamic target data is read in by the CPU and saved to the system memory in the form of an array sequence; Create a vertex buffer through the CPU and bind the initial position of the dynamic target in the system memory to the vertex buffer; Create a texture buffer through the CPU, and bind the primitive texture of the dynamic target in the system memory to the texture buffer; The vertex buffer and the texture buffer are transferred to the video memory of the graphics processor through the CPU.

3. The dynamic target display method according to claim 1, characterized in that: Determine whether the currently drawn primitive overlaps with other target primitives, including: Through the depth buffer, it is determined whether the depth value of the pixel of the current drawing primitive is the same as the depth value of the pixel of other target primitives. If so, the current drawing primitive coincides with the other target primitives, otherwise the current drawing primitive does not coincide with the other target primitives.

4. The dynamic target display method according to claim 1, characterized in that: Calculate the rasterized pixel shading value of the primitive texture of the current drawing target, including: Calculate the viewpoint coordinates of the primitive texture of the current drawing target; According to the Phong lighting model, the rasterized pixel shading value of each pixel of the primitive texture of the current drawing target is calculated.

5. The dynamic target display method according to claim 1, characterized in that: The method further comprises: After obtaining the updated position of the dynamic target, the data in the vertex buffer is updated.

6. A dynamic target display device, characterized in that: include: A reading unit, used for reading primitive vertices and primitive textures from a pre-established vertex buffer and texture buffer as primitive vertices and primitive textures of a current drawing target; A viewpoint coordinate calculation unit, used to perform model view matrix operations on the primitive vertices of the current drawing target to calculate the viewpoint coordinates of the primitive vertices of the current drawing target; A visible and coincidence processing unit, used to determine whether the current drawing primitive is within the window range according to the viewpoint coordinates of the primitive vertices of the current drawing target, and if not, to remove the current drawing target; determine whether the current drawing primitive overlaps with other target primitives, and if yes, to aggregate the current drawing primitive and the coincident target primitive into the same primitive; A rasterized pixel shading value calculation unit, used for calculating a rasterized pixel shading value of a primitive texture of a current drawing target; A rendering unit, for performing real-time rendering of a dynamic target through Alpha blending based on the rasterized pixel shading value of the primitive texture of the current drawing target, and synthesizing the dynamic target image; Among them, judging whether the current drawing primitive is within the window range according to the viewpoint coordinates of the primitive vertex of the current drawing target includes: Get the current camera Cartesian coordinates and model view matrix; According to the Cartesian coordinates of the camera and the viewpoint coordinates of the primitive vertices of the current drawing target, the normal of the window plane is calculated. If the normal is less than 0 degrees, the current drawing target is not within the window range; otherwise, The screen coordinate point of the current drawing target is calculated according to the model view matrix and the viewpoint coordinates of the primitive vertices of the current drawing target. If the screen coordinate point is within the display window, it is determined that the current drawing primitive is within the window range.

7. An electronic device, characterized in that: include: A memory, a graphics processor, and a computer program stored in the memory and executable on the graphics processor, wherein the graphics processor implements the dynamic target display method according to any one of claims 1 to 5 when executing the computer program.

Citation Information

Patent Citations

  • Method for rendering contour edges of models

    CN102708585A

  • Graph processing method and device

    CN105741228A

  • Two dimension situation map forming method and electronic equipment

    CN106780659A

  • Multiple shader processes in graphics processing

    CN110291563A

  • Graphics processor, and method for rendering processing

    JP2008282171A