[Insight-users] How to convert 3d image into 1D vector array......

Iván Macía imacia at vicomtech.org
Wed May 27 12:17:31 EDT 2009


Hi Habib,

The pixel buffer of itk::Image class, no matter if the dimension of the
image is 2D, 3D or ND, is actually stored as a 1D continuous array which you
can access through the method GetPixelContainer(). However, I would strongly
recommend to use iterators for this task. The standard
ImageRegion(Const)Iterator will provide sequencial access to this pixel
container. If you want to access pixels in some other fashion there are
several other types of iterators.

Read the ITK Software Guide or have a look at the iterator examples if you
don't know how to use them.

Regards

Iván 




-----Mensaje original-----
De: insight-users-bounces at itk.org [mailto:insight-users-bounces at itk.org] En
nombre de Habib Baluwala
Enviado el: miércoles, 27 de mayo de 2009 16:06
Para: insight-users at itk.org
Asunto: [Insight-users] How to convert 3d image into 1D vector array......


Dear ITK users, 
                    I wanted to needed some advice with regards to how to
convert the 3d image into 1d vector array for numerical computations. Any
help would be highly appreciated. 
-- 
View this message in context:
http://n2.nabble.com/How-to-convert-3d-image-into-1D-vector-array......-tp29
81274p2981274.html
Sent from the ITK Insight Users mailing list archive at Nabble.com.

_____________________________________
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 ITK FAQ at:
http://www.itk.org/Wiki/ITK_FAQ

Follow this link to subscribe/unsubscribe:
http://www.itk.org/mailman/listinfo/insight-users



More information about the Insight-users mailing list