
Chapter 4
GPU Computing
4.1 Drawing a 3D Object
The classical use of shader programming on GPUs involves drawing 3D
geometric primitives within a 2D window using perspective projection. In
order to motivate the parallelism that a GPU provides, let us review all the
steps involved in drawing a 3D geometric object. The parallelism comes in two
forms. The first form is the partitioning of the work due to the large number of
pixels that can be processed independently—this is massive parallelism due to
a large number of cores on the GPU. The second form is the vectorized work
per vertex and per pixel—this is SIMD parallelism available on each core. A
detailed ...