<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">
Hello,
<div class=""><br class="">
</div>
<div class="">The documentation for the sitk::Show method can be found here:</div>
<div class=""><a href="https://itk.org/SimpleITKDoxygen/html/namespaceitk_1_1simple.html#ac8416e6e7f02dedfe8373b83dbea411d" class="">https://itk.org/SimpleITKDoxygen/html/namespaceitk_1_1simple.html#ac8416e6e7f02dedfe8373b83dbea411d</a></div>
<div class=""><br class="">
</div>
<div class="">I suspect that you don’t have Fiji/ImageJ installed, or the method was not able to locate the executable. There are some environment variables that can be set to properly configure it.</div>
<div class=""><br class="">
</div>
<div class="">The Show method is designed to be a convenience method to launch an external viewer to display data. It is convenient to use in interactive environments such as python or R for a quick display.</div>
<div class=""><br class="">
</div>
<div class="">SimpleITK provides wrapping for a large number of languages include Python, R, Lua, Tcl, Ruby, Java and C#. Some languages have more examples then others. In general it’s not too hard to figure out how to translate an useful example from one language
to another.</div>
<div class=""><br class="">
</div>
<div class="">You can find a list of basic examples here:</div>
<div class=""><br class="">
</div>
<div class=""><a href="https://itk.org/SimpleITKDoxygen/html/examples.html" class="">https://itk.org/SimpleITKDoxygen/html/examples.html</a></div>
<div class=""><br class="">
</div>
<div class="">And may Python and R notebooks here:</div>
<div class=""><br class="">
</div>
<div class=""><a href="https://github.com/InsightSoftwareConsortium/SimpleITK-Notebooks" class="">https://github.com/InsightSoftwareConsortium/SimpleITK-Notebooks</a></div>
<div class=""><br class="">
</div>
<div class="">Hope that helps,</div>
<div class="">Brad</div>
<div class=""><br class="">
<div>
<blockquote type="cite" class="">
<div class="">On May 5, 2017, at 12:22 PM, an qin <<a href="mailto:anqin888@gmail.com" class="">anqin888@gmail.com</a>> wrote:</div>
<br class="Apple-interchange-newline">
<div class="">
<div dir="ltr" class="">
<div class=""><span style="font-family: 'times new roman'; font-size: inherit;" class="">Hi, I am new to C# simpleITK and can't find much sample codes. I tried to read dicom image and display them in simpleITK. The dicom image was read without a problem. But
got an exception when show. </span></div>
<div class=""><span style="font-family: 'times new roman'; font-size: inherit;" class=""><br class="">
</span></div>
<div class=""><span style="font-family: 'times new roman'; font-size: inherit;" class="">Any suggestion will be appreciated. </span></div>
<div class=""><span style="font-family: 'times new roman'; font-size: inherit;" class=""><br class="">
</span></div>
<div class=""><span style="font-family: 'times new roman'; font-size: inherit;" class="">Thanks.</span></div>
<div class=""><span style="font-family: 'times new roman'; font-size: inherit;" class="">Andy</span></div>
<div class=""><span style="font-family: 'times new roman'; font-size: inherit;" class=""><br class="">
</span></div>
<div class=""><span style="font-family: 'times new roman'; font-size: inherit;" class=""><br class="">
</span></div>
<div class=""><span style="font-family: 'times new roman'; font-size: inherit;" class="">//-------------code------------</span></div>
<div class="">
<div class=""><font face="times new roman" size="3" class="">using itk.simple;</font></div>
<div class=""><font face="times new roman" size="3" class=""><br class="">
</font></div>
<div class=""><font face="times new roman" size="3" class="">namespace TestReadDicom</font></div>
<div class=""><font face="times new roman" size="3" class="">{</font></div>
<div class=""><font face="times new roman" size="3" class=""> class Program</font></div>
<div class=""><font face="times new roman" size="3" class=""> {</font></div>
<div class=""><font face="times new roman" size="3" class=""> static void Main(string[] args)</font></div>
<div class=""><font face="times new roman" size="3" class=""> {</font></div>
<div class=""><font face="times new roman" size="3" class=""> var myreader = new ImageSeriesReader();</font></div>
<div class=""><font face="times new roman" size="3" class=""> var names = ImageSeriesReader.GetGDCMSeriesFileNames(@"E:\ImageSet_0.DICOM");</font></div>
<div class=""><font face="times new roman" size="3" class=""> myreader.SetFileNames(names);</font></div>
<div class=""><font face="times new roman" size="3" class=""> var image = myreader.Execute();</font></div>
<div class=""><font face="times new roman" size="3" class=""> VectorDouble imDim = image.GetOrigin();</font></div>
<div class=""><font face="times new roman" size="3" class=""> Console.WriteLine(imDim[0].ToString());</font></div>
<div class=""><font face="times new roman" size="3" class=""> SimpleITK.Show(image);</font></div>
<div class=""><span style="font-family: 'times new roman'; font-size: inherit;" class=""> }</span><br class="">
</div>
<div class=""><font face="times new roman" size="3" class=""> }</font></div>
<div class=""><font face="times new roman" size="3" class="">}</font></div>
</div>
<div class=""><font face="times new roman" size="3" class=""><br class="">
</font></div>
<div class=""><span style="font-family: 'times new roman'; font-size: inherit;" class="">//-------------output------------</span><font face="times new roman" size="3" class=""><br class="">
</font></div>
<div class=""><font face="times new roman" size="3" class=""></font>
<div class=""><font face="times new roman" size="3" class="">Additional information: Exception thrown in SimpleITK Show: ..\..\..\..\..\SimpleITK\Code\IO\src\sitkShow.cxx:500:</font></div>
<div class=""><font face="times new roman" size="3" class=""><br class="">
</font></div>
<div class=""><font face="times new roman" size="3" class="">sitk::ERROR: Error in administrating child process: [The parameter is incorrect</font></div>
</div>
</div>
_____________________________________<br class="">
Powered by <a href="http://www.kitware.com" class="">www.kitware.com</a><br class="">
<br class="">
Visit other Kitware open-source projects at<br class="">
<a href="http://www.kitware.com/opensource/opensource.html" class="">http://www.kitware.com/opensource/opensource.html</a><br class="">
<br class="">
Kitware offers ITK Training Courses, for more information visit:<br class="">
http://www.kitware.com/products/protraining.php<br class="">
<br class="">
Please keep messages on-topic and check the ITK FAQ at:<br class="">
http://www.itk.org/Wiki/ITK_FAQ<br class="">
<br class="">
Follow this link to subscribe/unsubscribe:<br class="">
http://public.kitware.com/mailman/listinfo/insight-users<br class="">
_______________________________________________<br class="">
Community mailing list<br class="">
Community@itk.org<br class="">
http://public.kitware.com/mailman/listinfo/community<br class="">
</div>
</blockquote>
</div>
<br class="">
</div>
</body>
</html>