[Insight-users] Desperation: performing itkfilters on a subset (e.g. slice) on a 3D Image

John Drescher drescherjm at gmail.com
Fri Aug 24 10:54:09 EDT 2012


On Fri, Aug 24, 2012 at 10:25 AM, A D <callidus.713 at gmail.com> wrote:
> Hello Everyone!
>
> Thus my former post didn't get any attention, I try a new one with preciser
> information. I would like to build up a small program, where a user could
> perform a filter (e.g. Threshold) on a slice (=2D image) from a 3D image.
> Now, I don't know how to solve this with ITK. I have used ExtractImageFilter
> to get a slice perform a filter and write it back into the volume with
> PasteImageFilterType but that doesn't work out.
> http://old.nabble.com/Can%27t-paste-Slice-back-into-3D-Volume-td34324209.html
> Then I tried Iterators, however with these I have to write my own filters,
> because I could manipulate on each pixels not on a hole 2D Image out of a 3D
> volume.
>
> If there exist an elegant way of doing this kind of task, please let me know
> as soon as possible.
>

I may be wrong however think you want m_size[plane] = 1; instead of
m_size[plane] = 0; in your code.

John


More information about the Insight-users mailing list