<div>I managed to build the insightapplications, and i now want to be able to use them just as easy as i can use the VTK and ITK. But i cannot seem to figure out how to make the CMakeLists.txt so that i can also include the whole Insightapplications, like it is done with ITK and VTK.
</div>
<div>My CMakeLists.txt looks like this now</div>
<div>&nbsp;</div>
<div>
<p>PROJECT(Hello)</p>
<p>FIND_PACKAGE(ITK)<br>IF (ITK_FOUND)<br>&nbsp;INCLUDE(${USE_ITK_FILE})<br>ENDIF(ITK_FOUND)</p>
<p>FIND_PACKAGE(VTK)<br>IF(VTK_FOUND)<br>&nbsp;INCLUDE( ${USE_VTK_FILE} )<br>ENDIF(VTK_FOUND)</p>
<p>INCLUDE_DIRECTORIES(<br>&nbsp;${Hello_SOURCE_DIR}<br>)<br>ADD_EXECUTABLE(Hello main.cxx) <br>TARGET_LINK_LIBRARIES (Hello <br>&nbsp;ITKBasicFilters ITKCommon ITKIO <br>&nbsp;vtkRendering vtkGraphics vtkHybrid <br>&nbsp;vtkImaging vtkIO vtkFiltering vtkCommon
<br>&nbsp;)</p></div>
<div><br>So i think somehow i need to make a INSIGHT package as well like ITK and VTK. But how is this done? </div>
<div>&nbsp;</div>
<div>Many regards</div>
<div>&nbsp;</div>
<div><span class="gmail_quote">2006/9/27, Kevin H. Hobbs &lt;<a href="mailto:hobbsk@ohiou.edu">hobbsk@ohiou.edu</a>&gt;:</span>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">On Wed, 2006-09-27 at 10:19 +0200, Prename Surname wrote:<br>&gt;<br>&gt; So i found out that i need the insightapplications in order to get
<br>&gt; these h-files.<br>&gt;<br>&gt; I then downloaded insightapplications and wantd to install. Now i then<br>&gt; find out that i need some FLTK library and q2 library also.<br>&gt;<br><br>You shouldn't need to build ALL of insight applications, and maybe you
<br>don't need to build any of it. *.txx aren't compiled until you compile<br>your program so I think you should be able to just copy the header and<br>template to your project directory and build them there.<br><br>There's also InsightApplications/vtkITK/Common/vtkITKUtility.h that does
<br>almost the same thing but in a single header file you can just include.<br>You can just copy it or add it to the include path in your<br>CMakeLists.txt with :<br><br>INCLUDE_DIRECTORIES(<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ${series_SOURCE_DIR}
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ${WHEREVER_THE_HECK_YOU_PUT}/InsightApplications/vtkITK/Common<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; )<br><br>You use it with :<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // VTK Image Reader<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; vtkXMLImageDataReader * reader<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = vtkXMLImageDataReader::New();
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; reader-&gt;SetFileName( input_image_file );<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // VTK Export<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; vtkImageExport * vtk_export = vtkImageExport::New();<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; vtk_export-&gt;SetInputConnection( reader-&gt;GetOutputPort() );<br>
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // ITK Import<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; typedef itk::VTKImageImport&lt; FloatImageType &gt; ITKImportType;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ITKImportType::Pointer itk_import = ITKImportType::New();<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ConnectPipelines( vtk_export, itk_import );
<br><br><br></blockquote></div><br>