[vtkusers] Get raw data from vtkimagedata
Jothybasu Selvaraj
jothybasu at gmail.com
Fri Jun 22 11:54:40 EDT 2012
GetScalarPointer(i,j,k) automatically manages the coordinates (i,j,k) but
incase of c-array (it's a linear array) you need to figure out the index
(only one, since its a 1D) from i,j,k.
This is waht I came to knoe from my own experience and some oither on the
list when i tried to export the vtkImageData to python (when there were no
helper classes to do this).
maybe someone can shed more light on this!
Jothy
On Fri, Jun 22, 2012 at 4:41 PM, David Doria <daviddoria at gmail.com> wrote:
> On Fri, Jun 22, 2012 at 11:37 AM, Jothybasu Selvaraj <jothybasu at gmail.com>wrote:
>
>> I think it will export the scalar data into a c array (not as a 3D array).
>>
>
> What is the difference? I thought GetScalarPointer() just gives you a
> "type*" ? (
> http://www.vtk.org/doc/nightly/html/classvtkImageData.html#a567566b094dcc3187061dc5ff02a6abb)
> How is that different from a "c array"?
>
> David
>
--
Jothybasu Selvaraj
PhD Student
University of Liverpool
UK
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20120622/b0108aed/attachment.htm>
More information about the vtkusers
mailing list