<HTML><HEAD></HEAD>
<BODY dir=ltr>
<DIV dir=ltr>
<DIV style="FONT-SIZE: 12pt; FONT-FAMILY: 'Calibri'; COLOR: #000000">
<DIV>Hi Simon,</DIV>
<DIV> </DIV>
<DIV>Yes, it solved the problem.</DIV>
<DIV>There are some more related questions. Filters like backprojectionFilter
have more than one input. As it is an InPlaceFilter, it will overwrite the
input. But which input will be updated? From the existing filters, it seems it
is the input( 0 ). Is this defined somewhere? Can I change this? If I query the
buffer of input(1), will I get the correct address?</DIV>
<DIV>Another one: if I pass an ITK image pointer to a function instead of
defining this image as an input, will I run into the same problem? Does it have
an impact on speed and ram consumption?</DIV>
<DIV>Thank you!</DIV>
<DIV> </DIV>
<DIV>Best regards,</DIV>
<DIV>Louie</DIV>
<DIV
style="FONT-SIZE: small; FONT-FAMILY: 'Calibri'; FONT-WEIGHT: normal; COLOR: #000000; FONT-STYLE: normal; TEXT-DECORATION: none; DISPLAY: inline">
<DIV style="FONT: 10pt tahoma">
<DIV> </DIV>
<DIV style="BACKGROUND: #f5f5f5">
<DIV style="font-color: black"><B>From:</B> <A
title=simon.rit@creatis.insa-lyon.fr
href="mailto:simon.rit@creatis.insa-lyon.fr">Simon Rit</A> </DIV>
<DIV><B>Sent:</B> Wednesday, December 03, 2014 9:31 AM</DIV>
<DIV><B>To:</B> <A title=ghostcz@hotmail.com
href="mailto:ghostcz@hotmail.com">louie L</A> </DIV>
<DIV><B>Cc:</B> <A title=rtk-users@public.kitware.com
href="mailto:rtk-users@public.kitware.com">rtk-users@public.kitware.com</A>
</DIV>
<DIV><B>Subject:</B> Re: [Rtk-users] Input and output image
buffer</DIV></DIV></DIV>
<DIV> </DIV></DIV>
<DIV
style="FONT-SIZE: small; FONT-FAMILY: 'Calibri'; FONT-WEIGHT: normal; COLOR: #000000; FONT-STYLE: normal; TEXT-DECORATION: none; DISPLAY: inline">
<DIV dir=ltr>
<DIV>
<DIV>Hi Louie,<BR></DIV>What you do is correct and what you obtain is expected.
BackProjectionImageFilter inherits from InPlaceImageFilter. InPlaceImageFilter
overwrites the input by default. If you don't want this behavior, you can simply
call <A
href="http://www.itk.org/Doxygen/html/classitk_1_1InPlaceImageFilter.html#a8d759f2bdeaf360a54524d87c5fc4d14">InPlaceOff</A>
before updating. Then , the buffers will be indeed pointing to different memory
spaces.<BR></DIV>Hope this helps,<BR>Simon<BR></DIV>
<DIV class=gmail_extra>
<DIV> </DIV>
<DIV class=gmail_quote>On Tue, Dec 2, 2014 at 10:21 PM, louie L <SPAN
dir=ltr><<A href="mailto:ghostcz@hotmail.com"
target=_blank>ghostcz@hotmail.com</A>></SPAN> wrote:<BR>
<BLOCKQUOTE class=gmail_quote
style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">Dear
RTK users and developers,<BR><BR>I am writing a backprojection filter whose
superclass is ImageToImageFilter. After allocating the output, I
called<BR>this->GetInput()->GetBufferPointer()
and<BR>this->GetOutput()->GetBufferPointer().<BR>to get the address of
the images in memory. However the two functions above return the same value.
Why? If this is not the correct way to get the address of the input image, how
can I get that address?<BR>Thank you.<BR><BR>Best
regards,<BR>Louie<BR><BR><BR>_______________________________________________<BR>Rtk-users
mailing list<BR><A
href="mailto:Rtk-users@public.kitware.com">Rtk-users@public.kitware.com</A><BR><A
href="http://public.kitware.com/mailman/listinfo/rtk-users"
target=_blank>http://public.kitware.com/mailman/listinfo/rtk-users</A><BR></BLOCKQUOTE></DIV>
<DIV> </DIV></DIV></DIV></DIV></DIV></BODY></HTML>