
396 GPGPU Programming for Games and Science
associated with corner (0, 0, 0) and 1 is associated with corner (1, 0, 0). Vertex
v
5
is associated with pair (1, 3) and vertex v
6
is associated with pair (1, 5).
The triple of indices for the triangle formed by these three vertices is (0, 5, 6).
The ordering is counterclockwise when viewed from the negative side of the
level surface, say, from the corner (1, 0, 0) that has a negative function value.
The table in full is
int i=0x29; // s i gn b i ts , b in ar y 00101001 (−−+−+−−+)
table [ i ][0] = 9;
table [ i ][1] = 5;
table[ i ][2..25] = { 0,1,0,4,0,2,2,3,3,7,1,3,1,5,5,7,4,5,x,x,x,x,x,x} ;
table [ i ][24..40] ...