Image data processing method, device, computer equipment, readable storage medium and program product
By determining the processing logic based on the output mode and optimizing the processing of image segmentation parameters and control point information, the inefficiency problem caused by a single execution mode in surface segmentation is solved, and more efficient image data processing is achieved.
Patent Information
- Application Number
- CN202411717368.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-26
- Publication Date
- 2025-04-04
AI Technical Summary
The single execution mode during surface subdivision in the prior art results in unnecessary data input and output and repeated data storage space allocation, reducing the efficiency of data processing.
By obtaining the shell shader output mode transmitted by the vertex shader, the target processing logic is determined according to the output mode, and the image segmentation parameters and image control point information are processed according to the target processing logic, thereby optimizing the data processing flow.
It effectively reduces the problem of low data processing efficiency caused by a single processing logic, improves the efficiency of image processing, and reduces the consumption of storage space under appropriate circumstances.
Smart Images

Figure CN119762643A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of image processing technology, and in particular to an image data processing method, apparatus, computer equipment, computer-readable storage medium, and computer program product. Background Art
[0002] In three-dimensional scene drawing, surface subdivision is an effective method to express the surface details of an object. This method automatically generates a large number of new vertices on the surface of the object, which will make the model surface either smooth and delicate (such as the face) or rugged (such as the terrain and the sea surface). It has been widely used on mainstream drawing platforms such as D3D, OpenGL, and Vulkan.
[0003] In the related art, there is only one execution mode for surface subdivision. Regardless of whether the control points output by the shell shader come from the output points of the vertex shader, the shell shader must execute the loading instructions of the input data and the output instructions of the control point data; and regardless of whether the image subdivision parameters output by the shell shader are constants, the shell shader must execute the output instructions of the image subdivision parameters.
[0004] Then, this single execution mode in the related art will increase unnecessary shell shader data input and output and loading instructions, and it is necessary to repeatedly allocate data storage space for the same data, which wastes data storage space, reduces the parallelism of data processing, and has low data processing efficiency. Summary of the invention
[0005] Based on this, it is necessary to provide an image data processing method, device, computer equipment, computer-readable storage medium and computer program product that can improve data processing efficiency in response to the above technical problems.
[0006] In a first aspect, the present application provides an image data processing method, comprising:
[0007] Get the output mode corresponding to the shell shader transmitted by the vertex shader; the output mode is used to indicate the type of image subdivision parameters and the output method of the shell shader for image control point information;
[0008] According to the output mode, obtain the target processing logic;
[0009] The image subdivision parameters and image control point information are processed according to the target processing logic to obtain the processing result.
[0010] In one embodiment, image subdivision parameters and image control point information are processed according to target processing logic to obtain processing results, including: when the image control point information is vertex information output by a vertex shader, the vertex information output by the vertex shader is output to a surface subdivision unit through a shell shader; when the type of the image subdivision parameter is a constant, the image subdivision parameter is read from an image subdivision parameter register through the surface subdivision unit.
[0011] In one embodiment, the output mode includes at least one of a first output mode, a second output mode and a third output mode; wherein the first output mode indicates that the image control point information is vertex information output by the vertex shader, and the type of the image subdivision parameter is a constant; the second output mode indicates that the image control point information is vertex information output by the vertex shader, and the type of the image subdivision parameter is a non-constant; the third output mode indicates that the image control point information is not vertex information output by the vertex shader, and the type of the image subdivision parameter is a constant.
[0012] In an optional embodiment, the output mode is the first output mode; the image subdivision parameters and the image control point information are processed according to the target processing logic to obtain a processing result, including: generating a first patch block according to the image control point information through a shell shader, and sending the image control point information constituting the first patch block to a surface subdivision unit, wherein the image control point information constituting the first patch block is the vertex information output by the vertex shader; obtaining the image subdivision parameters from the image subdivision parameter register through the surface subdivision unit, generating first domain vertices according to the image control point information constituting the first patch block and the image subdivision parameters, and sending the first domain vertices and the image control point information constituting the first patch block to a region shader; obtaining the first region cache information through the region shader, generating the first region thread bundle according to the image control point information constituting the first patch block, the first domain vertex and the first region cache information, wherein the first region cache information is used to store the first domain vertex.
[0013] In an exemplary embodiment, the output mode is the second output mode; the image subdivision parameters and the image control point information are processed according to the target processing logic to obtain the processing result, including: obtaining the subdivision parameter configuration information transmitted by the vertex shader through the shell shader, generating the image subdivision parameters according to the subdivision parameter configuration information, obtaining the first shell buffer area for storing the image subdivision parameters, generating the first patch block according to the image control point information, and sending the image control point information of the first patch block to the surface subdivision unit, wherein the image control point information constituting the first patch block is the vertex information output by the vertex shader; obtaining the image subdivision parameters from the first shell buffer area through the surface subdivision unit, generating the second domain vertices according to the image control point information and the image subdivision parameters of the first patch block, and sending the second domain vertices and the image control point information constituting the first patch block to the region shader; obtaining the second region cache information through the region shader, generating the second region thread warp according to the image control point information constituting the first patch block, the second domain vertex information and the second region cache information, wherein the second region cache information is used to store the second domain vertex information.
[0014] In one embodiment, the output mode is the third output mode, and the image subdivision parameters and the first image control point information are processed according to the target processing logic to obtain the processing results including: obtaining vertex information output by the vertex shader through the shell shader, generating image control point information according to the vertex information, generating a second patch block according to the image control point information, and sending the image control point information constituting the second patch block to the surface subdivision unit; obtaining the image subdivision parameters from the image subdivision parameter register through the surface subdivision unit, generating third domain vertex information according to the image control point information constituting the second patch block and the image subdivision parameters, and sending the third domain vertex information and the image control point information constituting the second patch block to the region shader; obtaining the third region cache information through the region shader, generating a third region thread warp according to the image control point information constituting the second patch block, the third domain vertex information and the third region cache information, wherein the third region cache information is used to store the third domain vertex information.
[0015] In a second aspect, the present application further provides an image data processing device, comprising:
[0016] An output mode acquisition module is used to acquire the output mode corresponding to the shell shader transmitted by the vertex shader; the output mode is used to indicate the type of image subdivision parameters and the output method of the shell shader for image control point information;
[0017] A processing logic acquisition module is used to acquire the target processing logic according to the output mode;
[0018] The processing module is used to process the image subdivision parameters and image control point information according to the target processing logic to obtain the processing result.
[0019] In a third aspect, the present application further provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps of the above-mentioned method embodiments when executing the computer program.
[0020] In a fourth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, which implements the steps of the above-mentioned method embodiments when the computer program is executed by a processor.
[0021] In a fifth aspect, the present application also provides a computer program product, including a computer program, which implements the steps of the above-mentioned method embodiments when executed by a processor.
[0022] The above-mentioned image data processing method, device, computer equipment, computer-readable storage medium and computer program product obtain an output mode indicating the image subdivision type and image control point information, determine the target processing logic according to the output mode, and process the image subdivision parameters and image control point information according to the target processing logic, thereby having different processing logics according to the different output methods of the subdivision parameter type and the image control point information, effectively reducing the problem of low data processing efficiency caused by a single processing logic, and effectively improving the image processing efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0023] In order to more clearly illustrate the technical solutions in the embodiments of the present application or related technologies, the drawings required for use in the embodiments of the present application or related technical descriptions will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.
[0024] Figure 1 is a structural block diagram of a surface subdivision module in one embodiment;
[0025] Figure 2 is a schematic flow chart of an image data processing method in one embodiment;
[0026] Figure 3 is a flowchart of an image data processing method in another embodiment;
[0027] Figure 4 is a structural block diagram of an image data processing device in one embodiment;
[0028] Figure 5 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0029] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0030] In related technologies, before the tessellation module is introduced into the graphics pipeline, the geometry shader GS (Geometry Shader) is generally used to generate geometric detail information. GS is an important shader of D3D10.0, which can generate new vertices by writing a shading program, but it is a general module, and the generated algorithm is too complex, the execution time is long, and it is not conducive to real-time rendering.
[0031] To improve the realism of the drawing and the smoothness of the picture, Figure 1 As shown in the figure, in addition to the traditional vertex shader (VS) and pixel shader (PS), the important function of surface subdivision has been added, with two new shaders, the hull shader (HS), the domain shader (DS) and a tessellation unit (TS). This subdivision module uses HS and DS to complete the pre-processing and post-processing calculations of TS, and the real-time drawing effect is also good.
[0032] Optionally, the shell shader HS is a pre-processing calculation of the TS, generating multiple image control point information (CPs, Control Points) and image subdivision parameters (PCs, Patch Consts) for the TS.
[0033] Exemplarily, HS obtains vertex information from VS, generates image control points (CPs) based on the vertex information, generates image subdivision parameters (PCs) based on the set image subdivision parameter configuration information, and sends the image control point information and image subdivision parameters to TS, which generates domain vertex information based on the image control point information and image subdivision parameters, and then sends the domain vertex information and the image control point information obtained from HS to DS, which performs the next step of data processing.
[0034] In one embodiment, VS includes a VSC (vertex shader control unit), HS includes an HSC (hull shader control unit), and DS includes a DSC (regional shader control unit), and VSC, HSC, and DSC perform corresponding functions. Exemplarily, VSC implements the output of vertex information, forms vertex thread bundles, and other steps. Exemplarily, HSC implements the steps of obtaining vertex information from VS, processing the vertex information to obtain image control point information, sending the image control point information to TESS, obtaining image subdivision parameters, and sending them to TESS, forming shell thread bundles, and other steps. Exemplarily, DSC implements the operations of applying for a regional cache area with the domain vertex information obtained from TESS, forming a regional thread bundle, and so on.
[0035] Optionally, a data buffer is also included for storing data output by VS, HS, and DS, for example, storing vertex information output by VS.
[0036] In actual application scenarios, HS may simply output the vertex information of VS (vertex shader) as control points (CPs) directly without any modification. Similarly, subdivision parameters (PCs) may also be a fixed constant, and HS does not need to calculate to obtain image subdivision parameters.
[0037] In the related art, when processing the surface subdivision module, there is only a single execution mode, that is, regardless of whether the HS directly outputs the vertex information output by the VS as CPs, and regardless of whether the PCs are constants, it is necessary to process based on the vertex information of the VS, perform calculations based on the image parameter configuration information, and generate storage intervals for the calculation results. Therefore, this single execution mode in the related art increases the input and output instructions corresponding to the HS, and also increases unnecessary storage space, resulting in low output processing efficiency.
[0038] To solve the above problems, Figure 2 As shown, an image data processing method is provided. This embodiment takes the method applied to a server as an example for illustration. It can be understood that the method can also be applied to a terminal, and can also be applied to a system including a terminal and a server, and is implemented through the interaction between the terminal and the server. In this embodiment, the method includes the following steps:
[0039] Step S202, obtaining the output mode corresponding to the hull shader transmitted by the vertex shader.
[0040] In one embodiment, the terminal and / or the server may be configured with a GPU (graphics processing unit), and the GPU is used to process the image data.
[0041] Optionally, a tessellation switch module may be provided to turn on or off tessellation.
[0042] In one embodiment, the GPU may receive input image data to be processed through a vertex shader, and perform a first step of processing on the image data to be processed through the vertex shader to obtain vertex information. Optionally, the vertex information includes but is not limited to position information, brightness information, etc.
[0043] In one embodiment, after generating vertex information, the vertex shader may generate a vertex warp and send the vertex warp to a warp processing unit, which performs processing according to the warp, for example, executing an instruction to input the vertex information into a vertex buffer.
[0044] In one embodiment, the vertex shader may also transmit an output mode corresponding to the shell shader and / or a control command corresponding to the shell shader.
[0045] Optionally, the output mode can be pre-configured, and the vertex shader transmits the output mode to the hull shader. Exemplarily, the output mode is configured by a software driver, and the vertex shader transmits the output mode configured by the software driver to the hull shader.
[0046] Optionally, the control instruction corresponding to the shell shader may include but is not limited to clearing the work task of the shell shader, etc.
[0047] In an optional embodiment, the vertex shader may obtain a vertex buffer for storing vertex information, and may generate a vertex warp from the vertex buffer and the vertex information. Optionally, after receiving the vertex warp information, the warp processing unit may perform corresponding processing based on the vertex warp, for example, inputting the vertex information into the vertex buffer, or obtaining the vertex information from the vertex buffer and further inputting it into the shell shader.
[0048] In one embodiment, when the vertex shader outputs information, it may also output the patch block size, so that the hull shader can compose the vertex information into patch blocks of a required size according to the received patch block size.
[0049] The output mode is used to indicate the type of image subdivision parameters and the output method of the shell shader for the first image control point information.
[0050] The image subdivision parameters are used to determine domain vertex information generated by the surface subdivision unit. Optionally, the domain vertex information includes but is not limited to the number of domain vertices and position information corresponding to the domain vertices.
[0051] In one embodiment, the image subdivision parameter may be a constant or may not be a constant.
[0052] Optionally, when the image subdivision parameter is a constant, the shell shader does not process the image subdivision parameter, and the surface subdivision unit directly obtains the image subdivision parameter from the image subdivision parameter register and generates domain vertex information based on the image subdivision parameter. Optionally, the image subdivision parameter configuration information can be pre-configured by software.
[0053] Optionally, when the image subdivision parameter is not a constant, the shell shader needs to perform processing to obtain the image subdivision parameter. Exemplarily, the shell shader obtains the image subdivision parameter configuration information transmitted by the vertex shader, and calculates based on the image subdivision configuration information to obtain the image subdivision parameter. Optionally, the image subdivision parameter configuration information can be pre-configured by software.
[0054] In one embodiment, the output mode of the image control point information of the hull shader can be determined according to the configuration information transmitted by the vertex shader. For example, if the configuration information transmitted by the vertex shader indicates that the image control point information is the vertex information output by the vertex shader, the hull shader directly sends the vertex information output by the vertex shader obtained as the image control point information to the tessellation unit. Alternatively, if the configuration information output by the vertex shader indicates that the image control point information is not the vertex information output by the vertex shader, the hull shader calculates the image control point information according to the vertex information output by the vertex shader, and sends the image control point information to the tessellation unit.
[0055] It can be understood that the execution method of the shell shader is different for different image subdivision parameters and / or different image control point information. Different output modes can be formed according to the differences in image subdivision parameters and image control point information, so as to obtain corresponding target processing logic according to different output modes, and the GPU can implement processing according to the target processing logic.
[0056] Optionally, the output mode includes at least one of a first output mode, a second output mode and a third output mode.
[0057] The first output mode indicates that the image control point information is vertex information output by the vertex shader, and the type of the image subdivision parameter is a constant.
[0058] The second output mode indicates that the image control point information is vertex information output by the vertex shader, and the type of the image subdivision parameter is a non-constant.
[0059] The third output mode indicates that the image control point information is not vertex information output by the vertex shader, and the type of the image subdivision parameter is a constant.
[0060] In an optional embodiment, the output mode may further include a fourth output mode, wherein the fourth output mode indicates that the image control point information is not vertex information output by the vertex shader, and the type of the image subdivision parameter is not a constant.
[0061] Step S204, obtaining the target processing logic according to the output mode.
[0062] The processing logic is used to indicate the processing steps of each component, for example, indicating the processing steps of the shell shader, the processing steps of the surface subdivision unit, the processing steps of the region shader, etc.
[0063] In one embodiment, different output modes have different processing logics.
[0064] Exemplarily, the first output mode corresponds to the first processing logic, the second output mode corresponds to the second processing logic, the third output mode corresponds to the third processing logic, and the fourth output mode corresponds to the fourth processing logic.
[0065] Optionally, the first processing logic, the second processing logic, the third processing logic and the fourth processing logic are different from each other.
[0066] In one embodiment, after obtaining the output mode transmitted by the vertex shader, it is determined whether the output mode is the first output mode, the second output mode, the third output mode or the fourth output mode, and a matching process is performed based on the result of determining the output mode to obtain the processing logic corresponding to the output mode. Exemplarily, when the output mode is the first output mode, the corresponding processing logic is the first processing logic, and the first processing logic is the target processing logic.
[0067] In an optional embodiment, when the output mode is the first output mode, the first processing logic may be that the shell shader obtains vertex information output by the vertex shader, the vertex information is used as image control point information, a first patch block is generated according to the image control point information, and the image control point information constituting the first patch block is sent to the tessellation unit. The tessellation unit obtains the image tessellation parameter from the image tessellation parameter register, and processes according to the image tessellation parameter and the image control point information constituting the first patch block to obtain first domain vertex information, and sends the first domain vertex information and the image control point information constituting the first patch block to the region shader. The region shader obtains first region cache information for storing the first domain vertex information, and generates a first region thread bundle with the first region cache information, the first domain vertex information and the image control point information constituting the first patch block. Optionally, after generating the first region thread bundle, the region shader may send the generated first region thread bundle to the thread bundle execution module, and the thread bundle execution module executes based on the first region thread bundle.
[0068] Optionally, when the output mode is the second output mode, the second processing logic may obtain the subdivision parameter configuration information transmitted by the vertex shader for the shell shader, generate the image subdivision parameters according to the subdivision parameter configuration information, obtain the first shell buffer information for storing the image subdivision parameters, generate the first patch block according to the image control point information, and send the image control point information constituting the first patch block to the tessellation unit, wherein the image control point information is the vertex information output by the vertex shader. The tessellation unit reads the image subdivision parameters from the first shell buffer, generates the second domain vertex information according to the image subdivision parameters and the image control point information constituting the first patch block, and sends the second domain vertex information and the image control point information constituting the first patch block to the region shader. The region shader obtains the second region buffer information for storing the second domain vertex information, and generates the second region warp by combining the second region buffer information, the image control point information constituting the first patch block and the second domain vertex information.
[0069] In one embodiment, the second processing logic may further include: the shell shader generates a first shell warp according to the first shell buffer information and the image control point information, and sends the first shell warp to the warp processing unit. In one embodiment, the second processing logic may further include: the region shader sends the second region warp to the warp processing unit. Optionally, the second processing logic may further include: the warp processing unit receives the first shell warp and the second region warp, and performs processing steps according to the first shell warp and the second region warp.
[0070] Optionally, when the output mode is the third output mode, the third processing logic can obtain vertex information output by the vertex shader for the shell shader, generate image control point information according to the vertex information, generate a second patch block according to the image control point information, and send the image control point information constituting the second patch block to the tessellation unit. The tessellation unit obtains the image tessellation parameter from the image tessellation parameter register, generates third domain vertex information according to the image control point information constituting the second patch block and the image tessellation parameter, and sends the third domain vertex information and the image control point information constituting the second patch block to the region shader. The region shader obtains the third region buffer information for storing the third domain vertex information, and composes the third region buffer information, the image control point information constituting the second patch block, and the third domain vertex into a third region warp.
[0071] In one embodiment, the third processing logic may further include: the shell shader obtains the second shell buffer information for storing the image control point information, sends the second shell buffer information to the surface, generates the second shell thread bundle according to the second shell buffer information and the image control point information, and sends the second shell thread bundle to the thread bundle processing unit. In one embodiment, the second processing logic may further include: the region shader sends the third region thread bundle to the thread bundle processing source. Optionally, the second processing logic may further include: the thread bundle processing unit receives the second shell thread bundle and the third region thread bundle, and performs processing steps according to the second shell thread bundle and the third region thread bundle.
[0072] Optionally, when the output mode is the fourth output mode, the fourth processing logic may be that the shell shader obtains vertex information output by the vertex shader, generates image control point information according to the vertex information output by the vertex shader, generates a third patch block according to the image control point information, obtains subdivision parameter configuration information transmitted by the vertex shader to generate image subdivision parameters, obtains third shell buffer information for storing image control point information and image subdivision parameters constituting the third patch block, and sends the third shell buffer information to the curve subdivision unit. The surface subdivision unit obtains image control point information and image subdivision parameters constituting the third patch block from the third shell buffer information, generates fourth domain vertex information according to the image control point information and image subdivision parameters constituting the third patch block, and sends the image control point information and fourth domain vertex information constituting the third patch block to the region shader. The region shader obtains fourth region buffer information for storing fourth domain vertex information, and generates fourth region thread warps according to the fourth region buffer information, the fourth domain vertex information, and the image control point information constituting the third patch block. Optionally, the regional shader may send the fourth regional warp to the warp execution unit, and the warp execution unit may perform processing steps based on the warp execution. Exemplarily, the warp execution unit may perform the step of inputting vertex information and image subdivision parameters constituting the third patch block into the third shell buffer information based on the third shell warp execution. Exemplarily, the warp execution unit may also perform the step of inputting the fourth domain vertex information into the fourth regional buffer information based on the fourth regional warp execution.
[0073] In one embodiment, the fourth processing logic may further include: the shell shader obtains third shell buffer information for storing image control point information and image subdivision parameters constituting the third patch block, generates a third shell warp according to the image control point information and image subdivision parameters constituting the third patch block, and sends the third shell warp to the warp processing unit. Optionally, the warp processing unit performs a processing step based on the third shell warp, exemplarily performing a step of inputting the image control point information and image subdivision parameters constituting the third patch block into the third shell buffer information.
[0074] Step S206: Process the image subdivision parameters and the image control point information according to the target processing logic to obtain a processing result.
[0075] In one embodiment, when the image control point information is vertex information output by a vertex shader, the vertex information output by the vertex shader can be directly output to the tessellation unit through a hull shader.
[0076] In one of the embodiments, when the type of the image subdivision parameter is a constant, the image subdivision parameter is read from the image subdivision parameter register by the surface subdivision unit.
[0077] Optionally, after the output mode is acquired, the output method of the image control point information and the type of the image subdivision parameter are determined based on the output mode. Exemplarily, if the image control point information is the vertex information of the shell shader, it can be considered that the output method of the image control point information indicated by the output mode is that the shell shader does not perform calculation processing on the vertex information output by the vertex shader, and the vertex information output by the vertex shader can be directly output to the surface subdivision unit as the image control point information. If, on the other hand, the image control point information is not the vertex information of the shell shader, it can be considered that the output method of the image control point information indicated by the output mode is that the shell shader needs to perform calculation processing on the vertex information output by the vertex shader, and can only output it after obtaining the image control point information.
[0078] Exemplarily, if the image subdivision parameter is a fixed constant, it can be considered that the type of the image subdivision parameter indicated by the output mode is a constant type, the shell shader does not calculate the image subdivision parameter, and the surface subdivision unit obtains the image subdivision parameter from the image subdivision parameter register. If the image subdivision parameter is not a fixed constant, it can be considered that the type of the image subdivision parameter indicated by the output mode is not a constant type, the shell shader needs to calculate to obtain the image subdivision parameter, and the surface subdivision unit performs the step of generating domain vertex information based on the image subdivision parameter calculated by the shell shader.
[0079] In one of the embodiments, after obtaining the output mode corresponding to the shell shader transmitted by the vertex shader, the output mode can be matched with a preset output mode. For example, the output mode is matched with the first output mode, the second output mode, the third output mode and / or the fourth output mode to determine whether the output mode corresponding to the shell shader matches the first output mode, the second output mode, the third output mode or the fourth output mode. After matching, the corresponding target processing logic is determined, and the processing steps are executed based on the target processing logic.
[0080] Optionally, when the output mode is the first output mode, a first patch block is generated according to the image control point information by the shell shader, and the image control point information constituting the first patch block is sent to the surface subdivision unit, wherein the image control point information constituting the first patch block is the vertex information output by the vertex shader. The surface subdivision unit obtains the image subdivision parameter from the image subdivision parameter register, generates the first domain vertex information according to the image control point information constituting the first patch block and the image subdivision parameter, and sends the first domain vertex information and the image control point information constituting the first patch block to the region shader, obtains the first region cache information for storing the first domain vertex information by the region shader, and generates the first region thread bundle according to the first image control point information constituting the first patch block, the first domain vertex information and the first region cache information. Optionally, after the first region thread bundle is generated, the region shader can send the generated first region thread bundle to the thread bundle execution module, and the thread bundle execution module executes based on the first region thread bundle, and exemplarily, executes the step of inputting the first domain vertex information into the first region cache information.
[0081] Optionally, when the output mode is the second output mode, the subdivision parameter configuration information transmitted by the vertex shader is obtained through the shell shader, the image subdivision parameters are generated according to the subdivision parameter configuration information, the first shell buffer area information for storing the image subdivision parameters is obtained, the first patch block is generated according to the image control point information, and the image control point information of the first patch block is sent to the surface subdivision unit, wherein the image control point information constituting the first patch block is the vertex information output by the vertex shader. The image subdivision parameters are obtained from the first shell buffer area through the surface subdivision unit, the second domain vertex information is generated according to the image control point information and the image subdivision parameters of the first patch block, and the second domain vertex information and the image control point information constituting the first patch block are sent to the region shader. The second region cache information for storing the second domain vertex information is obtained through the region shader, and the second region thread warp is generated according to the image control point information constituting the first patch block, the second domain vertex and the second region cache information. Optionally, the first shell buffer and vertex information constituting the first face block can be used to generate a first shell warp through the shell shader, and the first shell warp is sent to the warp processing unit, and the warp processing unit performs processing steps based on the first shell warp. Exemplarily, after receiving the first shell warp, the step of storing the image subdivision parameters in the first shell buffer can be performed according to the first shell warp. Optionally, the second regional warp can be sent to the warp processing unit through the regional shader, and the warp processing unit performs based on the second regional warp, and exemplarily, the step of storing the second domain vertex information in the second regional warp is performed.
[0082] Optionally, when the output mode is the third output mode, the vertex information output by the vertex shader is obtained through the shell shader, the image control point information is generated according to the vertex information, the second patch block is generated according to the image control point information, and the image control point information constituting the second patch block is sent to the surface subdivision unit. The image subdivision parameter is obtained from the image subdivision parameter register through the surface subdivision unit, the third domain vertex information is generated according to the image control point information constituting the second patch block and the image subdivision parameter, and the third domain vertex information and the image control point information constituting the second patch block are sent to the region shader. The third region cache information for storing the third domain vertex information is obtained through the region shader, and the third region thread warp is generated according to the image control point information constituting the second patch block, the third domain vertex information and the third region cache information.
[0083] In one embodiment, when the output mode is the third output mode, the second shell buffer area information for storing image control point information can also be obtained through the shell shader, and can be sent to the thread bundle execution unit after the second shell thread bundle is generated, and the thread bundle execution unit performs processing steps based on the second shell thread bundle, for example, inputting the image control point information constituting the second patch block into the shell buffer area. Optionally, after the third region thread bundle is generated, the third region thread bundle can be sent to the thread bundle execution unit, and the thread bundle execution unit executes according to the received third region thread bundle, exemplarily, performing the step of storing the third domain vertex information in the second region thread bundle.
[0084] Optionally, when the output mode is the fourth output mode, the vertex information output by the vertex shader is obtained through the shell shader, and the image control point information is generated according to the vertex information output by the vertex shader, the third patch block is generated according to the image control point information, the image subdivision parameters are generated according to the subdivision parameter configuration information, and the image control point information and image subdivision parameters constituting the third patch block are sent to the surface subdivision unit. The surface subdivision unit obtains the image control point information and image subdivision parameters constituting the third patch block from the third shell buffer information, and generates the fourth domain vertex information according to the image control point information and image subdivision parameters constituting the third patch block, and sends the image control point information and the fourth domain vertex information constituting the third patch block to the regional shader. The fourth regional buffer information for storing the fourth domain vertex information is obtained through the regional shader, and the fourth regional thread warp is generated according to the fourth regional buffer information, the fourth domain vertex information and the image control point information constituting the third patch block, and the fourth regional thread warp is sent to the thread warp execution unit.
[0085] In one embodiment, when the output mode is the fourth output mode, it may also include obtaining, through a shell shader, a third shell buffer information for storing image control point information and image subdivision parameters constituting a third patch block, generating a third shell thread bundle based on the image control point information, the image subdivision parameters and the third shell buffer information, and sending the third shell buffer information to a tessellation unit; the tessellation unit obtains the image control point information and the image subdivision parameters based on the third shell buffer information. Optionally, the region shader may send the fourth region thread bundle to a thread bundle execution unit, and the thread bundle execution unit executes the processing steps based on the thread bundle. Exemplarily, the thread bundle execution unit executes the step of inputting the vertex information and image subdivision parameters constituting the third patch block into the third shell buffer information based on the third shell thread bundle. Exemplarily, the thread bundle execution unit may also execute the step of inputting the fourth domain vertex information into the fourth region buffer information based on the fourth region thread bundle.
[0086] In an optional embodiment, the shell shader may include a control unit, and the control unit implements data processing, for example, obtaining an output mode, obtaining a control command, etc.
[0087] In one embodiment, the shell shader may further include a warp generation unit for implementing the generation of the shell warp.
[0088] In the above-mentioned image data processing method, an output mode indicating the image subdivision type and the image control point information output mode is obtained, a target processing logic is determined according to the output mode, and the image subdivision parameters and the image control point information are processed according to the target processing logic, so that different processing logics are provided according to the different subdivision parameter types and the output modes of the image control point information, effectively reducing the problem of low data processing efficiency caused by a single processing logic, and effectively improving the image processing efficiency. Moreover, when the output mode indicates that the image control point information is the vertex information output by the shell shader, and the image subdivision parameter is a constant, the shell shader directly outputs the vertex information, and the surface subdivision unit directly obtains the image subdivision parameter. In this process, the shell shader does not need to generate a shell thread bundle, reducing the execution of application instructions, and does not need to allocate a shell buffer area for the shell shader, reducing the occupation of the storage space by the shell shader, then the vertex shader and the region shader can obtain more storage space, and more vertex thread bundles and region thread bundles can be started in parallel, effectively improving the data processing efficiency. In the above-mentioned image processing method, when there is image control point information that is not vertex information output by the vertex shader and the image subdivision parameter is a constant, or when the image control point information is vertex information output by the vertex shader and the image subdivision parameter is not a constant, although the shell shader needs to generate a shell thread bundle and needs to allocate storage space for the image control point information or the image subdivision parameter, it only executes the calculation steps of the image control point information or the image subdivision parameter, and allocates storage space for the image control point information or the image subdivision parameter. Compared with the related art of calculating and processing the image control point information and the image subdivision parameter and allocating storage space, it can effectively reduce the calculation steps and save storage space. It can also obtain more storage space for the vertex shader and the region shader, and can start more vertex thread bundles and region thread bundles in parallel, effectively improving data processing efficiency.
[0089] In an exemplary embodiment, Figure 3 As shown, an image data processing method is provided. This embodiment takes the method applied to a terminal as an example for illustration. It can be understood that the method can also be applied to a server, and can also be applied to a system including a terminal and a server, and is implemented through the interaction between the terminal and the server. In this embodiment, the method includes the following steps:
[0090] Step S302, obtaining the output mode corresponding to the hull shader transmitted by the vertex shader.
[0091] The output mode is used to indicate the type of image subdivision parameters and the output method of the shell shader for the image control point information.
[0092] Step S304, determining whether the output mode is the first output mode, if yes, executing step S306, if no, executing step S312.
[0093] The first output mode indicates that the image control point information is vertex information output by the vertex shader, and the type of the image subdivision parameter is a constant.
[0094] Step S306: Generate a first patch block according to the image control point information through a shell shader, and send the image control point information constituting the first patch block to a tessellation unit.
[0095] The image control point information constituting the first facet block is vertex information output by the vertex shader.
[0096] Step S308, obtaining image subdivision parameters from the image subdivision parameter register through the surface subdivision unit, generating first domain vertex information according to the image control point information constituting the first patch block and the image subdivision parameters, and sending the first domain vertex information and the image control point information constituting the first patch block to the region shader.
[0097] Among them, the image subdivision parameters in the image subdivision parameter register are output by the vertex shader.
[0098] Step S310 , obtaining first regional cache information through a regional shader, and generating a first regional warp according to image control point information constituting a first patch block, first domain vertex information and first regional cache information.
[0099] Step S312, determine whether the output mode is the second output mode, if yes, execute step S314, if no, execute step S320.
[0100] The second output mode indicates that the image control point information is vertex information output by the vertex shader, and the type of the image subdivision parameter is a non-constant.
[0101] Step S314, obtaining the subdivision parameter configuration information transmitted by the vertex shader through the shell shader, generating image subdivision parameters according to the subdivision parameter configuration information, generating a first patch block according to the image control point information, and sending the image control point information of the first patch block to the surface subdivision unit.
[0102] The image control point information constituting the first facet block is vertex information output by the vertex shader.
[0103] Step S316, obtaining image subdivision parameters from the first shell buffer through the surface subdivision unit, generating second domain vertex information according to the image control point information constituting the first patch block and the image subdivision parameters, and sending the second domain vertex information and the image control point information constituting the first patch block to the region shader.
[0104] Step S318, obtaining second regional cache information through the regional shader, and generating a second regional warp according to the image control point information constituting the first patch block, the second domain vertex information and the second regional cache information.
[0105] Step S320, determining whether the output mode is the third output mode, if so, executing step S322, if not, executing step S328.
[0106] The third output mode indicates that the image control point information is not vertex information output by the vertex shader, and the type of the image subdivision parameter is a constant.
[0107] Step S322, obtaining vertex information output by the vertex shader through the shell shader, generating image control point information according to the vertex information, generating a second patch block according to the image control point information, and sending the image control point information constituting the second patch block to the tessellation unit.
[0108] The image control point information constituting the second patch block is generated by the shell shader according to the vertex information output by the vertex shader.
[0109] Step S324, obtaining image subdivision parameters from the image subdivision parameter register through the surface subdivision unit, generating third domain vertex information according to the image control point information constituting the second patch block and the image subdivision parameters, and sending the third domain vertex information and the image control point information constituting the second patch block to the region shader.
[0110] Step S326 , obtaining third region cache information through the region shader, and generating a third region warp according to the image control point information constituting the second patch block, the third domain vertex information and the third region cache information.
[0111] Step S328, obtain the vertex information output by the vertex shader through the shell shader, and generate image control point information according to the vertex information output by the vertex shader, generate a third face block according to the image control point information, generate image subdivision parameters according to the subdivision parameter configuration information transmitted by the vertex shader, and send the image control point information and image subdivision parameters constituting the third face block to the surface subdivision unit.
[0112] Optionally, the hull shader may obtain third hull buffer information for storing vertex information and image subdivision parameters constituting a third patch block, generate a third hull warp based on the third hull buffer, and send the third hull warp to the warp processing unit.
[0113] Optionally, the hull shader may send the third hull buffer information to the tessellation unit, so that the tessellation unit obtains the image control point information and the image tessellation parameters constituting the third patch block from the third hull buffer information.
[0114] Step S330: Generate fourth domain vertex information according to the image control point information and image subdivision parameters constituting the third patch block through the surface subdivision unit, and send the image control point information and fourth domain vertex information constituting the third patch block to the regional shader.
[0115] Step S332, obtaining fourth region buffer information for storing fourth domain vertex information through the regional shader, and generating a fourth region warp according to the fourth region buffer information, the fourth domain vertex information and the image control point information constituting the third patch block.
[0116] In the above-mentioned image data processing method, an output mode indicating the image subdivision type and the image control point information output mode is obtained, a target processing logic is determined according to the output mode, and the image subdivision parameters and the image control point information are processed according to the target processing logic, so that different processing logics are provided according to the different subdivision parameter types and the output modes of the image control point information, effectively reducing the problem of low data processing efficiency caused by a single processing logic, and effectively improving the image processing efficiency. Moreover, when the output mode indicates that the image control point information is the vertex information output by the shell shader, and the image subdivision parameter is a constant, the shell shader directly outputs the vertex information, and the surface subdivision unit directly obtains the image subdivision parameter. In this process, the shell shader does not need to generate a shell thread bundle, reducing the execution of application instructions, and does not need to allocate a shell buffer area for the shell shader, reducing the occupation of the storage space by the shell shader, then the vertex shader and the region shader can obtain more storage space, and more vertex thread bundles and region thread bundles can be started in parallel, effectively improving the data processing efficiency. In the above-mentioned image processing method, when there is image control point information that is not vertex information output by the vertex shader and the image subdivision parameter is a constant, or when the image control point information is vertex information output by the vertex shader and the image subdivision parameter is not a constant, although the shell shader needs to generate a shell thread bundle and needs to allocate storage space for the image control point information or the image subdivision parameter, it only executes the calculation steps of the image control point information or the image subdivision parameter, and allocates storage space for the image control point information or the image subdivision parameter. Compared with the related art of calculating and processing the image control point information and the image subdivision parameter and allocating storage space, it can effectively reduce the calculation steps and save storage space. It can also obtain more storage space for the vertex shader and the region shader, and can start more vertex thread bundles and region thread bundles in parallel, effectively improving data processing efficiency.
[0117] It should be understood that, although the steps in the flowcharts involved in the above embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps is not strictly limited in order, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above embodiments may include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.
[0118] Based on the same inventive concept, the embodiment of the present application also provides an image data processing device for implementing the image data processing method involved above. The implementation solution provided by the device to solve the problem is similar to the implementation solution recorded in the above method, so the specific limitations in one or more image data processing device embodiments provided below can refer to the limitations of the image data processing method above, and will not be repeated here.
[0119] In an exemplary embodiment, Figure 4 As shown, an image data processing device 400 is provided, comprising: an output mode acquisition module 402, a processing logic acquisition module 404 and a processing module 406, wherein:
[0120] The output mode acquisition module 402 is used to acquire the output mode corresponding to the hull shader transmitted by the vertex shader; the output mode is used to indicate the type of image subdivision parameters and the output method of the hull shader for the image control point information.
[0121] The processing logic acquisition module 404 is used to acquire the target processing logic according to the output mode.
[0122] The processing module 406 is used to process the image subdivision parameters and the image control point information according to the target processing logic to obtain a processing result.
[0123] In one embodiment, the processing module is further used to output the vertex information output by the vertex shader to the surface subdivision unit through the shell shader when the image control point information is the vertex information output by the vertex shader; and read the image subdivision parameter from the image subdivision parameter register through the surface subdivision unit when the type of the image subdivision parameter is a constant.
[0124] In one embodiment, the output mode includes at least one of a first output mode, a second output mode and a third output mode; wherein the first output mode indicates that the image control point information is vertex information output by a vertex shader, and the type of the image subdivision parameter is a constant; the second output mode indicates that the image control point information is vertex information output by a vertex shader, and the type of the image subdivision parameter is a non-constant; the third output mode indicates that the image control point information is not vertex information output by a vertex shader, and the type of the image subdivision parameter is a constant.
[0125] In an optional embodiment, the output mode is the first output mode; the processing module is also used to generate a first patch block according to the image control point information through the shell shader, and send the image control point information constituting the first patch block to the surface subdivision unit, wherein the image control point information constituting the first patch block is the vertex information output by the vertex shader; obtain the image subdivision parameters from the image subdivision parameter register through the surface subdivision unit, generate the first domain vertex information according to the image control point information constituting the first patch block and the image subdivision parameters, and send the first domain vertex information and the image control point information constituting the first patch block to the region shader; obtain the first region cache information through the region shader, generate the first region thread bundle according to the image control point information constituting the first patch block, the first domain vertex information and the first region cache information, wherein the first region cache information is used to store the first domain vertex information.
[0126] In one of the embodiments, the output mode is the second output mode; the processing module is further used to obtain subdivision parameter configuration information output by the vertex shader through the shell shader, generate image subdivision parameters according to the subdivision parameter configuration information, generate a first patch block according to the image control point information, and send the image control point information of the first patch block to the surface subdivision unit, wherein the image control point information constituting the first patch block is the vertex information output by the vertex shader; obtain the image subdivision parameters from the first shell buffer area through the surface subdivision unit, generate the second domain vertex information according to the image control point information and the image subdivision parameters of the first patch block, and send the second domain vertex information and the image control point information constituting the first patch block to the region shader; obtain the second region cache information through the region shader, generate the second region thread bundle according to the image control point information constituting the first patch block, the second domain vertex information and the second region cache information, wherein the second region cache information is used to store the second domain vertex information.
[0127] In one embodiment, the output mode is a third output mode, and the processing module is further used to obtain vertex information output by the vertex shader through a shell shader, generate image control point information according to the vertex information, generate a second patch block according to the image control point information, and send the image control point information constituting the second patch block to a surface subdivision unit; obtain image subdivision parameters from an image subdivision parameter register through the surface subdivision unit, generate third domain vertex information according to the image control point information constituting the second patch block and the image subdivision parameters, and send the third domain vertex information and the image control point information constituting the second patch block to a region shader; obtain third region cache information through the region shader, generate a third region thread bundle according to the image control point information constituting the second patch block, the third domain vertex information and the third region cache information, wherein the third region cache information is used to store the third domain vertex information.
[0128] Each module in the above-mentioned image data processing device can be implemented in whole or in part by software, hardware or a combination thereof. Each module can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in a computer device in the form of software, so that the processor can call and execute the operations corresponding to each module.
[0129] In an exemplary embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as shown in FIG. Figure 5 As shown. The computer device includes a processor, a memory, an input / output interface (Input / Output, referred to as I / O) and a communication interface. The processor, the memory and the input / output interface are connected through a system bus, and the communication interface is connected to the system bus through the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store data. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, an image data processing method is implemented.
[0130] Those skilled in the art will understand that Figure 5 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0131] In an exemplary embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps of the above-mentioned method embodiments when executing the computer program.
[0132] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps of the above-mentioned method embodiments are implemented.
[0133] In one embodiment, a computer program product is provided, including a computer program, which implements the steps of the above-mentioned method embodiments when executed by a processor.
[0134] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant regulations.
[0135] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, an artificial intelligence (AI) processor, etc., but are not limited to this.
[0136] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.
[0137] The above embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A method for processing image data, characterized in that: The method comprises: Obtaining an output mode corresponding to the hull shader transmitted by the vertex shader; the output mode is used to indicate the type of image subdivision parameters and the output method of the hull shader for image control point information; According to the output mode, obtaining target processing logic; The image subdivision parameters and the image control point information are processed according to the target processing logic to obtain a processing result.
2. The method according to claim 1, characterized in that: The processing of the image subdivision parameters and the image control point information according to the target processing logic to obtain a processing result includes: In a case where the image control point information is vertex information output by the vertex shader, outputting the vertex information output by the vertex shader to a tessellation unit through the hull shader; In a case where the type of the image subdivision parameter is a constant, the image subdivision parameter is read from an image subdivision parameter register by a surface subdivision unit.
3. The method according to claim 1 or 2, characterized in that: The output mode includes at least one of a first output mode, a second output mode and a third output mode; The first output mode indicates that the image control point information is vertex information output by the vertex shader, and the type of the image subdivision parameter is a constant; The second output mode indicates that the image control point information is vertex information output by the vertex shader, and the type of the image subdivision parameter is a non-constant; The third output mode indicates that the image control point information is not vertex information output by the vertex shader, and the type of the image subdivision parameter is a constant.
4. The method according to claim 3, characterized in that The output mode is the first output mode; the image subdivision parameters and the image control point information are processed according to the target processing logic to obtain a processing result, including: Generate a first patch block according to the image control point information through the shell shader, and send the image control point information constituting the first patch block to a tessellation unit, wherein the image control point information constituting the first patch block is vertex information output by the vertex shader; Obtaining the image subdivision parameter from an image subdivision parameter register through the surface subdivision unit, generating first domain vertex information according to the image control point information constituting the first patch block and the image subdivision parameter, and sending the first domain vertex information and the image control point information constituting the first patch block to a region shader; The first regional cache information is obtained through the regional shader, and the first regional thread warp is generated according to the image control point information constituting the first patch block, the first domain vertex information and the first regional cache information, wherein the first regional cache information is used to store the first domain vertex information.
5. The method according to claim 3, characterized in that: The output mode is the second output mode; the image subdivision parameters and the image control point information are processed according to the target processing logic to obtain a processing result, including: Acquire the subdivision parameter configuration information transmitted by the vertex shader through the shell shader, generate the image subdivision parameters according to the subdivision parameter configuration information, acquire a first shell buffer for storing the image subdivision parameters, generate a first patch block according to the image control point information, and send the image control point information constituting the first patch block to a tessellation unit, wherein the image control point information constituting the first patch block is the vertex information output by the vertex shader; Acquire the image subdivision parameters from the first shell buffer through the tessellation unit, generate second domain vertex information according to the image control point information constituting the first patch block and the image subdivision parameters, and send the second domain vertex information and the image control point information constituting the first patch block to the region shader; The second regional cache information is obtained through the regional shader, and the second regional thread warp is generated according to the image control point information constituting the first patch block, the second domain vertex information and the second regional cache information, wherein the second regional cache information is used to store the second domain vertex information.
6. The method according to claim 3, characterized in that The output mode is the third output mode, and the image subdivision parameters and the image control point information are processed according to the target processing logic to obtain the processing results including: Acquire vertex information output by the vertex shader through a shell shader, generate the image control point information according to the vertex information, generate a second patch block according to the image control point information, and send the image control point information constituting the second patch block to a tessellation unit; Obtaining the image subdivision parameter from the image subdivision parameter register through the surface subdivision unit, generating third domain vertex information according to the image control point information constituting the second surface patch and the image subdivision parameter, and sending the third domain vertex information and the image control point information constituting the second surface patch to the region shader; The third region cache information is obtained through the region shader, and a third region thread warp is generated according to the image control point information constituting the second patch block, the third domain vertex information and the third region cache information, wherein the third region cache information is used to store the third domain vertex information.
7. An image data processing device, characterized in that: The device comprises: An output mode acquisition module, used to acquire an output mode corresponding to a hull shader transmitted by a vertex shader; the output mode is used to indicate the type of image subdivision parameters and the output mode of the hull shader for image control point information; A processing logic acquisition module, used to acquire target processing logic according to the output mode; A processing module is used to process the image subdivision parameters and the image control point information according to the target processing logic to obtain a processing result.
8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 6 are implemented.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.
10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.