[Insight-users] Problem with passing images to functions

habibbaluwala2010 habibbaluwala at gmail.com
Mon Aug 9 15:42:12 EDT 2010


Hello Sergio, 
                 Can you give me an example of how to use this in context
with the syntax? I am really thankful for the help.  


Kind regards, 

Habib Baluwala




Sergio Vera wrote:
> 
> Following advices from Luis Ibañez in a previous mail of the list, we now
> use the following rules:
> 
> const ITKImgType *ImgIn  when images are input to a method and
> 
> ITKImgType::Pointer &ImgOut  when the image will be created inside the
> function
> 
> regards
> 
> 2010/8/6 Dženan Zukić <dzenanz at gmail.com>
> 
>> Use ImageType::Pointer. Here is an example:
>>
>> void calc2DJointHistogram(VisualizingImageType::Pointer x,
>> VisualizingImageType::Pointer y, std::string savefilename)
>> {
>> ...
>> }
>>
>> //calling it
>> VisualizingImageType::Pointer lVis, hVis;
>> ...
>> hVis=hReader->GetOutput();
>> calc2DJointHistogram(lVis, hVis, fnNoExt+"_LH.png");
>>
>> Dženan
>>
>> On Fri, Aug 6, 2010 at 15:32, habibbaluwala2010
>> <habibbaluwala at gmail.com>wrote:
>>
>>>
>>> Hi Everyone,
>>>                 I am a biot confused on how can i pass an image with
>>> smart
>>> pointers to an outside function . I basically need this to avoid
>>> reproducing
>>> the code again and again and also to avoid composite filters. It would
>>> be
>>> very helpful if you can provide an example which does the job!!! Anyways
>>> looking forward to your replies.
>>> --
>>> View this message in context:
>>> http://old.nabble.com/Problem-with-passing-images-to-functions-tp29356451p29356451.html
>>> Sent from the ITK - 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
>>>
>>> Kitware offers ITK Training Courses, for more information visit:
>>> http://www.kitware.com/products/protraining.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
>>>
>>
>>
>> _____________________________________
>> Powered by www.kitware.com
>>
>> Visit other Kitware open-source projects at
>> http://www.kitware.com/opensource/opensource.html
>>
>> Kitware offers ITK Training Courses, for more information visit:
>> http://www.kitware.com/products/protraining.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
>>
>>
> 
> 
> -- 
> Sergio Vera
> 
>  Alma IT Systems
>  C/ Vilana, 4B, 4º 1ª
>  08022 Barcelona
>  T. (+34) 932 380 592
>  www.alma3d.com
> 
> _____________________________________
> Powered by www.kitware.com
> 
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
> 
> Kitware offers ITK Training Courses, for more information visit:
> http://www.kitware.com/products/protraining.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
> 
> 

-- 
View this message in context: http://old.nabble.com/Problem-with-passing-images-to-functions-tp29356451p29391440.html
Sent from the ITK - Users mailing list archive at Nabble.com.



More information about the Insight-users mailing list