SnAP is distributed as a part of the ITK Applications installation. In order to build SNAP on a UNIX or Linux platform, the one must install ITK, VTK and FLTK on their system. This document will guide you through that process.
The following software must be installed on your system:
Create the following directory structure, which is recommended and will be assumed in this document.Replace the directory basedir with your own directory name, i.e., /home/myuserid/tk. Experienced users can change the names and order of the subdirectories to their preference.
basedir/ basedir/app // Base directory for ITK applications basedir/app/bingcc // ITK Applications binary directory basedir/itk // Base directory for ITK basedir/itk/bingcc // ITK binary directory basedir/vtk // Base directory for VTK basedir/vtk/bingcc // VTK binary directory basedir/fltk // FLTK directory
We will use CVS to download ITK. For more instructions, please refer to the ITK Software Guide located at www.itk.org
These instructions recommend that you download the release 1.4 of ITK. To use the latest version of ITK (at your own risk), remove the -r option in the cvs commands below.
cvs -d :pserver:anonymous@www.itk.org:/cvsroot/Insight login (respond with password insight) cvs -d :pserver:anonymous@www.itk.org:/cvsroot/Insight co Insight
ccmake ../Insight
BUILD_EXAMPLES = OFF BUILD_TESTING = OFF CMAKE_BUILD_TYPE = Release
make
At this point, you will have a working installation of ITK on your system. Please refer to ITK documentation for troubleshooting information.
VTK installation is similar to the installation of ITK.
These instructions recommend that you download the release 4.2 of VTK. To use the latest version of ITK (at your own risk), remove the -r option in the cvs commands below.
cvs -d :pserver:anonymous@public.kitware.com:/cvsroot/VTK login (respond with password vtk) cvs -d :pserver:anonymous@public.kitware.com:/cvsroot/VTK co -r LatestRelease VTK
ccmake ../VTK
BUILD_EXAMPLES = OFF BUILD_TESTING = OFF CMAKE_BUILD_TYPE = Release VTK_USE_HYBRID = ON VTK_USE_PARALLEL= ON VTK_USE_RENDERING= ON
VTK_USE_ANSI_STDLIB = ON VTK_USE_SYSTEM_PNG = ON VTK_USE_SYSTEM_JPEG = ON
make
At this point, you will have a working installation of ITK and VTK on your system. Please refer to VTK documentation (at www.vtk.org) for troubleshooting information.
FLTK is a multiplatform GUI toolkit. SnAP has been developed and tested using version 1.1.2 of FLTK, but later 1.1.* versions should work as well. In all the following commands, replace the * character with the correct version number, the current version is 1.1.4
tar -xzvf fltk-1.1.*-source.tar.gz
./configure make make fluid
At this point, you will have a working installation of FLTK on your system. Please refer to FLTK documentation (at www.fltk.org) for troubleshooting information.
We will use CVS to download ITK Applications, including SNAP. For more instructions, please refer to the ITK Software Guide located at www.itk.org
cvs -d :pserver:anonymous@www.itk.org:/cvsroot/Insight login (respond with password insight) cvs -d :pserver:anonymous@www.itk.org:/cvsroot/Insight co InsightApplications
ccmake ../InsightApplications
BUILD_EXAMPLES = OFF BUILD_TESTING = OFF CMAKE_BUILD_TYPE = Release ITK_DIR = basedir/itk/bingcc USE_VTK = ON USE_FLTK = ON
VTK_DIR = basedir/vtk/bingcc FLTK_BASE_LIBRARY = basedir/fltk/fltk-1.1.* FLTK_FLUID_EXECUTABLE = basedir/fltk/fltk-1.1.*/fluid/fluid
make
At this point, you will have a working installation of ITK InsightApplications on your system. Please refer to ITK documentation for troubleshooting information.
./SNAP
For troubleshooting the installation of ITK, VTK, FLTK and InsightApplications, please refer to the corresponding web sites noted above
We recommend that you join the ITK users mailing list, where you can find answers to questions posed by other users as well as post your own questions.