[ITK] [ITK-users] Create ITK Project with CUDA from CMake
D'Isidoro Fabio
fisidoro at ethz.ch
Tue Mar 21 13:49:23 EDT 2017
Hallo,
I have a .cu CUDA main code which makes use of itk to read and write images.
How can I create a new ITK project with Cmake that include CUDA? I could not find any tutorial/description on it. Since I am not familiar with Cmake, I would need an understandable and detailed description.
The most basic CmakeLists.txt I could find does not work:
------------------------------
project(CUDAitk)
find_package(ITK REQUIRED)
include(${ITK_USE_FILE})
find_package(CUDA REQUIRED)
CUDA_INCLUDE_DIRECTORIES(${ITK_INCLUDE_DIRS})
cuda_add_executable(CUDAitk CUDAitk.cu)
target_link_libraries(CUDAitk ${ITK_LIBRARIES})
------------------------------
The compling errors I get are like:
error C2244: 'itk::FixedArray<TValue,VLength>::FixedArray': unable to match function definition to an existing declaration
CMake Error at CUDAitk_generated_CUDAitk.cu.obj.Debug.cmake:267 (message):
Error generating file
C:/Users/Fabio/Documents/CUDAitk_cpp2/bin/CMakeFiles/CUDAitk.dir//Debug/CUDAitk_generated_CUDAitk.cu.obj
Any help is highly appreciated.
Thank you!
Fabio
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/community/attachments/20170321/6b0a3be3/attachment.html>
-------------- next part --------------
_____________________________________
Powered by www.kitware.com
Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html
Kitware offers ITK Training Courses, for more information visit:
http://www.kitware.com/products/protraining.php
Please keep messages on-topic and check the ITK FAQ at:
http://www.itk.org/Wiki/ITK_FAQ
Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/insight-users
More information about the Community
mailing list