NAME

cxQmeshTris - generate polygon vertex indexing to create a quadrilateral mesh using cell centers
#include <cx/Qmesh.h>

long *cxQmeshTris(long m, long n, int *numIndices)
integer function cxQmeshTris( m, n, numIndices )
integer m, n, numIndices
integer pindices
pointer (pindices,indices)
m
Number of grid points in I (first) dimension.
n
Number of grid points in J (second) dimension.
numIndices
Output number of vertex indices.
Returns an array of vertex indices used to describe the triangle strips comprising the quadrilateral mesh. cxQmeshTris computes the triangulation of a quadrilateral mesh, taking into account the values at the grid cell centers. This is significant because standard quad-mesh generation uses only two triangles per grid cell, which means that the rendered cell center value will be independent of two corner values. Using only two triangles per grid cell may create rendering artifacts, which this routine attempts to eliminate.

The output of cxQmeshTris is an array of vertex indices in the usual triangle strip notation (see cxGeoTrisDefine), along with a count of the number of indices. The strips average about 11 indices per 8 triangles and include no swaps. The strips assume the vertex ordering given by cxQmeshData and cxQmeshCoords.

Geometry can be created from the grid points output of cxQmeshCoords and the output of cxQmeshTris with a call to cxGeoTrisDefine.

cxGeoTrisDefine(3E), cxGeoGridDefine(3E), cxQmeshCoords(3E), cxQmeshData(3E), cxQmeshNumPoints(3E), cxQmeshNumTris(3E), cxQmeshNextInd(3E), LatToGeom(1E), MultiSlice(1E)
Last modified: Mon Nov 6 16:33:47 GMT 2000
[ Documentation Home ]
© The Numerical Algorithms Group Ltd, Oxford UK. 1999