This compilation is tested with MSVC 2015. It is recommended to build toolchains from sources for better version compatibility.
Please install the following packages.
- Git for Windows
- MSVC 2015 (Windows)
- G++ (Ubuntu
sudo apt install build-essential
) - CMake
- VTK (Mandatory when VMTK super build is not implemented)
- ITK (Mandatory when VMTK super build is not implemented)
- Qt
- VMTK
Please following the build instructions from each package. If you have any difficulty in building the library, please don't hesitate to contact me.
- Create an empty folder anywhere in the computer, e.g.
D:/projects
- Open Git Bash and move working directory to
D:/project
- Type
git clone https://github.com/jackyko1991/Vessel-Centerline-Extraction
on Git Bash - Create an empty folder
D:/projects/Vessel-Centerline-Extraction/build
- Open CMake GUI
- Press
Browse Source
and direct toD:/projects/Vessel-Centerline-Extraction
- Press
Browse Build
and direct toD:/projects/Vessel-Centerline-Extraction/build
- Press
Configure
and chooseVisual Studio 14 2015 Win64
(Windows) orUnix Makefiles
(Ubuntu) - Error comes out when configuring VMTK, change the
VMTK_DIR
variable to the folder containingFindVMTK.cmake
, usaually atD:/VMTK/build/VMTK-Build
. The system should auto configure VTK paths. - If VTK is not found , provide the variable
VTK_DIR
to the folder containingFindVMTK.cmake
- Press
Generate
- Build steps differ from Windows and Linux at this point
- Windows Build
- Press
Open
and change solution build type toRelease
- Press
F7
to compile - Copy the necessary dlls to
D:\projects\Vessel-Centerline-Extraction\build\Release
upon system request. The dlls may found in VTK, VMTK and Qt binary directory
- Press
- Ubuntu Build
- On terminal, move working directory to
/<projects>/Vessel-Centerline-Extraction/build
, where/<projects>
is the directory containing the source make
- On terminal, move working directory to
- Windows Build
- Run the test script
./CenterlineExtraction <surface.stl> <capped_surface.stl> <centerline.vtp>
, replace lines in<>
to the actual path of containing the associated files. Sample data can be found fromVessel-Centerline-Extraction/test_data