# US 2016/0364898 A1 · Optimizing for rendering with clear color

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

- Number: US 2016/0364898 A1
- Document ID: US20160364898A1
- Status: Published application
- Kind: A1
- Application number: 14/737,302
- Filed: 2015-06-11
- Published: 2016-12-15
- Earliest claimed: 2015-06-11
- Assignees: Intel Corporation
- Inventors: Bimal Poddar; Prasoonkumar Surti; Rahul P. Sathe
- Web page: https://patentgrep.com/patent/US20160364898A1

## CPC

- G06T 15/005: {General purpose rendering architectures}
- G06T 1/60: Memory management
- G06T 15/04: Texture mapping
- G06T 15/506: {Illumination models}
- G06T 19/20: Editing of three-dimensional [3D] images, e.g. changing shapes or colours, aligning objects or positioning parts
- G06T 2200/04: involving 3D image data
- G06T 2200/28: involving image processing hardware
- G06T 2210/62: Semi-transparency
- G06T: IMAGE DATA PROCESSING OR GENERATION, IN GENERAL

## Abstract

Embodiments provide for a graphics processing apparatus comprising render logic to detect rendering operations that will result in framebuffer having the same data as the initial clear color value and morphing such rendering operations to optimizations that are typically done for initial clearing of the framebuffer.

## Claims

### Claim 1

A graphics processing apparatus comprising:
render logic to set a first control bit associated with a first region of memory to a value which represents a clear color value in response to a request to write the clear color to the first region of memory; and
clear color detection logic to detect the request to write the clear color to the first region of memory and cause the render logic to set the first control bit.

### Claim 2 (depends on 1)

The apparatus as in claim 1, wherein the first control bit is associated with a first cache region, the first cache region to cache data for the first region of memory.

### Claim 3 (depends on 1)

The apparatus as in claim 1, wherein the render logic is further to write to a second region of memory and set a second control bit associated with the second region of memory to a value indicating that the second region of memory has valid data.

### Claim 4 (depends on 3)

The apparatus as in claim 3, wherein the second control bit is associated with a second cache region, the second cache region to cache data for the second region of memory.

### Claim 5 (depends on 4)

The apparatus as in claim 4, wherein the render logic is to write to the second cache region and set the second control bit in association with the write.

### Claim 6 (depends on 5)

The apparatus as in claim 5, further comprising sampler logic to read the first control bit and sample from internal logic storing the clear color value in response to a request to sample from the first region of memory and read the second control bit and sample from the second region of memory in response to a request to sample the second region of memory.

### Claim 7 (depends on 6)

The apparatus as in claim 6, wherein the first region of memory and the second region of memory are regions of stencil buffer memory.

### Claim 8 (depends on 6)

The apparatus as in claim 6, wherein the first region of memory is a first composition surface, the second region of memory is a second composition surface, and the first and second composition surfaces are to be composited to a framebuffer.

### Claim 9 (depends on 6)

The apparatus as in claim 6, wherein the first region of memory and the second region of memory are regions of framebuffer memory.

### Claim 10 (depends on 9)

The apparatus as in claim 9, further comprising display controller logic to read from a clear color register in response to a first request to display the first region of memory based on the first control bit and read from the second region of memory in response to a second request to display the second region of memory based on the second control bit.

### Claim 11 (depends on 1)

The apparatus as in claim 1, wherein the clear color detection logic is to cause the render logic to discard the clear color write to the first region of memory.

### Claim 12

A non-transitory machine-readable medium storing data which, when read by one or more machines, causes the one or more machines to fabricate one or more integrated circuits to perform a process comprising:
clearing a framebuffer by setting a first set of control bits associated with a first set of cache lines of a framebuffer cache to a value representing a clear state; and
drawing to the framebuffer by writing color data to a first cache line in the first set of cache lines of the framebuffer cache; and
setting a first control bit in the first set of control bits to a value representing a data state.

### Claim 13 (depends on 12)

The medium as in claim 12, the process further comprising:
detecting a write of a designated clear color to a second cache line;
setting a second control bit associated with the second cache line to a value representing a clear state; and
discarding the second cache line without evicting the second cache line to the framebuffer.

### Claim 14 (depends on 13)

The medium as in claim 13, wherein detecting the clear color in the second cache line includes compressing pixel data in the cache line and detecting the clear color via the compressed pixel data.

### Claim 15 (depends on 14)

The medium as in claim 14, wherein compressing pixel data in the cache line includes setting a base compression value to the designated clear color and determining a delta value for each pixel value in the cache line.

### Claim 16 (depends on 15)

The medium as in claim 15, wherein detecting the clear color via the compressed pixel data includes detecting whether the delta value for each pixel is zero.

### Claim 17 (depends on 12)

The medium as in claim 12, the process further comprising:
clearing a stencil buffer by setting a second set of control bits associated with a second set of cache lines to a value representing a clear state; and
writing to the stencil buffer by writing data to the second set of cache lines and setting control bits in the second set of control bits to a value representing a data state.

### Claim 18 (depends on 12)

The medium as in claim 12, the process further comprising:
receiving a designation of a clear color value; and
storing the clear color value in a register.

### Claim 19 (depends on 18)

A medium as in claim 18, the process further comprising:
receiving a request to sample a region of the framebuffer associated with a second control bit having a value representing a rendered clear color state and sampling the clear color value in the register in response to the request.

### Claim 20 (depends on 18)

A medium as in claim 18, the process further comprising:
receiving a request to display a region of the framebuffer associated with a second control bit having a value representing a rendered clear color state and displaying the clear color value in the register in response to the request.

### Claim 21

A desktop composition system comprising:
one or more processors coupled to memory, the one or more processors including at least one graphics processor; and
a compositor to execute via the one or more processors, the compositor to:
determine a predominant color for a surface;
set clear color value to the predominant color;
request a clear of the surface after setting the clear color value;
render a desktop window to the surface via the one or more processors, at least one of the one or more processors to suppress writes of the clear color to the surface during the render.

### Claim 22 (depends on 21)

The system as in claim 21, wherein the one or more processors are to:
detect a write of the clear color to a region of the surface;
set a control bit associated with the region to a value indicating that the region has the clear color value; and
suppress the write of the clear color to the region.

### Claim 23 (depends on 21)

The system as in claim 21, wherein the compositor is further to perform a desktop composition operation which includes to sample the surface during composition, at least one of the one or more processors including a sampler to sample regions of the surface having the clear color value from an internal register based on a control bit associated with the region.

### Claim 24 (depends on 23)

The system as in claim 23, wherein the compositor is further to perform a desktop composition operation which includes to write of a portion of the surface to a framebuffer, at least one of the one or more processors to suppress the write of the portion of the surface to the framebuffer if the portion of the surface has the clear color value based on the control bit associated with the region.

### Claim 25 (depends on 24)

The system as in claim 24, wherein the compositor is further to request the one or more processors to display a composited framebuffer, wherein the one or more processors are to display the predominant color of the surface using a value from an internal register.
