23.06.2013 Views

The OpenGL Graphics System: A Specification

The OpenGL Graphics System: A Specification

The OpenGL Graphics System: A Specification

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

4.1. PER-FRAGMENT OPERATIONS 199<br />

Fragment<br />

+<br />

Associated<br />

Data<br />

Framebuffer<br />

Pixel<br />

Ownership<br />

Test<br />

Framebuffer<br />

Blending<br />

(RGBA Only)<br />

Depth buffer<br />

Test<br />

Figure 4.1. Per-fragment operations.<br />

Scissor<br />

Test<br />

Framebuffer<br />

Dithering<br />

4.1 Per-Fragment Operations<br />

Stencil<br />

Test<br />

Framebuffer<br />

Alpha<br />

Test<br />

(RGBA Only)<br />

Logicop<br />

To<br />

Framebuffer<br />

A fragment produced by rasterization with window coordinates of (xw, yw) modifies<br />

the pixel in the framebuffer at that location based on a number of parameters<br />

and conditions. We describe these modifications and tests, diagrammed in<br />

figure 4.1, in the order in which they are performed. Figure 4.1 diagrams these<br />

modifications and tests.<br />

4.1.1 Pixel Ownership Test<br />

<strong>The</strong> first test is to determine if the pixel at location (xw, yw) in the framebuffer<br />

is currently owned by the GL (more precisely, by this GL context). If it is not,<br />

the window system decides the fate the incoming fragment. Possible results are<br />

that the fragment is discarded or that some subset of the subsequent per-fragment<br />

operations are applied to the fragment. This test allows the window system to<br />

control the GL’s behavior, for instance, when a GL window is obscured.<br />

Version 2.0 - October 22, 2004

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!