[vtkusers] vtkDoubleArray -- you can set the number of values but you can't get the number of values?

Thompson, David C dcthomp at sandia.gov
Wed Feb 18 13:39:37 EST 2009


You may call GetMaxId(), which returns the number of values minus 1 (since
IDs start at 0).

    David
________________________________________
From: vtkusers-bounces at vtk.org [vtkusers-bounces at vtk.org] On Behalf Of kent williams [nkwmailinglists at gmail.com]
Sent: Wednesday, February 18, 2009 10:34
To: VTK users group
Subject: [vtkusers] vtkDoubleArray -- you can set the number of values but you can't get the number of values?

I've been staring for some time at the Doxygen man pages for
vtkDoubleArray and vtkDataArray.  It seems that there is a member
function vtkDoubleArray::SetNumberOfValues(), but no corresponding
vtkDoubleArray::GetNumberOfValues().

This seems to indicate that you have to make sure that you never try
to read out more values than you've put in to the array, because
there's no way to check this.

Or am I missing something?
_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ

Follow this link to subscribe/unsubscribe:
http://www.vtk.org/mailman/listinfo/vtkusers





More information about the vtkusers mailing list