# US 11,120,605 B2 · Approximate trilinear filtering

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

- Number: US 11,120,605 B2
- Document ID: US11120605B2
- Status: Granted
- Kind: B2
- Application number: 16/828,926
- Filed: 2020-03-24
- Published: 2021-07-15
- Granted: 2021-09-14
- Earliest claimed: 2020-01-09
- Assignees: Samsung Electronics Co., Ltd.
- Applicants: Samsung Electronics Co., Ltd.
- Inventors: Anders M. Kugler; Aayush Ankit; Wilson Wai Lun Fung
- Web page: https://patentgrep.com/patent/US11120605B2

## CPC

- G06T 15/04: Texture mapping
- G06T 1/20: Processor architectures; Processor configuration, e.g. pipelining
- G06T 1/60: Memory management
- G06T 15/503: {Blending, e.g. for anti-aliasing}
- G06T 2210/36: Level of detail
- G06T: IMAGE DATA PROCESSING OR GENERATION, IN GENERAL

## Abstract

A texture filtering unit and a method are disclosed that provide multiple variants of an approximate trilinear filtering operation. A texture sampling and filtering unit may be configured to determine a level-of-detail (LOD) value for a sample point in texture space, and select, based on the LOD value, a fine mip-level and a coarse mip-level from the mip-map. The closer of the two selected mip-levels to the sample point is determined, and farther of the two selected mip-levels from the sample point is determined. A first quad of texels in the closer mip-level and a second quad of texels in the farther mip-level are then determined. A total of five or fewer texels are selected from the first quad of texels and from the second quad of texels. A filtered value for the sample point is determined based on an approximate trilinear filtering operation on the selected texels.

## Claims

### Claim 1

A graphics processing unit (GPU), comprising:
a memory that stores mip-levels of a mip-map; and
a texel sampling unit coupled to the memory, the texel sampling unit being configured to:
determine a level-of-detail (LOD) value for a sample point in texture space,
select, based on the LOD value, a fine mip-level and a coarse mip-level from the mip-map,
determine which of the fine mip-level and the coarse mip-level selected based on the LOD value is closer to the sample point,
determine which of the fine mip-level and the coarse mip-level selected based on the LOD value is farther away from the sample point,
determine a first quad of texels in the mip-level closest to the sample point and a second quad of texels in the other mip-level farther away from the sample point, the first quad of texels comprising four texels in a 2×2 arrangement of texels, the second quad of texels comprising four texels in a 2×2 arrangement of texels,
select a total of five or fewer texels from the first quad of texels and from the second quad of texels, and
determine a value for the sample point based on an approximate trilinear filtering operation on the selected texels.

### Claim 2 (depends on 1)

The GPU of claim 1, wherein the texel sampling unit selects the total of five or fewer texels from the first quad of texels and from the second quad of texels in a same clock cycle.

### Claim 3 (depends on 1)

The GPU of claim 1, wherein the texel sampling unit is further configured to:
determine weights to blend texels selected from the first quad of texels based on a Manhattan distance to the sample point; and
determine weights to blend texels selected from the second quad of texels based on a Manhattan distance to the sample point.

### Claim 4 (depends on 1)

The GPU of claim 1, wherein the texel sampling unit selects a total of four texels, two of the four texels being selected from the first quad of texels and two of the four texels being selected from the second quad of texels.

### Claim 5 (depends on 4)

The GPU of claim 4, wherein the texels selected in first quad of texels are the texels that are closest to the sample point, and
wherein the texels selected in the second quad of texels are the texels that are closest from the sample point.

### Claim 6 (depends on 4)

The GPU of claim 4, wherein the texel sampling unit selects the texels in first quad of texels that are the texels that are farthest from the sample point, and
wherein the texel sampling unit selects the texels in the second quad of texels that are the texels that are closest from the sample point.

### Claim 7 (depends on 1)

The GPU of claim 1, wherein the texel sampling unit selects the texel in the first quad of texels that is closest to the sample point, and
wherein the texel sampling unit selects the four texels of the second quad of texels.

### Claim 8 (depends on 1)

The GPU of claim 1, wherein the texel sampling unit selects a total of four texels, three of the four texels being selected from the first quad of texels and one of the four texels being selected from the second quad of texels, and
wherein the three of the four texels selected from the first quad of texels are interpolated based on a barycentric interpolation.

### Claim 9 (depends on 8)

The GPU of claim 8, wherein the texel selected from the second quad of texels is farthest from the sample point.

### Claim 10 (depends on 8)

The GPU of claim 8, wherein the texel selected from the second quad of texels is closest to the sample point.

### Claim 11

A method to approximate trilinear filtering, the method comprising:
determining a level-of-detail (LOD) value for a sample point in texture space;
selecting, based on the LOD value, a fine mip-level and a coarse mip-level from a mip-map;
determining which of the fine mip-level and the coarse mip-level selected based on the LOD value is closer to the sample point;
determining which of the fine mip-level and the coarse mip-level selected based on the LOD value is farther away from the sample point;
determining a first quad of texels in the mip-level closest to the sample point and a second quad of texels in the mip-level farther away from the sample point, the first quad of texels comprising four texels in a 2×2 arrangement of texels, and the second quad of texels comprising four texels in a 2×2 arrangement of texels;
selecting a total of five or fewer texels from the first quad of texels and from the second quad of texels; and
determining a value for the sample point based on an approximate trilinear filtering operation on the selected texels.

### Claim 12 (depends on 11)

The method of claim 11, wherein selecting the total of five or fewer texels from the first quad of texels and from the second quad of texels is performed in a same clock cycle.

### Claim 13 (depends on 11)

The method of claim 11, further comprising:
determining weights to blend texels selected from the first quad of texels based on a Manhattan distance to the sample point; and
determining weights to blend texels selected from the second quad of texels based on a Manhattan distance to the sample point.

### Claim 14 (depends on 11)

The method of claim 11, wherein a total of four texels are selected, two of the four texels being selected from the first quad of texels and two of the four texels being selected from the second quad of texels.

### Claim 15 (depends on 14)

The method of claim 14, wherein the texels selected in first quad of texels are the texels that are closest to the sample point, and
wherein the texels selected in the second quad of texels are the texels that are closest from the sample point.

### Claim 16 (depends on 14)

The method of claim 14, wherein the texels selected in first quad of texels are the texels that are farthest from the sample point, and
wherein the texels selected in the second quad of texels are the texels that are closest from the sample point.

### Claim 17 (depends on 11)

The method of claim 11, wherein the texel selected in the first quad of texels is closest to the sample point, and
wherein the four texels of the second quad of texels are selected.

### Claim 18 (depends on 11)

The method of claim 11, wherein a total of four texels are selected, three of the four texels being selected from the first quad of texels and one of the four texels being selected from the second quad of texels
the method further comprising:
interpolating the three of the four texels selected from the first quad of texels based on a barycentric interpolation.

### Claim 19 (depends on 18)

The method of claim 18, wherein the texel selected from the second quad of texels is farthest from the sample point.

### Claim 20 (depends on 18)

The method of claim 18, wherein the texel selected from the second quad of texels is closest to the sample point.
