Re: Delaunay Triangulation

Hi Bill and all others,

I did manage to include the with VisAD created Delaunay Shape3D Object in
my application. 


  /**
     * Triangulation of given set of points with delaunay. This method 
     * throws an event, when 3D-Objects are ready. See displayChanged.
     */
    public void makeSurface() {
        //System.out.println("Hallo Delaunay!");
        RealType x = RealType.getRealType("x");
        RealType y = RealType.getRealType("y");
        RealType height = RealType.getRealType("height");
        try {
            RealTupleType xy = new RealTupleType(x, y);
            FunctionType terrain_type = new FunctionType(xy, height);
            Irregular2DSet set = new Irregular2DSet(xy,new float[][]
{eastValues,northValues});
            FlatField terrain = new FlatField(terrain_type, set);
            terrain.setSamples(new float[][] {heightValues});
                    
            display = new DisplayImplJ3D("display1");
            ScalarMap hoxmap = new ScalarMap(x, Display.XAxis);
            ScalarMap reymap = new ScalarMap(y, Display.YAxis);
            ScalarMap heightmap = new ScalarMap(height, Display.ZAxis);
                    
            display.addMap(hoxmap);
            display.addMap(reymap);
            display.addMap(heightmap);
                
            hoxmap.setRange(-1.0, 1.0);
            reymap.setRange(-1.0, 1.0);
            heightmap.setRange(-1.0, 1.0);
            
            DataReferenceImpl data_ref = new
DataReferenceImpl("data_ref"); 
            data_ref.setData( terrain );
            renderer = new DefaultRendererJ3D();
            display.addReferences(renderer,data_ref);
            display.addDisplayListener(listener);
        }
        catch (VisADException ve) {
            System.out.println("VisAd TupleType Exception");
        }       
        catch (RemoteException re) {
            System.out.println("RemoteExcpetion");
        }
        //System.out.println("Delaunay ende!"); 
    }

Is it possible with visad to get a shap3d of a part of this triangulation?
Say, I do have coordinates of a point and want to clip the parts of the
object, which are more far away, than 10m, or something similar?

Thanks for your help in advance

Desiree



o------------------------------------------------------------------------o
| Desiree Hilbring      Institut fuer Photogrammetrie und Fernerkundung  | 
|                       Universitaet Karlsruhe, Germany                  |
|                                                                        |
|                       email: hilbring@xxxxxxxxxxxxxxxxxxxx             |
|                       # 0721 6083676                                   |
o------------------------------------------------------------------------o