From KitwarePublic
Jump to: navigation, search

Install and run VTK on Linux

This install preocedure was tested on a system using SuSE Linux 10.0.
Download required files:


Install CMake
cmake .
make install
Install VTK

Uncompress the downloaded file to a directory of your choice (such as home/username/vtk)

To use vtk classes, a vtk application requires a makelist created using CMake. To create the CMakeLists.txt file see the CMake website. With the CMakeLists.txt file in the same directory as your applications source code, run CMake:

In a terminal window, change directory to your source code directory. Type ccmake . to run CMake Setup:

3DWidgets install 01.png

Check the cmake settings such as output and vtk directories and an executable output directory. Press “c” to configure, then “g” to generate cmakefiles. Press “q” to exit CMake Setup.

Type cmake .

3DWidgets install 02.png

Type make

3DWidgets install 03.png

With the example code compiled, change directory to that of the output (in this example it is /home/username/programs/output as shown in the CMake Setup).

To run the compiled code, type ./TestBoxWidget and press Enter.

3DWidgets install 04.png

The test application is launched:

3DWidgets install 05.png

KWWidgets: [Welcome | Site Map]