CN115049774A - Graphic processing method, processor, storage medium and terminal device - Google Patents

Graphic processing method, processor, storage medium and terminal device Download PDF

Info

Publication number
CN115049774A
CN115049774A CN202210969665.8A CN202210969665A CN115049774A CN 115049774 A CN115049774 A CN 115049774A CN 202210969665 A CN202210969665 A CN 202210969665A CN 115049774 A CN115049774 A CN 115049774A
Authority
CN
China
Prior art keywords
graphics
rendering
graph
sub
tasks
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202210969665.8A
Other languages
Chinese (zh)
Other versions
CN115049774B (en
Inventor
江靖华
张坚
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenliu Micro Intelligent Technology Shenzhen Co ltd
Original Assignee
Shenliu Micro Intelligent Technology Shenzhen Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenliu Micro Intelligent Technology Shenzhen Co ltd filed Critical Shenliu Micro Intelligent Technology Shenzhen Co ltd
Priority to CN202210969665.8A priority Critical patent/CN115049774B/en
Publication of CN115049774A publication Critical patent/CN115049774A/en
Application granted granted Critical
Publication of CN115049774B publication Critical patent/CN115049774B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T15/003D [Three Dimensional] image rendering
    • G06T15/005General purpose rendering architectures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5027Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/50Indexing scheme relating to G06F9/50
    • G06F2209/5017Task decomposition
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/50Indexing scheme relating to G06F9/50
    • G06F2209/5018Thread allocation

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Computer Graphics (AREA)
  • General Engineering & Computer Science (AREA)
  • Image Generation (AREA)

Abstract

The application discloses a graphic processing method, a processor, a storage medium and a terminal device, wherein the method comprises the following steps: dividing a display interface into a plurality of interface areas; dividing rendering data of a graph to be processed into n data sets according to a plurality of interface areas; determining a graph rendering task of each data set to obtain n graph rendering tasks; executing n graphics rendering tasks through m graphics processing units to obtain n pixel point sets; and for each pixel point set, displaying a local graph of the graph to be processed in the corresponding interface area according to the pixel point set. The rendering data is divided based on a plurality of interface areas, and the graphics rendering task is asynchronously executed aiming at the data sets of different interface areas, so that the graphics processing efficiency is improved.

Description

Graphic processing method, processor, storage medium and terminal device
Technical Field
The present application relates to the field of graphics processing technologies, and in particular, to a graphics processing method, a processor, a storage medium, and a terminal device.
Background
When a 3D graph in a 3D rendered scene is presented on a display interface, the content presented on the display interface changes both due to viewing angle and due to scene change, wherein one display interface may cover multiple 3D graphs.
Generally, when content presented on a display interface is changed, graphics processing operations need to be re-executed to present a new 3D graphic, where the graphics processing operations are divided into two phases, a first phase is a geometric phase, i.e., drawing a 3D graphic, and a second phase is a rasterization phase, i.e., rendering all 3D graphics drawn to present on the display interface.
Because the processing progress of different 3D graphics in the geometric stage and the rasterization stage is different, the graphics processing efficiency will be low if the conventional graphics processing method is adopted.
Disclosure of Invention
The embodiment of the application provides a graphic processing method, a processor, a storage medium and a terminal device, which can improve graphic processing efficiency.
In a first aspect, an embodiment of the present application provides a graphics processing method, including:
dividing a display interface into a plurality of interface areas;
dividing rendering data of a graph to be processed into n data sets according to a plurality of interface areas;
determining a graph rendering task of each data set to obtain n graph rendering tasks, wherein the graph rendering tasks comprise multiple levels of sub rendering tasks, and processing results of the sub rendering tasks of the previous level above each level of sub rendering tasks are used as input;
determining the similarity among n data sets;
if the similarity is greater than a preset threshold value, distributing each level of sub-rendering tasks of each graphics rendering task in the n graphics rendering tasks to one graphics processing unit in the m graphics processing units for execution to obtain n pixel point sets, wherein n and m are positive integers greater than 1;
if the similarity is not greater than the preset threshold, for each graphics rendering task in the n graphics rendering tasks, gradually allocating each level of sub-rendering tasks in each graphics rendering task to one graphics processing unit in the m graphics processing units for execution to obtain n pixel point sets;
executing n graphics rendering tasks through m graphics processing units to obtain n pixel point sets, wherein n and m are positive integers greater than 1;
and for each pixel point set, displaying a local graph of the graph to be processed in the corresponding interface area according to the pixel point set.
In a second aspect, an embodiment of the present application further provides a processor, where the processor is configured to execute the graphics processing method provided in any embodiment of the present application.
In a third aspect, an embodiment of the present application further provides a computer-readable storage medium, on which a computer program is stored, and when the computer program runs on a computer, the computer is caused to execute a graphics processing method as provided in any embodiment of the present application.
In a fourth aspect, an embodiment of the present application further provides a terminal device, including a processor and a memory, where the memory has a computer program, and the processor is configured to execute the graphics processing method provided in any embodiment of the present application by calling the computer program.
According to the technical scheme, the display interface is divided into the plurality of interface areas, the rendering data of the graph to be processed is divided into the plurality of data sets according to the plurality of interface areas, so that the rendering data are divided, a plurality of graph rendering tasks are determined according to the plurality of data sets independently, and when the graph rendering tasks are executed, the plurality of graph rendering tasks are distributed to the plurality of graph processing units to be executed asynchronously, so that the pixel point set corresponding to each graph rendering task is obtained, and the processing efficiency of the graph to be processed is improved. In addition, local graphs of the graph to be processed are sequentially displayed in the interface area corresponding to the display interface according to the sequence of completing the graph rendering task and the pixel point set, so that the display efficiency of the graph on the display interface is improved, and the viewing effect is guaranteed.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the description below are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a schematic view of an application scenario of a graphics processing method according to an embodiment of the present application.
Fig. 2 is a schematic flowchart of a graphics processing method according to an embodiment of the present disclosure.
Fig. 3 is a schematic diagram of a graph to be processed in the graph processing method according to the embodiment of the present application.
Fig. 4 is a schematic diagram illustrating scheduling of each level of sub-rendering tasks in the graphics processing method according to the embodiment of the present application.
Fig. 5 is a schematic display interface diagram of a graphics processing method according to an embodiment of the present disclosure.
Fig. 6 is a schematic structural diagram of a terminal device according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application. It should be apparent that the described embodiments are only some of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without inventive step, are within the scope of the present application.
Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the application. The appearances of the phrase in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. It is explicitly and implicitly understood by one skilled in the art that the embodiments described herein may be combined with other embodiments.
An execution main body of the graphics processing method may be the processor provided in the embodiments of the present application, or a terminal device provided with the processor. The processor can be realized in a hardware or software mode, and the terminal equipment can be a smart phone, a tablet personal computer, a palm computer and the like.
To better understand the solution provided by the embodiment of the present application, an application scenario is provided here, please refer to fig. 1, fig. 1 is a schematic view of an application scenario of the graphics processing method provided by the embodiment of the present application, the application scenario is a game scenario, and a terminal device takes a mobile phone as an example. For example, when a user operates a mobile phone to change a content to be presented in a game scene, the user needs to draw a new 3D graphic (shown in a line drawing, as shown in the upper left side of fig. 1), and after the graphic drawing, the user also needs to render the 3D graphic (shown in a color drawing, as shown in the upper right side of fig. 1), and finally presents the new graphic on the screen of the mobile phone.
It can be understood that the solution provided by the present application is applicable to various application scenes, such as game scenes, modeling scenes, movie scenes, animation scenes, etc., and stereoscopic graphics, such as three-dimensional stereoscopic graphics (3D graphics), four-dimensional stereoscopic graphics (4D graphics), five-dimensional stereoscopic graphics (5D graphics), etc., are used in such application scenes.
Referring to fig. 2, fig. 2 is a schematic flow chart illustrating a graphics processing method according to an embodiment of the present disclosure. The specific flow of the graphics processing method provided by the embodiment of the application may be as follows.
101. The display interface is divided into a plurality of interface areas.
In one aspect, the geometry of the divided interface region is not limited. The geometric shape can be determined, and then the display interface is divided according to the specific geometric shape to obtain a plurality of interface areas with specific geometric shapes. Wherein the geometric shape is, for example, a rectangle, a triangle, an octagon, etc. The geometric shapes of the interface regions may be the same or different, and may be determined according to actual requirements.
On the other hand, the number of the divided interface regions is not limited herein. The number of the interface areas can be set to be constant, and the number of the interface areas can also be set to be changed according to actual requirements.
102. And dividing rendering data of the graph to be processed into n data sets according to the interface areas.
Generally, when dividing rendering data of a graphic to be processed, a part of the rendering data of the graphic to be processed can be divided into a plurality of data sets by using a boundary of each interface region as a reference. The graph to be processed covers all contents of a display interface, the rendering data refers to a vertex data set required by the graph to be processed, and each vertex data comprises a vertex coordinate, a vertex color, a vertex normal, a texture coordinate, illumination information and the like.
Referring to fig. 3, fig. 3 is a schematic diagram of a graph to be processed in the graph processing method according to the embodiment of the present application. For example, the display interface is divided into 16, and accordingly, the to-be-processed graphics are divided into 16 parts, where one 3D graphic can be distributed in multiple interface areas, for example, fig. 3 shows that 15 interface areas each include a partial graphic of one 3D graphic. As can also be seen from fig. 3, after the interface region is divided, there is also a blank interface region. Therefore, when a plurality of interface regions each have a graphic, the number of interface regions is the same as the number of data sets. When there are blank interface regions in the plurality of interface regions, the blank interface regions do not have corresponding data sets, i.e., the number of interface regions is greater than the number of data sets.
103. And determining the graph rendering task of each data set to obtain n graph rendering tasks.
The graphics rendering task includes a geometry phase and a rasterization phase. The geometric stage and the rasterization stage both comprise a plurality of levels (pipelines) of sub-rendering tasks, and the processing result of the sub-rendering task of the upper level of each level of sub-rendering tasks is used as input.
The multi-level sub-rendering tasks of the geometric stage are as follows.
1.1, drawing a triangle according to a vertex data set through a vertex shader, completing coordinate transformation and calculating vertex color;
1.2, subdividing the curved surface, subdividing the triangular surface, and generating interpolation colors on the subdivided vertexes;
1.3, a geometry shader for changing the shape of the triangle and changing the number of vertices;
1.4, assembling the primitives, wherein the primitives are used for assembling the triangles into a specified graph;
1.5, eliminating the graphs used for reducing the number of graphs entering rasterization;
1.6, cutting out part of the graph positioned outside the view cone;
1.7, back face removing, which is used for removing partial graphs back to the camera;
1.8, screen mapping for mapping the graphic coordinates to screen coordinates (i.e., two-dimensional coordinates) of the display interface.
The multi-level sub-rendering tasks of the rasterization stage are as follows.
2.1, setting triangles and calculating information required by rasterizing a triangular mesh;
2.2, traversing the triangle, and finding out which pixels are covered by the triangular mesh, and interpolating the pixels in the covered area through triangle vertex information to obtain a fragment sequence, wherein information contained in one fragment comprises screen coordinates, depth information and vertex information;
2.3, a fragment shader for processing the pixel fragments transmitted after rasterization, including calculating the illumination information, texture map, jaggies and anti-jaggies, shadows, etc. of the pixel fragments, wherein each pixel fragment is a pixel set;
and 2.4, performing hybrid test, namely performing cutting test, transparency test, depth/template test, depth test, hidden surface elimination, cone elimination, entrance elimination, shielding elimination and the like, and rendering the pixel fragments passing the test into a display interface.
104. The similarity between the n data sets is determined.
The determining of the similarity between the n data sets refers to determining the similarity between every two data sets, and when the similarity is compared with a preset threshold, whether all the similarities are greater than the preset threshold is compared.
For example, the similarity between every two data sets can represent the similarity between the local graphs to be processed, for example, the local graphs obtained by graphic processing of every two data sets are the same, i.e., both data sets are considered to be similar (the similarity is not greater than a preset threshold), otherwise, both data sets are not similar (the similarity is greater than the preset threshold). For another example, the similarity between every two data sets can also represent the similarity of the task quantities of the local graph to be processed, and if the task quantities of every two data sets are different in the graph processing, the two data sets are considered to be similar, otherwise, the two data sets are not similar.
105. If the similarity is greater than a preset threshold value, each level of sub-rendering tasks of each graphics rendering task in the n graphics rendering tasks is distributed to one graphics processing unit in the m graphics processing units to be executed, and a pixel point set corresponding to each graphics rendering task is obtained, wherein n and m are positive integers greater than 1.
And executing n graphics rendering tasks through the m graphics processing units to obtain n pixel point sets.
The Graphic Processing Unit may be a CPU (Central Processing Unit) or a GPU (Graphic Processing Unit), and this is not limited, and it is only required to describe that the terminal device has a multi-core processor.
Illustratively, m may be the number of all processors in the terminal device, or may be the number of partial processors in the terminal device. The number of processors may also be used as the number of interface regions in determining the number of interface regions.
The relationship between n and m is not limited herein, and n ═ m, n > m, or n < m. When n is less than or equal to m, distributing a graphic processing unit for a graphic rendering task; when n is greater than m, m graphics rendering tasks can be executed by m graphics processing units, and then the remaining graphics rendering tasks are executed, so as to circulate until n graphics rendering tasks are executed.
For n graphics rendering tasks with the similarity greater than the preset threshold, a graphics processing unit can be allocated to each graphics rendering task to execute each level of sub-rendering tasks of the graphics rendering task, that is, all sub-rendering tasks of one graphics rendering task are executed in the same graphics processing unit, so that the sub-rendering tasks need to be scheduled in different graphics processing units, and the time consumed for scheduling is saved.
106. And if the similarity is not greater than the preset threshold, for each graphics rendering task in the n graphics rendering tasks, gradually allocating each level of sub-rendering tasks in each graphics rendering task to one graphics processing unit in the m graphics processing units for execution, and obtaining a pixel point set corresponding to each graphics rendering task.
For n graphics rendering tasks with the similarity not greater than the preset threshold, it is described that each level of sub rendering tasks included in the n graphics rendering tasks may be different, and the processing schedules of the sub rendering tasks at different levels are also different, so that the n graphics rendering tasks may be distributed among the m graphics processing units for each level of sub rendering tasks. During the re-allocation, the next level sub-rendering task and the previous level sub-rendering task of the same graphics rendering task can be processed by the same graphics processing unit, or by different graphics processing units, specifically according to the scheduling policy.
107. And for each pixel point set, displaying a local graph of the graph to be processed in the corresponding interface area according to the pixel point set.
The information of a plurality of pixels, such as pixel values, pixel bit depths, and the like, is collected in one pixel set, and one pixel set refers to a set of pixels forming a local graphic in a corresponding interface region. After the last level of sub-rendering task of a certain graphic rendering task is executed by the graphic processing unit, a corresponding pixel point set can be obtained, a local graphic can be obtained according to the pixel point set and displayed in the corresponding interface area, and the local graphics of all the interface areas form a complete graphic displayed after the graphic processing of the graphic to be processed.
Partial graphs can be displayed firstly by displaying the partial graphs according to the completion condition of the graph rendering task corresponding to each interface area, so that a user can know the updated interface content in advance, and the user experience is improved.
In particular implementation, the present application is not limited by the execution sequence of the described steps, and some steps may be performed in other sequences or simultaneously without conflict.
According to the graphic processing method in the embodiment of the application, the display interface is divided into the plurality of interface areas, the rendering data of the graph to be processed is divided into the plurality of data sets according to the plurality of interface areas, so that the rendering data are divided, a plurality of graphic rendering tasks are determined according to the plurality of data sets independently, and the plurality of graphic rendering tasks are distributed to the plurality of graphic processing units to be executed asynchronously when the graphic rendering tasks are executed, so that the processing efficiency of the graph to be processed is improved. In addition, after the graphics rendering task is executed by the graphics processing unit to obtain the corresponding pixel point sets, the local graphics of the graphics to be processed are sequentially presented in the interface area corresponding to the display interface according to the pixel point sets according to the sequence of completing the graphics rendering task, so that the display efficiency of the graphics on the display interface is improved, and the viewing effect is ensured.
In some embodiments, 101 comprises:
1011. acquiring information indicated by preset conditions, and determining the number of interface areas according to the information, wherein the preset conditions comprise at least one of the task quantity of the graph to be processed, the current use scene and the system resource occupancy rate;
1012. and dividing the display interface into a plurality of interface areas according to the number.
This embodiment provides a way of setting the number of interface regions. For example, preset conditions are preset, and when the number of the interface regions is determined, the number of the interface regions can be determined by analyzing information indicated by the preset conditions, so that the display interface is divided according to the determined number of the interface regions, the dividing mode is more flexible, and different graphic processing requirements can be met.
As an embodiment, 1011 includes: and acquiring the task quantity of the graph to be processed, and determining the number of the interface areas according to the task quantity. The graph to be processed is a three-dimensional graph, and the task amount can indicate the complexity of the graph to be processed. For example, simple 3D graphics have a small amount of tasks when performing graphics processing. The complex 3D graphics have a large amount of tasks in graphics processing. Therefore, the number of interface regions is small when the number of tasks is small, and the number of interface regions is large when the number of tasks is large.
The corresponding relation between the task amount and the number can be preset, and the number can be determined according to the corresponding relation after the task amount is determined.
As another embodiment, 1011 further includes: and acquiring a current use scene, and determining the number of interface areas according to the current use scene. If the application program is game software, the image processing efficiency is high, and therefore the number of the settable interface areas is large. And if the application program is film and television software, the requirement on the graphic processing efficiency is not high, and the number of the settable interface areas is less. The number of corresponding interface areas can be set for different applications, wherein the number of different applications can be the same or different, depending on the requirement for graphics processing efficiency.
As above, the current usage scenario is also, for example, the content to be presented in a certain application. For example, for the same game software, if sniper games are loaded, higher graphics processing efficiency is required, and a larger number of interface regions can be set. If the treasure hunt game is loaded, the higher graphic processing efficiency is not needed, and the number of the interface areas can be set to be less.
Therefore, the number of the interface areas can be dynamically changed according to different application programs, and the number of the interface areas can be dynamically changed according to different contents loaded in the same application program, so that the dividing mode of the interface areas is more flexible, and the graphic processing efficiency and the graphic display effect can be considered at the same time.
As still another embodiment, 1011 further comprises: and acquiring the occupancy rate of system resources, and determining the number of the interface areas according to the occupancy rate of the system resources. The system resource occupancy rate can indicate the memory space of the terminal equipment, and further indicate the fluency degree when the graphics to be processed are processed. When the system resource occupancy rate is high, the graphics to be processed are relatively unsmooth in processing, and the number of the interface areas can be set to be large. Conversely, if the system resource occupancy rate is low, the number of the interface areas can be set to be small.
Following the above, the number of interface regions may be determined by combining a plurality of preset conditions. For example, in combination with the task amount of the to-be-processed graph and the system resource occupancy rate, if the number of the interface areas determined according to the task amount of the to-be-processed graph is 14, but the number of the interface areas determined according to the system resource occupancy rate is 12, the number may be determined again to be 13 or 12. If the number of the interface areas determined according to the system resource occupancy rate is 18, 14 interface areas may be used as the final number, and naturally, the number may be adaptively increased to 15 or 16. The method for determining the quantity by combining multiple factors can take account of the smoothness of system operation and the graphic processing efficiency.
Illustratively, 1012 further includes: the geometry of the interface regions is determined, and the display interface is divided into a plurality of interface regions according to the number and the geometry.
When the interface area is divided according to the geometric shape, on one hand, the geometric shape can be divided and determined according to a horizontal screen display mode or a vertical screen display mode, and the horizontal screen display mode or the vertical screen display mode is determined according to a display mode commonly used by an application program. For example, a rectangle may be used in the horizontal screen display mode, and a triangle may be used in the vertical screen display mode.
On the other hand, the position of the to-be-processed graph in the display interface can be determined, for example, a rectangle can be adopted if the to-be-processed graph is centered, and a triangle can be adopted if the to-be-processed graph is not centered.
Since there are many ways to determine the geometric shape, which are not limited herein, it is understood that the geometric shape and the number of the above mentioned interface areas can also be set by the user in a customized manner, which is not limited herein.
In this embodiment, the interface area is divided by combining the number and the geometric shape, so as to consider both the processing efficiency of the graphics to be processed and the display effect when displaying a new graphics.
In some embodiments, 103 comprises:
and respectively determining the graph rendering tasks for the n data sets according to the attribute information of the n data sets, wherein the graph rendering tasks corresponding to different attribute information are different.
Wherein the attribute information of the data set refers to the graphics rendering effect, the graphics shading effect, the lighting effect, the perspective effect, and the like indicated by the above-mentioned vertex data. And setting different graphic rendering tasks for the graphics of different interface areas according to the attribute information, wherein the graphic rendering tasks are selected from the sub rendering tasks of 1.1-1.8 of the above mentioned geometric stage and the sub rendering tasks of 2.1-2.4 of the rasterization stage, and the sub rendering tasks in the mixing test of 2.4 are also optional.
For example, if the graphics has perspective effect, the sub-rendering task 1.7 may not be added to the graphics rendering task, and if the graphics has perspective effect, the transparency test mode in the sub-rendering task 2.4 may not be used. For another example, if the graphics are smooth, it is not necessary to add the sub-rendering task 1.2 and the sub-rendering task 1.3 to the graphics rendering task.
It will be appreciated that the different graphics rendering tasks may contain the same or different sub-rendering tasks. In this embodiment, the setting of different graphics rendering tasks for different data sets is based on the graphics effect, and the corresponding graphics processing task can be set according to the graphics effect of the local graphics to be processed in different interface regions, so that the step that all the local graphics need to execute all the geometric stages and the rasterization stage is avoided, and unnecessary steps are omitted, thereby improving the graphics processing efficiency. Meanwhile, the graphics rendering task can be adaptively adapted, the flexibility of setting the graphics processing task is improved, and system resources are saved.
Illustratively, the ordering of each level of sub-rendering tasks in the graphics rendering task may also be determined according to the attribute information, wherein the ordering of each level of sub-rendering tasks in different graphics rendering tasks may be the same or different.
It can be understood that the graphic rendering task corresponding to each data set can be set by the user in a customized manner, so that different display effects can be obtained in different interface areas, and the diversity of display modes is improved.
In some embodiments, assigning each level of sub-rendering tasks of each of the n graphics rendering tasks to one of the m graphics processing units for execution comprises:
when n is less than or equal to m, distributing a graphics processing unit for each of the n graphics rendering tasks, and calling each graphics processing unit to execute each level of sub-rendering tasks of the graphics rendering tasks distributed on each graphics processing unit;
and when n is larger than m, determining the rendering sequence of the n graphics rendering tasks, distributing a graphics processing unit to the n graphics rendering tasks according to the rendering sequence, and calling each graphics processing unit to execute each level of sub-rendering tasks of the graphics rendering tasks distributed on the graphics processing unit according to the rendering sequence.
As an embodiment, for the case that n > m, the following is specifically included:
determining the rendering sequence of n graphic rendering tasks, and distributing a graphic processing unit for each of the first m graphic rendering tasks in the rendering sequence;
calling each graphics processing unit to execute each level of sub-rendering tasks of the graphics rendering tasks distributed on each graphics processing unit;
for a first target graphic processing unit which completes the graphic rendering task, distributing the graphic rendering task to be executed to the first target graphic processing unit according to the rendering sequence;
and calling the first target graphic processing unit to execute each level of sub-rendering tasks of the graphic rendering task to be executed until each level of sub-rendering tasks of the last graphic rendering task is executed.
For example, there are 5 gpu, 8 gpu tasks, and the gpu tasks are sequenced into A, B, C, D, E, F, G, H, and the gpu tasks indicated by A, B, C, D, E are executed by the 5 gpu tasks respectively. Then, by determining which of the 5 gpu completes the graphics rendering task first, for example, completes the graphics rendering task indicated by C first, the graphics rendering task indicated by F is allocated to the gpu which completes the graphics rendering task indicated by C to execute, and so on, each time the 5 gpu completes one graphics rendering task, the gpu which completes the graphics rendering task is selected from the remaining to-be-executed graphics rendering tasks according to the rendering order and allocated to the first target gpu until each level of sub-rendering tasks of the last graphics rendering task is completed, where the gpu which completes the graphics rendering task is called the first target gpu.
As another embodiment, the n graphics rendering tasks may be processed in batch, that is, m graphics rendering tasks are executed by m graphics processing units each time, and after all the m graphics rendering tasks are executed, new m graphics rendering tasks are selected from the unexecuted graphics rendering tasks and distributed to the m graphics processing units for execution, and so on until each level of sub-rendering tasks of the last graphics rendering task is completed. It will be appreciated that the number of graphics rendering tasks for the last batch may be less than m.
In some embodiments, for each graphics rendering task of the n graphics rendering tasks, allocating each level of sub-rendering tasks of each graphics rendering task to one graphics processing unit of the m graphics processing units step by step for execution, and obtaining a pixel point set corresponding to each graphics rendering task, includes:
for the current level sub-rendering tasks of the n graphics rendering tasks, distributing a graphics processing unit for the n current level sub-rendering tasks, and calling each graphics processing unit to execute the current level sub-rendering task distributed on the graphics processing unit;
and for the finished sub-rendering tasks at the current level, redistributing the sub-rendering tasks at the next level corresponding to the finished sub-rendering tasks at the current level to one of the m graphic processing units for execution until the last sub-rendering task at the last level of the last graphic rendering task is executed, and obtaining a pixel point set corresponding to each graphic rendering task.
In this embodiment, each time a current level sub-rendering task of any one of the n graphics rendering tasks is completed, a graphics processing unit may be reallocated for a next level sub-rendering task of the one graphics rendering task to execute the next level sub-rendering task, specifically, one graphics processing unit may be selected from the m graphics processing units during reallocation.
For example, n first-level sub-rendering tasks may be randomly allocated among m graphics processing units for the first-level sub-rendering task of each graphics rendering task, or a specific graphics processing unit may be selected for each first-level sub-rendering task. For example, when the task size of the first level sub-rendering task is large, one of the m gpu with the fastest processing speed may be selected. When the task amount of the first level sub-rendering task is small, one of the m graphics processing units having the slowest processing rate can be selected. Preferably, the n first-level sub-rendering tasks may be sorted in descending order according to the task amount, and then sorted in descending order according to the processing efficiency of the m graphics processing units, and further the first-level sub-rendering tasks are allocated to one graphics processing unit with the same sorting one by one according to a one-to-one correspondence relationship.
For the allocation of the sub-rendering tasks of the non-first level in the m gpu, please refer to fig. 4, and fig. 4 is a schematic diagram illustrating scheduling of the sub-rendering tasks of each level in the graphics processing method according to the embodiment of the present disclosure. For example, there are 5 graphics processing units, denoted by a, B, C, D, E, 5 graphics rendering tasks, the first graphics rendering task denoted by a, the second graphics rendering task denoted by B, the third graphics rendering task denoted by C, the fourth graphics rendering task denoted by D, and the fifth graphics rendering task denoted by E. The first level sub-rendering tasks corresponding to each graphics rendering task are respectively A1, B1, C1, D1 and E1, and the sub-rendering tasks included in the first graphics rendering task are respectively A1, A2, A3, A4, A5, A6 and A7. If the first level sub-rendering task A1 of the first graphics rendering task is executed on GPU a, after the first level sub-rendering task A1 is completed, the second level sub-rendering task A2 may be allocated to GPU d for execution, after the second level sub-rendering task A2 is completed, the third level sub-rendering task A3 may be allocated to GPU d for execution, and so on, until the last level sub-rendering task A7 of the first graphics rendering task is allocated and the execution is completed, that is, the first graphics rendering task A is instructed to complete the execution. It will be appreciated that for a2, A3, a4, a5, a6, a7 completion may be performed in a manner referred to the first graphics rendering task a.
In this embodiment, by re-allocating the sub-rendering tasks of each level in the m graphics processing units, processing schedules between the m graphics processing units can be considered, so as to ensure balanced load distribution on each graphics processing unit, that is, when a scheduling policy of a non-first-level sub-rendering task is determined, current loads on the m graphics processing units can be analyzed, and then a next-level sub-rendering task corresponding to the completed current-level sub-rendering task is allocated to one of the m graphics processing units with the smallest load.
For example, continuing with the second level sub-rendering task a2, if gpu d is executing the fourth level sub-rendering task B4 of the second graphics rendering task, the second level sub-rendering task a2 may be added to the task processing queue of gpu d, and the second level sub-rendering task a2 may be executed after the fourth level sub-rendering task B4 is completed. Therefore, the load on each graphic processing unit can be balanced, the balance of memory occupation is guaranteed, the effect of saving the energy consumption of terminal equipment is achieved, the defect that the efficiency of partial graphic processing units is low when the partial rendering tasks are executed is overcome, the graphic processing efficiency is integrally improved, each level of partial rendering tasks are dynamically scheduled, the processing progress of the partial graphics corresponding to each interface area is synchronized, and the synchronous display of the partial graphics of a plurality of interface areas is facilitated.
Following the above, there are two cases, namely n is less than or equal to m, and n is greater than m, when n is less than or equal to m, for each of the n graphics rendering tasks, each level of sub-rendering tasks in each graphics rendering task is allocated to one of the m graphics processing units to be executed step by step.
For the case that n > m, each level of sub-rendering tasks in each graphics rendering task may be scheduled according to the above-mentioned rendering order, for example, after the second target processing unit executes the last level of sub-rendering tasks in any one of the m graphics rendering tasks, the first sub-rendering task of the non-executed graphics rendering task that is not executed in the previous order from the non-executed remaining graphics rendering tasks may be allocated to the second target processing unit for execution, and so on until the last sub-rendering task of the last graphics rendering task is executed.
Of course, after the second target processing unit executes the first level sub-rendering task of any one of the first m graphics rendering tasks, the first sub-rendering task of the graphics rendering task that is not executed before is allocated to the second target processing unit for execution.
Because there are various optional manners, which are not listed here, the execution progress of each level of sub-rendering tasks of each graphics rendering task can be greatly advanced through the dynamic scheduling manner provided by the embodiment of the present application, so as to improve the graphics processing efficiency.
In some embodiments, when the graphics processing unit executes each level of sub-rendering tasks, the graphics processing unit may also execute through multiple asynchronous threads, thereby improving the processing efficiency of each level of sub-rendering tasks.
In some embodiments, for each set of pixel points, displaying a partial graphic of the graphic to be processed in the corresponding interface region according to the set of pixel points, comprising:
determining whether a displayed partial graphic adjacent to the target partial graphic exists before the target partial graphic is displayed according to the target pixel point set;
if not, displaying a target local graph in the corresponding interface area according to the target pixel point set;
and if so, according to the sharing boundary pixel points of the displayed local graph adjacent to the target local graph, fitting the target pixel point set and then displaying a new target local graph in the corresponding interface area.
The target local graph refers to a corresponding target pixel point set obtained through graph processing, but the local graph is not displayed according to the target pixel point set.
For example, referring to fig. 5, fig. 5 is a schematic view of a display interface of the graphics processing method according to the embodiment of the present application, for example, 16 interface regions are respectively represented by numerals 1 to 16, and if a target partial graphic to be displayed is a graphic in an interface region represented by numeral 8, the interface region in which the partial graphic has been displayed is a graphic in an interface region represented by numerals 1, 5, 13, 14, 15, and 16. And neither 7 nor 12 adjacent to the display interface indicated by the numeral 8 displays the partial graphs, and at this time, the displayed partial graphs are not adjacent to the target partial graph, and the target partial graph can be directly displayed in the display interface indicated by the numeral 8, wherein the target partial graphs can be one or more, and the displayed partial graphs can also be one or more.
If the target partial graphic is a graphic in the interface region indicated by the numeral 5, the interface regions of the displayed partial graphic are, for example, the graphics in the interface regions indicated by the numerals 1, 8, 13, 14, 15, 16. The interface area represented by the numeral 5 is adjacent to the interface area represented by the numeral 1, and the interface area represented by the numeral 1 displays a local graph, which indicates that a local graph adjacent to the target local graph exists in the displayed local graph, so that the target pixel point set can be subjected to fitting processing by taking the shared boundary pixel point of the displayed local graph in the interface area represented by the numeral 1 as a reference, a new target pixel point set is obtained, and a new target local graph is displayed in a fifth area according to the new target pixel point set.
According to the method, the influence of the interface partition on the local graph rendering can be avoided, namely the situation that the pixel point difference of the boundary of the adjacent local graphs is large is avoided, the boundary of the local graphs can be optimized through fitting processing, and the graph display effect is improved.
In some embodiments, according to a shared boundary pixel point of a displayed partial graph adjacent to a target partial graph, after fitting a target pixel point set, displaying a new target partial graph in a corresponding interface region, including:
determining sharing boundary pixel points of the displayed local graph adjacent to the target local graph;
determining target pixel points adjacent to the sharing boundary pixel points from the target pixel point set;
replacing target pixel points in the target pixel point set according to the average value of the shared boundary pixel points and the target pixel points to obtain a new target pixel point set;
and displaying a new target local graph of the graph to be processed in the corresponding interface area according to the new target pixel point set.
Continuing with the above example, the above neighboring manner may be defined as vertical neighboring, where the shared boundary pixel refers to a pixel on the lower edge contour of the displayed local graphic in the interface region represented by the number 1, and the contour thickness may indicate the number of layers occupied by the shared boundary pixel from bottom to top (the direction opposite to the neighboring boundary), where the number of layers may be multiple or may be set by a user, and selecting more layers may improve the processing effect on the target pixel point set and improve the quality of a new target local graphic.
Illustratively, all the pixels in the target pixel set may be optimized longitudinally according to the shared boundary pixel point, that is, for each column of shared boundary pixels, the target pixels in the same column may be optimized. If the adjacent directions are adjacent in the transverse direction, namely, for each line of shared boundary pixel points, the target pixel points in the same line are optimized. By optimizing the whole target pixel point set, the whole graphic display effect can be improved.
Certainly, the target pixel points adjacent to the sharing boundary pixel points can be determined from the target pixel point set, and the number of turns occupied by the target pixel points is not limited here. And then, optimizing the target pixel point by sharing the boundary pixel point to update the original target pixel point, wherein the updated target pixel point and the rest pixels in the target pixel point set form a new target pixel point set. This approach can compromise both boundary optimization efficiency and graphical display effects.
Illustratively, when optimizing the target pixel point or the target pixel point set, the optimization process may be performed by averaging.
For example, when the target pixel is optimized in a manner of averaging, an average value may be obtained for every two adjacent target pixels in the optimization direction, so as to assign the average value to one target pixel far from the shared boundary pixel among the two adjacent target pixels. If there is one sharing boundary pixel point in the longitudinal optimization direction and there are two target pixel points, the average value between the sharing boundary pixel point and the target pixel point close to the sharing boundary pixel point can be obtained first, and then the average value is assigned to the target pixel point participating in the average value calculation. And then, calculating an average value by the updated target pixel point and another target pixel point, and assigning the average value to another target pixel point.
As can be seen from the above, the graphics processing method provided in the embodiment of the present invention, on one hand, can asynchronously process multiple graphics rendering tasks through multiple graphics processing units in the geometry processing stage, thereby avoiding the time consumed for waiting for the completion of the execution of all the geometry stages of the graphics in the related art, and improving the overall processing efficiency of the graphics to be processed. On the other hand, the sub rendering tasks of each graph rendering task are dynamically scheduled in the multiple graph processing units, so that the asynchronous processing progress of each graph rendering task is reduced, local graphs can be synchronously displayed, the graph display effect is improved, the loads on the multiple graph processing units can be balanced, the power consumption and the storage space occupation amount are saved, and the processing vectors of the sub rendering tasks are improved. Furthermore, the boundary of the local graph is optimized, and the graph quality can be improved.
A processor is also provided in an embodiment. The processor is applied to the terminal device, and the processor may be a Central Processing Unit (CPU) or a Graphics Processing Unit (GPU). The processor is configured to perform the steps of:
dividing a display interface into a plurality of interface areas;
dividing rendering data of a graph to be processed into n data sets according to a plurality of interface areas;
determining a graph rendering task of each data set to obtain n graph rendering tasks, wherein the graph rendering tasks comprise multiple levels of sub rendering tasks, and processing results of the sub rendering tasks of the previous level above each level of sub rendering tasks are used as input;
determining the similarity among n data sets;
if the similarity is greater than a preset threshold value, distributing each level of sub-rendering tasks of each graphics rendering task in the n graphics rendering tasks to one graphics processing unit in the m graphics processing units for execution to obtain a pixel point set corresponding to each graphics processing unit, wherein n and m are positive integers greater than 1;
if the similarity is not greater than the preset threshold, for each graphics rendering task in the n graphics rendering tasks, gradually allocating each level of sub-rendering tasks in each graphics rendering task to one graphics processing unit in the m graphics processing units for execution, and obtaining a pixel point set corresponding to each graphics processing unit;
and for each pixel point set, displaying a local graph of the graph to be processed in the corresponding interface area according to the pixel point set.
In some embodiments, the processor is further configured to:
acquiring information indicated by preset conditions, and determining the number of interface areas according to the information, wherein the preset conditions comprise at least one of the task quantity of the graph to be processed, the current use scene and the system resource occupancy rate;
and dividing the display interface into a plurality of interface areas according to the number.
In some embodiments, the processor is further configured to:
and respectively determining the graph rendering tasks for the n data sets according to the attribute information of the n data sets, wherein the graph rendering tasks corresponding to different attribute information are different.
In some embodiments, the processor is further configured to:
for the current level sub-rendering tasks of the n graphics rendering tasks, distributing a graphics processing unit for the n current level sub-rendering tasks, and calling each graphics processing unit to execute the current level sub-rendering task distributed on the graphics processing unit;
and for the finished sub-rendering task at the current level, redistributing the sub-rendering task at the next level corresponding to the finished sub-rendering task at the current level to one of the m graphic processing units for execution until the last sub-rendering task at the last level of the final graphic rendering task is executed, and obtaining a pixel point set corresponding to each graphic processing unit.
In some embodiments, the processor is further configured to:
determining whether a displayed partial graphic adjacent to the target partial graphic exists before the target partial graphic is displayed according to the target pixel point set;
if not, displaying a target local graph in the corresponding interface area according to the target pixel point set;
and if so, according to the sharing boundary pixel points of the displayed local graph adjacent to the target local graph, fitting the target pixel point set and then displaying a new target local graph in the corresponding interface area.
In some embodiments, the processor is further configured to:
determining sharing boundary pixel points of the displayed local graph adjacent to the target local graph;
determining target pixel points adjacent to the sharing boundary pixel points from the target pixel point set;
replacing target pixel points in the target pixel point set according to the average value of the shared boundary pixel point to the target pixel points to obtain a new target pixel point set;
and displaying a new target local graph of the graph to be processed in the corresponding interface area according to the new target pixel point set.
It should be noted that the processor provided in the embodiment of the present application and the graphics processing method in the foregoing embodiment belong to the same concept, and any method provided in the embodiment of the graphics processing method can be implemented by the processor, and the specific implementation process thereof is described in detail in the embodiment of the graphics processing method, and is not described herein again.
As can be seen from the above, on one hand, the processor provided in the embodiment of the present application can asynchronously process multiple graphics rendering tasks through multiple graphics processing units in a geometry processing stage, thereby avoiding a time duration consumed by waiting for the completion of the execution of all the geometry stages of the graphics in the related art, and improving the overall processing efficiency of the graphics to be processed. On the other hand, the sub rendering tasks of each graph rendering task are dynamically scheduled in the multiple graph processing units, so that the asynchronous processing progress of each graph rendering task is reduced, local graphs can be synchronously displayed, the graph display effect is improved, the loads on the multiple graph processing units can be balanced, the power consumption and the storage space occupation amount are saved, and the processing vectors of the sub rendering tasks are improved. Furthermore, the boundary of the local graph is optimized, and the graph quality can be improved.
The embodiment of the application further provides a terminal device, and the terminal device can be a smart phone, a tablet computer, a palm computer and the like. As shown in fig. 6, fig. 6 is a schematic structural diagram of a terminal device provided in the embodiment of the present application. The terminal device 200 comprises a processor 201 with one or more processing cores, a memory 202 with one or more computer readable storage media, and a computer program stored on the memory 202 and executable on the processor. The processor 201 is electrically connected to the memory 202. Those skilled in the art will appreciate that the terminal device configurations shown in the figures are not intended to be limiting of terminal devices and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components.
The processor 201 is a control center of the terminal apparatus 200, connects various parts of the entire terminal apparatus 200 with various interfaces and lines, and performs various functions of the terminal apparatus 200 and processes data by running or loading software programs and/or modules stored in the memory 202 and calling data stored in the memory 202, thereby performing overall monitoring of the terminal apparatus 200.
In the embodiment of the present application, the processor 201 in the terminal device 200 loads instructions corresponding to processes of one or more application programs into the memory 202, and the processor 201 runs the application programs stored in the memory 202, so as to implement various functions as follows:
dividing a display interface into a plurality of interface areas;
dividing rendering data of a graph to be processed into n data sets according to a plurality of interface areas;
determining a graph rendering task of each data set to obtain n graph rendering tasks, wherein the graph rendering tasks comprise multiple levels of sub rendering tasks, and processing results of the sub rendering tasks of the previous level above each level of sub rendering tasks are used as input;
determining the similarity among n data sets;
if the similarity is greater than a preset threshold value, distributing each level of sub-rendering tasks of each graphics rendering task in the n graphics rendering tasks to one graphics processing unit in the m graphics processing units for execution to obtain a pixel point set corresponding to each graphics processing unit, wherein n and m are positive integers greater than 1;
if the similarity is not greater than the preset threshold, for each graphics rendering task in the n graphics rendering tasks, gradually allocating each level of sub-rendering tasks in each graphics rendering task to one graphics processing unit in the m graphics processing units for execution, and obtaining a pixel point set corresponding to each graphics processing unit;
and for each pixel point set, displaying a local graph of the graph to be processed in the corresponding interface area according to the pixel point set.
The above operations can be implemented in the foregoing embodiments, and are not described in detail herein.
In the foregoing embodiments, the descriptions of the respective embodiments have respective emphasis, and for parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.
As can be seen from the above, on one hand, the terminal device provided in this embodiment can asynchronously process multiple graphics rendering tasks through multiple graphics processing units in the geometry processing stage, thereby avoiding the time consumed for waiting for the completion of the execution of the geometry stages of all the graphics in the related art, and improving the overall processing efficiency of the graphics to be processed. On the other hand, the sub rendering tasks of each graph rendering task are dynamically scheduled in the multiple graph processing units, so that the asynchronous processing progress of each graph rendering task is reduced, local graphs can be synchronously displayed, the graph display effect is improved, the loads on the multiple graph processing units can be balanced, the power consumption and the storage space occupation amount are saved, and the processing vectors of the sub rendering tasks are improved. Furthermore, the boundary of the local graph is optimized, and the graph quality can be improved.
It will be understood by those skilled in the art that all or part of the steps of the methods of the above embodiments may be performed by instructions or by associated hardware controlled by the instructions, which may be stored in a computer readable storage medium and loaded and executed by a processor.
To this end, an embodiment of the present application provides a computer-readable storage medium, in which multiple computer programs are stored, where the computer programs can be loaded by a processor to execute steps in a graphics processing method provided in an embodiment of the present application. For example, the computer program may perform the steps of:
dividing a display interface into a plurality of interface areas;
dividing rendering data of a graph to be processed into n data sets according to a plurality of interface areas;
determining a graph rendering task of each data set to obtain n graph rendering tasks, wherein the graph rendering tasks comprise multiple levels of sub rendering tasks, and processing results of the sub rendering tasks of the previous level above each level of sub rendering tasks are used as input;
determining the similarity among n data sets;
if the similarity is greater than a preset threshold value, distributing each level of sub-rendering tasks of each graphics rendering task of the n graphics rendering tasks to one graphics processing unit of the m graphics processing units to be executed, and obtaining a pixel point set corresponding to each graphics processing unit, wherein n and m are positive integers greater than 1;
if the similarity is not greater than the preset threshold, for each graphics rendering task in the n graphics rendering tasks, gradually allocating each level of sub-rendering tasks in each graphics rendering task to one graphics processing unit in the m graphics processing units for execution, and obtaining a pixel point set corresponding to each graphics processing unit;
and for each pixel point set, displaying a local graph of the graph to be processed in the corresponding interface area according to the pixel point set.
The above operations can be implemented in the foregoing embodiments, and are not described in detail herein.
The storage medium may be ROM/RAM, magnetic disk, optical disk, etc. Since the computer program stored in the storage medium can execute the steps in any graphics processing method provided in the embodiments of the present application, beneficial effects that can be achieved by any graphics processing method provided in the embodiments of the present application can be achieved, which are detailed in the foregoing embodiments and will not be described herein again.
The foregoing detailed description is directed to a method, an apparatus, a medium, and a terminal device for processing a graphic, which are provided in the embodiments of the present application, and specific examples are applied in the present application to explain the principles and embodiments of the present application, and the descriptions of the foregoing embodiments are only used to help understand the method and the core idea of the present application; meanwhile, for those skilled in the art, according to the idea of the present application, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present application.

Claims (9)

1. A method of graphics processing, the method comprising:
dividing a display interface into a plurality of interface areas;
dividing rendering data of a graph to be processed into n data sets according to the interface areas;
determining a graph rendering task of each data set to obtain n graph rendering tasks, wherein the graph rendering tasks comprise multiple levels of sub rendering tasks, and a processing result of the sub rendering task above each level of sub rendering tasks is used as input;
determining the similarity among the n data sets;
if the similarity is greater than a preset threshold value, distributing each level of sub-rendering tasks of each graphics rendering task in the n graphics rendering tasks to one graphics processing unit in the m graphics processing units for execution to obtain a pixel point set corresponding to each graphics rendering task, wherein n and m are positive integers greater than 1;
if the similarity is not greater than the preset threshold, for each graphics rendering task in the n graphics rendering tasks, gradually allocating each level of sub-rendering tasks in each graphics rendering task to one graphics processing unit in the m graphics processing units for execution, and obtaining a pixel point set corresponding to each graphics rendering task;
and for each pixel point set, displaying a local graph of the graph to be processed in a corresponding interface area according to the pixel point set.
2. The method of claim 1, wherein the dividing the display interface into a plurality of interface regions comprises:
acquiring information indicated by preset conditions, and determining the number of interface areas according to the information, wherein the preset conditions comprise at least one of the task quantity of the graph to be processed, the current use scene and the system resource occupancy rate;
and dividing the display interface into a plurality of interface areas according to the number.
3. The method of claim 1, wherein determining the graphics rendering task for each of the data sets results in n graphics rendering tasks, comprising:
and respectively determining graphics rendering tasks for the n data sets according to the attribute information of the n data sets, wherein the graphics rendering tasks corresponding to different attribute information are different.
4. The method of claim 1, wherein for each of the n graphics rendering tasks, assigning each level of sub-rendering tasks of the each graphics rendering task to one of the m graphics processing units for execution, and obtaining a set of pixel points corresponding to the each graphics rendering task, comprises:
for the current level sub-rendering tasks of the n graphics rendering tasks, distributing a graphics processing unit for the n current level sub-rendering tasks, and calling each graphics processing unit to execute the current level sub-rendering task distributed on the graphics processing unit;
and for the finished sub-rendering tasks at the current level, redistributing the sub-rendering tasks at the next level corresponding to the finished sub-rendering tasks at the current level to one of the m graphic processing units for execution until the last sub-rendering task at the last level of the final graphic rendering task is executed, and obtaining a pixel point set corresponding to each graphic rendering task.
5. The method of claim 1, wherein for each set of pixel points, displaying a partial graphic of the graphic to be processed in a corresponding interface region according to the set of pixel points comprises:
determining whether a displayed partial graphic adjacent to a target partial graphic exists before the target partial graphic is displayed according to a target pixel point set;
if not, displaying the target local graph in a corresponding interface area according to the target pixel point set;
and if so, according to the sharing boundary pixel points of the displayed local graph adjacent to the target local graph, fitting the target pixel point set and then displaying a new target local graph in a corresponding interface area.
6. The method of claim 5, wherein the displaying a new target local graph in a corresponding interface region after fitting the target pixel point set according to shared boundary pixel points of displayed local graphs adjacent to the target local graph comprises:
determining sharing boundary pixel points of the displayed local graph adjacent to the target local graph;
determining target pixel points adjacent to the sharing boundary pixel points from the target pixel point set;
replacing target pixel points in the target pixel point set according to the average value of the shared boundary pixel point to the target pixel points to obtain a new target pixel point set;
and displaying a new target local graph of the graph to be processed in a corresponding interface area according to the new target pixel point set.
7. A processor, characterized in that the processor is configured to perform the graphics processing method of any of claims 1 to 6.
8. A computer-readable storage medium, on which a computer program is stored, which, when run on a computer, causes the computer to carry out a graphics-processing method according to any one of claims 1 to 6.
9. A terminal device comprising a processor and a memory, said memory storing a computer program, characterized in that said processor is adapted to execute a graphics processing method according to any of claims 1 to 6 by invoking said computer program.
CN202210969665.8A 2022-08-12 2022-08-12 Graphic processing method, processor, storage medium and terminal device Active CN115049774B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210969665.8A CN115049774B (en) 2022-08-12 2022-08-12 Graphic processing method, processor, storage medium and terminal device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210969665.8A CN115049774B (en) 2022-08-12 2022-08-12 Graphic processing method, processor, storage medium and terminal device

Publications (2)

Publication Number Publication Date
CN115049774A true CN115049774A (en) 2022-09-13
CN115049774B CN115049774B (en) 2022-11-01

Family

ID=83168199

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210969665.8A Active CN115049774B (en) 2022-08-12 2022-08-12 Graphic processing method, processor, storage medium and terminal device

Country Status (1)

Country Link
CN (1) CN115049774B (en)

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140368521A1 (en) * 2013-05-02 2014-12-18 Arm Limited Graphics processing systems
GB201502705D0 (en) * 2015-02-18 2015-04-01 Advanced Risc Mach Ltd Graphics processing systems
CN105809728A (en) * 2015-01-19 2016-07-27 想象技术有限公司 Rendering views of scene in a graphics processing unit
GB201714519D0 (en) * 2016-03-07 2017-10-25 Imagination Tech Ltd Task assembly
CN107451916A (en) * 2017-07-21 2017-12-08 武汉楚鼎信息技术有限公司 The querying method of high-performance K lines based on graphics processor, form are selected stocks system
US20200005423A1 (en) * 2018-06-29 2020-01-02 Imagination Technologies Limited Tile Assignment to Processing Cores Within a Graphics Processing Unit
US20210158585A1 (en) * 2019-11-27 2021-05-27 Arm Limited Graphics processing systems
CN113269856A (en) * 2021-05-12 2021-08-17 南京邮电大学 Data parallel visualization graph rendering method and system based on distributed cloud storage
CN114155334A (en) * 2021-11-30 2022-03-08 北京字跳网络技术有限公司 Scene rendering method and device, computer equipment and storage medium

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140368521A1 (en) * 2013-05-02 2014-12-18 Arm Limited Graphics processing systems
CN105809728A (en) * 2015-01-19 2016-07-27 想象技术有限公司 Rendering views of scene in a graphics processing unit
GB201502705D0 (en) * 2015-02-18 2015-04-01 Advanced Risc Mach Ltd Graphics processing systems
GB201714519D0 (en) * 2016-03-07 2017-10-25 Imagination Tech Ltd Task assembly
CN107451916A (en) * 2017-07-21 2017-12-08 武汉楚鼎信息技术有限公司 The querying method of high-performance K lines based on graphics processor, form are selected stocks system
US20200005423A1 (en) * 2018-06-29 2020-01-02 Imagination Technologies Limited Tile Assignment to Processing Cores Within a Graphics Processing Unit
US20210158585A1 (en) * 2019-11-27 2021-05-27 Arm Limited Graphics processing systems
CN113269856A (en) * 2021-05-12 2021-08-17 南京邮电大学 Data parallel visualization graph rendering method and system based on distributed cloud storage
CN114155334A (en) * 2021-11-30 2022-03-08 北京字跳网络技术有限公司 Scene rendering method and device, computer equipment and storage medium

Also Published As

Publication number Publication date
CN115049774B (en) 2022-11-01

Similar Documents

Publication Publication Date Title
US11748840B2 (en) Method for efficient re-rendering objects to vary viewports and under varying rendering and rasterization parameters
US10210651B2 (en) Allocation of tiles to processing engines in a graphics processing system
US10229529B2 (en) System, method and computer program product for implementing anti-aliasing operations using a programmable sample pattern table
US10249016B2 (en) Graphics processing units and methods using cost indications for sets of tiles of a rendering space
CN101371247B (en) Parallel array architecture for a graphics processor
CN108305313B (en) Graphics processing unit and method for rendering for subdividing a set of one or more tiles of a rendering space
EP3588289B1 (en) Tile assignment to processing cores within a graphics processing unit
US10553024B2 (en) Tile-based rendering method and apparatus
EP2985735B1 (en) Method and apparatus for performing tile-based path rendering
WO2014035682A1 (en) Surface tessselation by symmetric edge splitting
US9721187B2 (en) System, method, and computer program product for a stereoscopic image lasso
CN115049774B (en) Graphic processing method, processor, storage medium and terminal device
CN114661473A (en) Task processing method and device, storage medium and electronic equipment
Kunii et al. Parallel polygon rendering on the graphics computer VC-1
KR20160131457A (en) Method and apparatus for performing curve rendering

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant