<div dir="ltr">Hi Simon,<div><br></div><div>Your solution works fine ! Thanks.</div><div><br></div><div>I just noticed something to be careful with : the function "CastImageToITK" (in $RTK_HOME/utilities/SimpleRTK/Code/BasicFilters/include/srtkImageFilter.h) does not accept NULL pointer (an error is returned) while the default value set in the JSON file seems to declare a (0,0) image whose pointer is NULL. As a consequence it is mandatory to set an image before executing the filter.</div><div><br></div><div>So if you plan, as this is in my case, to allow the filter not to do something if no image has been set, it will not work in SimpleRTK with this custom cast.</div><div><br></div><div>Fabien.</div></div><div class="gmail_extra"><br><div class="gmail_quote">2016-06-20 9:59 GMT+02:00 Fabien Momey <span dir="ltr"><<a href="mailto:fabien.momey@gmail.com" target="_blank">fabien.momey@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>Hi Simon,</div><div><br></div>Thanks for your help.<div><br></div><div>It seems to be what I need ! I will try this and tell you if it works.</div><span class="HOEnZb"><font color="#888888"><div><br></div><div>Fabien.</div></font></span></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">2016-06-17 18:46 GMT+02:00 Simon Rit <span dir="ltr"><<a href="mailto:simon.rit@creatis.insa-lyon.fr" target="_blank">simon.rit@creatis.insa-lyon.fr</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div>Hi Fabien,<br></div>I can't say I master this but I had to do something similar in <a href="https://github.com/SimonRit/RTK/blob/master/utilities/SimpleRTK/Code/BasicFilters/json/FieldOfViewImageFilter.json" target="_blank">FieldOfViewImageFilter.json</a>. Look at the "ProjectionsStack" parameter which is actually a 3D image. How did I come up with such a complicated code? No clue, but SimpleITK has similar ugly json files, e.g., <a href="https://github.com/SimpleITK/SimpleITK/blob/master/Code/BasicFilters/json/LabelMapContourOverlayImageFilter.json" target="_blank">LabelMapContourOverlayImageFilter.json</a>. My guess is that passing an image as a parameters in an itk image filter is not so common...<br></div>I hope this helps,<br></div>Simon<br></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div>On Fri, Jun 17, 2016 at 11:07 AM, Fabien Momey <span dir="ltr"><<a href="mailto:fabien.momey@gmail.com" target="_blank">fabien.momey@gmail.com</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div><div dir="ltr"><div>Hi everyone,</div><div><br></div><div>I need some help for updating a JSON file for the ConjugateGradientConeBeamReconstructionFilter.</div><div><br></div><div>I want to test a new implementation I made on this filter to perform a support constraint for the reconstructed image.</div><div><br></div><div>The constraint consists in a binary mask passed as an attribute. This attribute is a pointer to an image of type TOutputImage. The default value (in the constructor) is NULL.</div><div><br></div><div>I don't know how to write it in the JSON file to wrap this member :</div><div><br></div><div> {</div><div>      "name" : "SupportMask",</div><div>      "type" : ?,</div><div>      "default" : ?,</div><div>      "briefdescriptionSet" : "",</div><div>      "detaileddescriptionSet" : "",</div><div>      "briefdescriptionGet" : "",</div><div>      "detaileddescriptionGet" : ""</div><div>   }</div><div><br></div><div>Does it also need to perform a specific cast with the optional field custom_itk_cast ? I don't really understand how it works.</div><div><br></div><div>Thanks in advance for your help.</div></div>
<br></div></div>_______________________________________________<br>
Rtk-users mailing list<br>
<a href="mailto:Rtk-users@public.kitware.com" target="_blank">Rtk-users@public.kitware.com</a><br>
<a href="http://public.kitware.com/mailman/listinfo/rtk-users" rel="noreferrer" target="_blank">http://public.kitware.com/mailman/listinfo/rtk-users</a><br>
<br></blockquote></div><br></div>
</blockquote></div><br></div>
</div></div></blockquote></div><br></div>