
39. Th e ANGLE Project: Implementing OpenGL ES 2 .0 on Direct3D 553
gl_FrontFacing = dx_PointsOrLines || ( dx_FrontCCW ? (input . vFace >= 0.0) : input.←
vFace <= 0.0) );
Listing 39.3. Calculation of front-facing built-in variable.
The gl PointCoord variable provides a set of 2D coordinates that indicate
where in a point primitive the current fragment is located. The values must vary
from0to1horizontally(lefttoright)andfrom0to1vertically(toptobot-
tom). These values can be used as texture coordinates in order to provide textured
point sprites. Direct3D also has the ability to synthesize texture coordinates for
the generated vertices of the point sprit ...