fine level control

This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.

Content-Type: text/plain

Greetings,

 

I am attempting real-time VisAD visualization with a plasma code and I have
a few issues regarding RealTupleTypes and FlatField.setSamples().  I would
like to include all possible variables that can be visualized when my code
is initialized, but not all of them will be plotted all of the time as the
simulation progresses.  The user can turn variables on and off through a
GUI.  Therefore I would like to set only the samples for the data that I
want to visualize at that particular iteration.  So I have set up my
RealTupleTypes as following.

 

 

density = RealType.getRealType("density", SI.meter, null);

densityTuple = new RealTupleType(density);

 

temperature = RealType.getRealType("temperature", SI.meter, null);

temperatureTuple = new RealTupleType(temperature);

 

velocity = new RealType[Ndims];

for(int n=0;n<Ndims;n++)

{   velocity[n] = RealType.getRealType("velocity"+n, SI.meter, null);

}

velocityField = new RealTupleType(velocity);

 

electromagnetic = new RealType[Ndims];

for(int n=0;n<Ndims;n++)

{   electromagnetic[n] = RealType.getRealType("electromagnetic"+n, SI.meter,
null);

}

electromagneticField = new RealTupleType(electromagnetic);

 

etc...

 

 

This has worked well so far because I am able to setSamples() for each
individual FlatField separately.  Therefore when I don't want to visualize a
variable, I just don't set its samples.  But what I really want, is to do
things like generate a 3D surface plot of the density and then map
streamlines for the flow field on top of the density surface.  This is
easily accomplished by creating a RealTupleType with density, velocityX, and
velocityY.  Then you just set the samples for all 3 variables.  But what
happens if you don't want to map the streamlines to the density surface
anymore?  It seems as if you still have to set the samples for all 3
variables.  I don't see  method in FlatField which allows you to set samples
for individual components.  If not, is there a way around this, or possibly
should a new method be added which allows you to select which variable you
want to set?  I guess you could create a new RealTupleType, FlatField,
DataReference, etc..., but it would be nice if one could selectively set the
samples for a desired variable.

 

Thanks in advance.



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