[vtkusers] vtkDataArray: Memory allocation problem

David Doria daviddoria+vtk at gmail.com
Mon Feb 1 10:04:09 EST 2010


On Mon, Feb 1, 2010 at 9:22 AM, Liam Kurmos <quantum.leaf at googlemail.com>wrote:

> Hi,
>
> I figured out how to do this recently too. Previously I was loading a 1D
> array and then using setScalars for the whole volume (as per another
> example). Eventually i found  SetScalarComponentFromDouble in the
> documentation.
>
> This example would have been helpful but I didn't find it. At first i
> didn't appreciate that ImageData could be a volume. I'm not sure a beginner
> would know that IterateImageData<http://www.cmake.org/Wiki/VTK/Examples/IterateImageData>is what theyre looking for.
>
> not sure how this could be best improved, but thought i'd give feedback,
>
> Liam
>
>
Liam,

This type of feedback is extremely important, thanks.

I added a sentence to the section:

*Working with Stuctured (grid aligned) 3D Data (vtkImageData)*
"ImageData" is not the traditional "flat, 2D image" you are used to. It is a
special VTK data structure in the collection of 3D data structures provided
by VTK. Here is an overview of these data structures: [1]. Image data can
represent at typical 2D image, but also, a 3D volume.

I also added:
"Set and access locations in a 3D image."
on the main examples page with the example you referred to, and

"This example demonstrates how to set and access locations in a 3D image."
On the example itself.

Would this have helped you find what you were looking for? Any further
suggestions?

Thanks,

David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20100201/5bb2f40b/attachment.htm>


More information about the vtkusers mailing list