NOTICE: This version of the NSF Unidata web site (archive.unidata.ucar.edu) is no longer being updated.
Current content can be found at unidata.ucar.edu.
To learn about what's going on, see About the Archive Site.
Hi Ibrahim, > I'm changing the 'reference' (by setting a new field to my > ref.setData()) in my program to change the display for my animation. The > display updates automatically but sometimes takes some time as the > dataset is pretty large. Is there a method by which I can determine if > the display has finished updating so that I can wait before I move on to > the next change? Construct a DisplayListener, and pass it to the addDisplayListener() method of your DisplayImpl. In its displayChanged() method, check for TRANSFORM_DONE events - they should tell you when the transforms triggered by your setData() calls are done. > I’m sorry, I should have added this to the last email. I have a > problem when I try to use display.getImage(), I get an exception that > says > > Exception occurred during event dispatching: > > visad.VisADError: cannot call getImage() from Thread: AWT-EventQueue-0 You cannot call getImage() from a GUI callback. From your callback create a new Thread that makes the getImage() call and does whatever is needed with the returned image. I think there is an example of this in the SpreadSheet source. Cheers, Bill
visad
archives: