Unidata - To provide the data services, tools, and cyberinfrastructure leadership that advance Earth system science, enhance educational opportunities, and broaden participation. Unidata
         
  advanced  
 

Re: 2 displays for one cross section (different GriddedSets)

Hi Stu,

> Say I've got a 3D display and in it show a slice or cross-section
> (by making a new FlatField from 3D data by making a Gridded3Dset
> describing the plane of the slice in 3D space and resampling the full 
> FlatField
> of 3D data to a new FlatField "sliceFF" using the Gridded3DSet).
> 
> Now further the cross section data in "sliceFF" is also shown in a separate
> 2D display, a DisplayImplJ2D. This involves making a new FlatField
> say "slice2D" with a new Gridded2DSet, and some RealTypes
> and ScalarMaps based on that, and a new FunctionType, DataReference etc.
> 
> Now by some user interface method the original slice in 3D is
> repositioned.  sliceFF is recomputed
> 
> How do I send word to the 2D display to go get the
> modified "sliceFF" when it is changed, make its display again?  Or is there 
> some
> even more subtle way to move the new data into the second display,
> such as sharing a data reference in either the Java or VisAD sense?

You should have a DataReference to sliceFF that's been
linked via an addReference() call to your DisplayImplJ2D.
When you update the FlatField in sliceFF via a setData()
call on the DataReference, that will trigger the
DisplayImplJ2D to re-display.

Cheers,
Bill


 
 
  Contact Us     Site Map     Search     Terms and Conditions     Privacy Policy     Participation Policy
 
National Science Foundation (NSF) UCAR Community Programs   Unidata is a member of the UCAR Community Programs, is managed by the University Corporation for Atmospheric Research, and is sponsored by the National Science Foundation.
P.O. Box 3000     Boulder, CO 80307-3000 USA     Tel: 303-497-8643     Fax: 303-497-8690