NAME

     ijkgenpatch - generate isosurface patch


SYNOPSIS

     #include "ijktable.h"
     void ijkgenpatch
       (const IJKTABLE::ISOSURFACE_TABLE_POLYHEDRON & polyhedron,
        const int * const vertex_sign,
        vector<ISOSURFACE_VERTEX_INDEX> & isov_list,
        int & num_simplices);
     void ijkgenpatch_nep
       (const IJKTABLE::ISOSURFACE_TABLE_POLYHEDRON & polyhedron,
        const int * const vertex_sign,
        vector<ISOSURFACE_VERTEX_INDEX> & isov_list,
        vector<ISOSURFACE_VERTEX::ISOSURFACE_VERTEX_TYPE> &
          isov_type,
        int & num_simplices);


ARGUMENTS

     const IJKTABLE::ISOSURFACE_TABLE_POLYHEDRON & polyhedron
          A convex polyhedron  containing  the  isosurface.   The
          polyhedron  may be in dimension other than three but it
          must be convex for ijkgenpatch to produce a proper iso-
          surface.

     const int * const vertex_sign
          Encoding of vertex signs,  -1,  0  or  1,  representing
          negative, zero and positive.  vertex_sign[i] represents
          the vertex sign of vertex i. Vertices with sign -1 have
          scalar value less than the isovalue, vertices with sign
          0 have scalar value equal to the isovalue and  vertices
          with  sign  1  have  scalar value greater than the iso-
          value.

     vector<ISOSURFACE_VERTEX_INDEX> & isov_list
          Array  containing  isosurface  vertices   returned   by
          ijkgenpatch  or  ijkgenpatch_nep.  Isosurface simplex j
          has      isosurface      vertices      (isov_list[d*j],
          isov_list[d*j+1],  ...,  isov_list[d*j+d-1]) where d is
          the polyhedron dimension.

     ISOSURFACE_VERTEX::ISOSURFACE_VERTEX_TYPE & isov_type
          Array containing isosurface vertex  types  returned  by
          ijkgenpatch_nep.  Isosurface  vertex  isov_list[k]  has
          vertex type isov_type[k]. The  isosurface  vertex  type
          determines if an isosurface vertex lies on a polyhedron
          vertex, edge or facet.

     int & num_simplices
          Number of isosurface simplices returned by ijkgenpatch.



DESCRIPTION

     Given a convex polyhedron  polyhedron  and  a  sign  pattern
     (+/-)  defined by vertex_sign, ijkgenpatch generates an iso-
     surface in the polyhedron which separates the  positive  (+)
     vertices  from the negative (-) ones.  ijkgenpatch returns a
     set of d-dimensional simplices forming the isosurface  where
     d  is  the dimension of the convex polyhedron.  The vertices
     of each simplex lie on the edges of the original polyhedron.
     The vertices are specified, not by their coordinates, but by
     the  polyhedron  edges  containing   the   vertices.    This
     separates  the  computation  of  vertex coordinates from the
     generation of the isosurface simplices.

     ijkgenpatch_nep is similar to ijkgenpatch but takes  a  sign
     pattern  (+/0/-)  defined by vertex_sign, where 0 represents
     polyhedron vertices whose scalar value equals the  isovalue.
     ijkgenpatch_nep  generates  an  isosurface in the polyhedron
     which separates the positive (+) vertices from the  negative
     (-)  ones.   ijkgenpatch_nep  returns a set of d-dimensional
     simplices forming the isosurface where d is the dimension of
     the  convex polyhedron.  The vertices of each simplex lie on
     the vertices and edges of the original polyhedron.  The iso-
     surface  vertices  are  specified, not by their coordinates,
     but by the polyhedron vertices and edges containing the ver-
     tices.  This separates the computation of vertex coordinates
     from the generation of the isosurface simplices.


NOTES

     The input polyhedron must  be  convex  for  ijkgenpatch  and
     ijkgenpatch_nep to produce a proper isosurface.  ijkgenpatch
     and ijkgenpatch_nep create an isosurface from  a  subset  of
     the  convex  hull of a subset of the polyhedron vertices and
     edge midpoints.  It uses a convex hull routine written by K.
     Clarkson.


SEE ALSO

     ijkgentable,ijktable(3).


AUTHOR

     Praveen Bhaniramka, Rephael Wenger













Man(1) output converted with man2html