Using the gts_isosurface_cartesian() function, it is possible to build a triangulated isosurface of a given user-defined function. As its name indicates this function assumes that the values of the user-defined function are defined for points located on a regular cartesian grid described by the GtsCartesianGrid parameter. The triangles describing the isosurface are computed for each pair of successive planes z and z+dz in a pipelined manner. Consequently only two planes need to be stored in memory at any time. This allows to construct isosurfaces for datasets too large to fit in main memory.
A regular cartesian grid is defined by the number of points in each direction, the spatial increment in each direction and the coordinates of the first point.
A GtsIsoSlice is an opaque data structure containing the coordinates of the points located on the isosurface for a given slice of the user-defined function.
void (*GtsIsoCartesianFunc) (gdouble **a,
GtsCartesianGrid g,
guint i,
gpointer data);
This user-defined function is passed to the gts_isosurface_cartesian()
function. Given a particular GtsCartesianGridg it must fill the array a
with the values of the function for the plane z=g.z (or for the corresponding
index i). This function is always called in order by gts_isosurface_cartesian(), i.e. i varies from 0 to g.nz - 1 with an increment of one (and similarly g.z is incremented every time by g.dz).
Adds to surface new faces defining the isosurface f(x,y,z) = iso. By
convention, the normals to the surface are pointing toward the positive
values of f(x,y,z) - iso.
The user function f is called successively for each value of the z
coordinate defined by g. It must fill the corresponding (x,y) plane with
the values of the function for which the isosurface is to be computed.
Adds to surface new faces defining the isosurface f(x,y,z) =
iso. By convention, the normals to the surface are pointing toward
the positive values of f(x,y,z) - iso.
The user function f is called successively for each value of the z
coordinate defined by g. It must fill the corresponding (x,y)
plane with the values of the function for which the isosurface is
to be computed.
Adds to surface new faces defining the isosurface f(x,y,z) =
iso. By convention, the normals to the surface are pointing toward
the positive values of f(x,y,z) - iso. To ensure a closed object,
a boundary of G_MINDOUBLE is added around the domain
The user function f is called successively for each value of the z
coordinate defined by g. It must fill the corresponding (x,y)
plane with the values of the function for which the isosurface is
to be computed.