Re: [visad] HowTo Questions: gray scale, shader gray scale, viewers position, process monitor and netcdf access to large files

  • To: visad@xxxxxxxxxxxxxxxx
  • Subject: Re: [visad] HowTo Questions: gray scale, shader gray scale, viewers position, process monitor and netcdf access to large files
  • From: Tom Rink <rink@xxxxxxxxxxxxx>
  • Date: Wed, 14 Jul 2010 10:36:08 -0500
Hi Marius,

Marius Schmidt wrote:
Hi again VisAD community,

as my work progresses I fall more and more in love with the ease of use of the VisAD library :-). But for today I do not only have laud but also a bunch of questions I hope you can help me with:

1. Gray Scale:
a) I have learned from the tutorial and documentation, that I have to create a custom lookup table to provide a gray scale mapping using Display.RGB(A). If I only map to gray in a 3D display I was wondering, if internally 24 (32) bit texture are used nevertheless? If yes, is it possible to enforce the use of an 8-bit luminance texture instead to reduce memory consumption and allow bigger datasets uploaded to GPU memory?

Yes, this is possible, we've done this with our new image renderer. It can be
forced on the command line, and hopefully we'll just detect from table when
it can be used. This is development code, so you won't have access to it
right away.

b) Before I started working with VisAD I experimented with some fragment shader based application of lookup tables as explained in some literature. I searched the library for the usage of Shader programms but did not find any. Am I guessing right that color table is applied to data before uploading it to the GPU? At which place might it be possible and a good idea to implement a shader based lookup table for real-time coloring of depictions (by only exchanging the lookup map stored as lookup texture in GPU memory and accessed by a fragment shader)?

Using byReference rendering, and a smart analysis of what work needs to be
done on a 'doTransform', we're getting pretty close to this kind of capability
while staying away from GPU specifics. I'm not sure how portable shader
programming is.

2. Viewers position:
I have not found a way yet to Setup the initial users view point viewing direction, I guess I overlooked something, can you help me out ?

I believe Transform3D in Java3D has methods which will help you.

3. Process monitor
Some calculations or data fetching processes in VisAD take longer than a few seconds and I would like to display their progress using a process monitor showing the user, that there is still something going on. I have seen, that as soon as the display is up and there are calculations going on a "please wait" message is being displayed. But that does not work for initial pre-displayed processes like fetching and analyzing data of a bigger Netcdf dataset. Is there a hook to ask Visad how many percent of a job is already processed ?

4. Netcdf
a) I have seen that there is Plain as a reader for NetCDF datasets. I transformed one of the dicom image sets available at the human visible project into netcdf format, but without attention to any convention like CF. Following the VerySimple and Simple example of the developers guide did not really worked for me, so I set the MathType, FunctionType and Set informations up manually and handed them over to a FlatField. Then I used Plain only to read the sample values from the netcdf file into the FlatField in reversed order. It works allright but I am wondering what to keep in mind, that the plain reader works innately. How do I have to prepare my NetCDF files, which conventions are known to Plain?

b) I shall try to visualize some of the measuring results of the Coltrims experiment (for your interest: Unfortunately the data files come in chunks of more than 10 GB each. I found that there are classes called VirtualData, FileFlatField, etc. and hope, that my guess is right. Are they are somehow intended to be used for accessing datasets that do not fit into memory? How do I utilize them for fast retrieving of slices in dimension of 500MB? I do not have the heart yet trying to access one of those files, because I did have not really understood, how to use them, and I do not want to freeze my system instantly :-D

I'll try to get you some specifics on what was done with caching, our goal is to be able to animate perhaps several hundred, roughly 1000x1000, satellite images. Of
course, caching saves memory, but is performance hit.


  • 2010 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the visad archives: