

See the section above for additional details on these variables. If you do not specify one of these packages, then the vtkDICOMReader will only be able to read uncompressed files.

The USE_DCMTK and USE_GDCM variables allow you to add the image decompression capabilities of either of these packages (do not specify both!) to the vtkDICOMReader. Optionally, the following cmake variables can be set with ccmake or cmake-gui: BUILD_EXAMPLES ON $ cmake -D CMAKE_BUILD_TYPE:STRING=Release. $ export VTK_DIR=/Volumes/HD2/vtk-release-build/ $ # specify the directory where you built VTK, this is an example This example is for building the package on Linux or OS X in the bash shell. The following procedure can be used to build the vtkDICOM library, assuming that you have already built VTK with CMake. Note that the default DCMTK build does not provide JPEG2000 support, though it can be purchased as an add-on. USE_DCMTK can be enabled if you cannot use GDCM, but still require the ability to read compressed files. With this option, it is not necessary to build GDCM separately. The USE_ITK_GDCM option can be used as an alternative to USE_GDCM if you are building a program that uses ITK. This requires downloading GDCM from its project website. It is highly recommended that you turn the USE_GDCM option ON, otherwise vtk-dicom will not be able to read compressed dicom files. To enable vtk-dicom in a VTK 9 build, set this cmake cache variable: VTK_MODULE_ENABLE_VTK_vtkDICOM:STRING=WANTįor VTK 7 or 8, use the following cmake cache variable instead: Module_vtkDICOM:BOOL=ONĪfter running cmake once, the following new options will become available: BUILD_DICOM_PROGRAMS:BOOL=ON

PYTHON VTK INSTALL CMAKE CODE
This will cause cmake to automatically download the vtk-dicom source code from Github and build it as part of the VTK build. If are building VTK yourself, then vtk-dicom can be enabled as a VTK remote module. The different ways to install the package.
