[vtkusers] initializing vtk array from std::vector for charting

arasu arasakumaran at yahoo.com
Mon Jun 27 01:59:58 EDT 2016


I have data that is stored in std::vector - one for the X axis and one for the y axis. How do I get this into vtkarray / vtkTable for plotting - other than iterate through the vector and setting values one by one (there is a lot of data ).  my data is either std::vector<double> or std::vector<unsigned short>.   
Is there a way to assign a pointer from my data to the vtkarray, or at least do a bulk copy of all the data rather than individually setting the values.
Thanks in advance,
-Arasu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtkusers/attachments/20160627/cd57bb9c/attachment.html>


More information about the vtkusers mailing list