Graphics Reference
In-Depth Information
The depth range values n and f can be set using the following API call:
void glDepthRangef (GLclampf n, GLclampf f )
n, f specify the desired depth range. Default values for n and f are 0.0
and 1.0, respectively. The values are clamped to lie within (0.0, 1.0).
The values specified by glDepthRangef and glViewport are used to
transform the vertex position from normalized device coordinates into
window (screen) coordinates.
The initial (or default) viewport state is set to w = width and h = height
of the window created by the application in which OpenGL ES is to do
its rendering. This window is given by the EGLNativeWindowType win
argument specified in eglCreateWindowSurface .
Rasterization
Figure 7-9 shows the rasterization pipeline. After the vertices have
been transformed and primitives have been clipped, the rasterization
pipelines take an individual primitive such as a triangle, a line segment,
or a point sprite and generate appropriate fragments for this primitive.
Each fragment is identified by its integer location ( x , y ) in screen space.
A fragment represents a pixel location given by ( x , y ) in screen space and
additional fragment data that will be processed by the fragment shader
to produce a fragment color. These operations are described in detail in
Chapter 9, “Texturing,” and Chapter 10, “Fragment Shaders.”
Point-Sprite
Rasterization
From
Primitive
Assembly
Line
Rasterization
Line
Rasterization
Output for each fragment—
screen (x w , y w ) coordinate,
attributes such as color,
texture coordinates, etc.
Triangle
Rasterization
To Fragment Shader Stage
Figure 7-9
OpenGL ES Rasterization Stage
 
 
 
Search WWH ::




Custom Search