[vtkusers] Multiple Scalars

Said. Said.El_Kasmi at sophia.inria.fr
Mon Nov 24 03:35:45 EST 2003




Hi,

In Java I do it this way:

for(int counter=0; counter< NUMBER_OF_ARRAYS; counter++){
      getUnstructuredGrid().GetPointData().AddArray(solution[counter]); 
}

Greg Novak wrote:
> 
> Something I find puzzling about VTK is how to get multiple scalars into
> the same data file.  I've searched the mailing list archives, and the
> consensus seesm to be to "Put one scalar value into the 'Scalars' slot in
> the data set attributes, and put the other in as field data."  Fine, but
> why?  Scalars can have one to four components (making them seemingly
> un-scalar-like, but that's another issue), so why not just put your first
> scalar in the first slot, second in the second, etc?  Why doesn't anyone
> do it that way?
> 
> Furthermore, if you construct a data file with multiple scalars (not as
> field data or as addtional components in the same "scalars" block, but as
> a separate "scalars" block) in it, VTK can read it based on the names you
> give to the scalar values.  But it does not seem to be able to write such
> a file.  Correct?
> 
> Thanks,
> Greg
> 
> _______________________________________________
> This is the private VTK discussion list.
> Please keep messages on-topic. Check the FAQ at: <http://public.kitware.com/cgi-bin/vtkfaq>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers

-- 
Said.
--------------------------------------------------------------------
Said EL KASMI.
INRIA - Projet CAIMAN. 2004, Route des Lucioles - BP 93     
06902 Sophia Antipolis Cedex (France)- Tel: 04 92 38 79 07     
Email:   Said.El_kasmi at sophia.inria.fr



More information about the vtkusers mailing list