# US 2023/0267570 A1 · Data Processing Method and Related Apparatus

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2023/0267570 A1
- Document ID: US20230267570A1
- Status: Published application
- Kind: A1
- Application number: 18/308,969
- Filed: 2023-04-28
- Published: 2023-08-24
- Earliest claimed: 2020-10-28
- Assignees: Huawei Technologies Co., Ltd.
- Applicants: Huawei Technologies Co., Ltd.
- Inventors: Jing Ren; Deyou Kong
- Web page: https://patentgrep.com/patent/US20230267570A1

## CPC

- G06T 1/20: Processor architectures; Processor configuration, e.g. pipelining
- G06T 15/005: {General purpose rendering architectures}
- G06F 9/5027: {the resource being a machine, e.g. CPUs, Servers, Terminals}
- G06T 15/04: Texture mapping
- G06T: IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

A data processing method includes a graphics processing unit (GPU) obtaining rendering data that is sent by a central processing unit (CPU) and that includes a plurality of pieces of attribute data. The GPU stores the plurality of pieces of attribute data into continuous storage space, for example, stores the plurality of pieces of attribute data into the continuous storage space in a form of an array. Then, the GPU directly determines an address of target attribute data in the continuous storage space based on an attribute selector to obtain the target attribute data.

## Claims

### Claim 1

A data processing method implemented by a graphics processing unit (GPU), wherein the data processing method comprises:
obtaining, from a central processing unit (CPU), rendering data, wherein the rendering data comprises a plurality of pieces of first attribute data, and wherein all of the plurality have a same attribute type;
arranging the plurality into a continuous storage space;
obtaining an attribute selector corresponding to a to-be-rendered material, wherein the attribute selector is for selecting second attribute data for rendering the to-be-rendered material;
determining, based on the attribute selector, an address of target attribute data in the continuous storage space, wherein the target attribute data is for rendering the to-be-rendered material; and
obtaining, based on the address, the target attribute data from the continuous storage space.

### Claim 2 (depends on 1)

The data processing method of claim 1, wherein arranging the plurality comprises arranging, based on a storage sequence of the plurality, the plurality into the continuous storage space.

### Claim 3 (depends on 2)

The data processing method of claim 2, further comprising obtaining, from the CPU, indication information, wherein the indication information indicates location information of the plurality, and wherein arranging the plurality further comprises:
determining, based on the indication information, storage locations of the plurality; and
arranging, based on a sequence of the storage locations, the plurality into the continuous storage space.

### Claim 4 (depends on 3)

The data processing method of claim 3, wherein the indication information comprises mapping relationships between attribute indexes and the storage locations, and wherein the attribute indexes identify the plurality.

### Claim 5 (depends on 3)

The data processing method of claim 3, wherein one of the storage locations is for storing one or more pieces of third attribute data of a same attribute type.

### Claim 6 (depends on 1)

The data processing method of claim 1, wherein determining the address comprises determining, based on the attribute selector and a first data length of the target attribute data, the address, and wherein all of the plurality have a same data length.

### Claim 7 (depends on 6)

The data processing method of claim 6, further comprising obtaining a first starting address of the continuous storage space, and wherein determining the address comprises:
determining, based on the first starting address and a product of the attribute selector and the first data length, a second starting address of the target attribute data; and
determining, based on the second starting address and the first data length, an end address of the target attribute data.

### Claim 8 (depends on 1)

The data processing method of claim 1, wherein the rendering data are based on the to-be-rendered material, and wherein all of the first attribute data are required for rendering the to-be-rendered material.

### Claim 9 (depends on 1)

The data processing method of claim 1, wherein the rendering data comprises position attribute data, normal attribute data, color attribute data, texture coordinate attribute data, tangent attribute data, joint attribute data, or weight attribute data.

### Claim 10

An electronic device, comprising:
a central processing unit (CPU); and
a graphics processing unit (GPU) coupled to the CPU and configured to:
obtain, from the CPU, rendering data, wherein the rendering data comprises a plurality of pieces of first attribute data, and wherein all of the plurality have a same attribute type;
arrange the plurality into continuous storage space;
obtain an attribute selector corresponding to a to-be-rendered material, wherein the attribute selector is for selecting second attribute data for rendering the to-be-rendered material;
determine, based on the attribute selector, an address of target attribute data in the continuous storage space, wherein the target attribute data is for rendering the to-be-rendered material; and
obtain, based on the address, the target attribute data from the continuous storage space.

### Claim 11 (depends on 10)

The electronic device of claim 10, wherein the GPU is further configured to arrange, based on a storage sequence of the plurality, the plurality into the continuous storage space.

### Claim 12 (depends on 11)

The electronic device of claim 11, wherein the GPU is further configured to:
obtain, from the CPU, indication information, wherein the indication information indicates location information of the plurality;
determine, based on the indication information, storage locations of the plurality; and
arrange, based on a sequence of the storage locations, the plurality into the continuous storage space.

### Claim 13 (depends on 12)

The electronic device of claim 12, wherein the indication information comprises mapping relationships between attribute indexes and the storage locations, and wherein the attribute indexes identify the plurality.

### Claim 14 (depends on 12)

The electronic device of claim 12, wherein one of the storage locations is for storing one or more pieces of third attribute data of a same attribute type.

### Claim 15 (depends on 10)

The electronic device of claim 10, wherein the GPU is further configured to determine, based on the attribute selector and a first data length of the target attribute data, the address, and wherein all of the plurality have a same data length.

### Claim 16 (depends on 15)

The electronic device of claim 15, wherein the GPU is further configured to:
obtain a first starting address of the continuous storage space;
determine, based on the first starting address and a product of the attribute selector and the first data length, a second starting address of the target attribute data; and
determine, based on the second starting address and the first data length, an end address of the target attribute data.

### Claim 17 (depends on 10)

The electronic device of claim 10, wherein the CPU is further configured to determine, based on the to-be-rendered material, the rendering data, and wherein all of the first attribute data are required for rendering the to-be-rendered material.

### Claim 18 (depends on 10)

The electronic device of claim 10, wherein the rendering data comprises position attribute data, normal attribute data, color attribute data, texture coordinate attribute data, tangent attribute data, joint attribute data, or weight attribute data.

### Claim 19

A computer program product comprising instructions stored on a non-transitory computer-readable medium that, when execute by one or more processors, cause a graphics processing unit (GPU) to:
obtain, from a central processing unit (CPU), rendering data, wherein the rendering data comprises a plurality of pieces of first attribute data, and wherein all of the plurality have a same attribute type;
arrange the plurality into continuous storage space;
obtain an attribute selector corresponding to a to-be-rendered material, wherein the attribute selector is for selecting second attribute data for rendering the to-be-rendered material;
determine, based on the attribute selector, an address of target attribute data in the continuous storage space, wherein the target attribute data is for rendering the to-be-rendered material; and
obtain, based on the address, the target attribute data from the continuous storage space.

### Claim 20 (depends on 19)

The computer program product of claim 19, wherein the one or more processors are further configured to execute the instructions to arrange, based on a storage sequence of the plurality, the plurality into the continuous storage space.
