visad
Class DelaunayCustom

java.lang.Object
  extended by visad.Delaunay
      extended by visad.DelaunayCustom
All Implemented Interfaces:
java.io.Serializable

public class DelaunayCustom
extends Delaunay

DelaunayCustom is a set of constructors to create an instance of Delaunay by passing in a pre-computed triangulation. DelaunayCustom is useful for creating instances of Delaunay that can be passed into IrregularSet. If you want to perform consistency checks on your triangulation, call Delaunay.test() on your DelaunayCustom object after it is constructed.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class visad.Delaunay
Edges, NumEdges, Tri, Vertices, Walk
 
Constructor Summary
DelaunayCustom(float[][] samples, int[][] tri)
          shortcut constructor
DelaunayCustom(float[][] samples, int[][] tri, int[][] vertices, int[][] walk, int[][] edges, int num_edges)
          complete constructor
DelaunayCustom(float[][] samples, int[][] tri, int[][] vertices, int[][] walk, int[][] edges, int num_edges, boolean copy)
           
 
Method Summary
static boolean checkAndFixSelfIntersection(float[][] samples)
          return true if closed path in samples self-intersects
static boolean checkSelfIntersection(float[][] samples)
          return true if closed path in samples self-intersects
static boolean checkSelfIntersection(Gridded2DSet set)
          return true if closed path in samples self-intersects
static void clip(float[][] samples, int[][] tris, float xc, float yc, float v, float[][][] outs, int[][][] outt)
          clip (samples, tris) against xc * x + yc * c <= v
static float computeArea(float[][] samples)
          compute area inside closed path
static float computeArea(Gridded2DSet set)
          compute area inside closed path
static float computeArea(UnionSet set)
          compute area inside closed path
static int[][] fill(float[][] samples)
          check that float[2][number_of_points] samples describes the boundary of a simply connected plane region; return a decomposition of that region into triangles whose vertices are all boundary points from samples; the trick is that the region may not be convex, but the triangles must all lie inside the region
static Irregular2DSet fill(Gridded2DSet set)
          check that set describes the boundary of a simply connected plane region; return a decomposition of that region into triangles whose vertices are all boundary points from samples, as an Irregular2DSet
static Irregular2DSet fill(UnionSet set)
          check that set describes the boundary of a simply connected plane region; return a decomposition of that region into triangles whose vertices are all boundary points from samples, as an Irregular2DSet
static int[][] fillCheck(float[][] samples, boolean check)
           
static Irregular2DSet fillCheck(Gridded2DSet set, boolean check)
           
static Irregular2DSet fillCheck(UnionSet set, boolean check)
           
static boolean inside(float[][] s, float x, float y)
          determine if (x, y) is inside the closed path defined by s
static float[][] link(float[][][] ss)
          link multiple paths into a single path
 
Methods inherited from class visad.Delaunay
clone, factory, finish_triang, getNonConvex, improve, perturb, sampleString, scale, setNonConvex, test, toString
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DelaunayCustom

public DelaunayCustom(float[][] samples,
                      int[][] tri)
               throws VisADException
shortcut constructor

Throws:
VisADException

DelaunayCustom

public DelaunayCustom(float[][] samples,
                      int[][] tri,
                      int[][] vertices,
                      int[][] walk,
                      int[][] edges,
                      int num_edges)
               throws VisADException
complete constructor

Throws:
VisADException

DelaunayCustom

public DelaunayCustom(float[][] samples,
                      int[][] tri,
                      int[][] vertices,
                      int[][] walk,
                      int[][] edges,
                      int num_edges,
                      boolean copy)
               throws VisADException
Throws:
VisADException
Method Detail

checkSelfIntersection

public static boolean checkSelfIntersection(Gridded2DSet set)
                                     throws VisADException
return true if closed path in samples self-intersects

Throws:
VisADException

checkSelfIntersection

public static boolean checkSelfIntersection(float[][] samples)
                                     throws VisADException
return true if closed path in samples self-intersects

Throws:
VisADException

checkAndFixSelfIntersection

public static boolean checkAndFixSelfIntersection(float[][] samples)
                                           throws VisADException
return true if closed path in samples self-intersects

Throws:
VisADException

computeArea

public static float computeArea(UnionSet set)
                         throws VisADException
compute area inside closed path

Throws:
VisADException

computeArea

public static float computeArea(Gridded2DSet set)
                         throws VisADException
compute area inside closed path

Throws:
VisADException

computeArea

public static float computeArea(float[][] samples)
                         throws VisADException
compute area inside closed path

Throws:
VisADException

fill

public static Irregular2DSet fill(Gridded2DSet set)
                           throws VisADException
check that set describes the boundary of a simply connected plane region; return a decomposition of that region into triangles whose vertices are all boundary points from samples, as an Irregular2DSet

Throws:
VisADException

fillCheck

public static Irregular2DSet fillCheck(Gridded2DSet set,
                                       boolean check)
                                throws VisADException
Throws:
VisADException

fill

public static int[][] fill(float[][] samples)
                    throws VisADException
check that float[2][number_of_points] samples describes the boundary of a simply connected plane region; return a decomposition of that region into triangles whose vertices are all boundary points from samples; the trick is that the region may not be convex, but the triangles must all lie inside the region

Throws:
VisADException

fillCheck

public static int[][] fillCheck(float[][] samples,
                                boolean check)
                         throws VisADException
Throws:
VisADException

fill

public static Irregular2DSet fill(UnionSet set)
                           throws VisADException
check that set describes the boundary of a simply connected plane region; return a decomposition of that region into triangles whose vertices are all boundary points from samples, as an Irregular2DSet

Throws:
VisADException

fillCheck

public static Irregular2DSet fillCheck(UnionSet set,
                                       boolean check)
                                throws VisADException
Throws:
VisADException

link

public static float[][] link(float[][][] ss)
                      throws VisADException
link multiple paths into a single path

Throws:
VisADException

inside

public static boolean inside(float[][] s,
                             float x,
                             float y)
                      throws VisADException
determine if (x, y) is inside the closed path defined by s

Throws:
VisADException

clip

public static void clip(float[][] samples,
                        int[][] tris,
                        float xc,
                        float yc,
                        float v,
                        float[][][] outs,
                        int[][][] outt)
                 throws VisADException
clip (samples, tris) against xc * x + yc * c <= v

Throws:
VisADException