-
Notifications
You must be signed in to change notification settings - Fork 26
/
CMakeLists.txt
137 lines (112 loc) · 3.52 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
cmake_minimum_required(VERSION 2.8 FATAL_ERROR)
project(SceneNetv1.0)
SET(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${PROJECT_SOURCE_DIR}/CMakeModules/")
SET(CMAKE_CXX_FLAGS "-std=c++11")
FIND_PACKAGE(CUDA REQUIRED)
find_package(PkgConfig REQUIRED)
find_package(Eigen3 REQUIRED)
find_package(OpenGL REQUIRED)
find_package(GLUT REQUIRED)
find_package(Pangolin REQUIRED)
find_package(CVD REQUIRED)
find_package(MinimalImgUtilities REQUIRED)
find_package(OpenMP)
find_package(Boost COMPONENTS thread REQUIRED)
find_package(OpenCV REQUIRED)
find_package(OpenCV2 REQUIRED)
find_package(SceneGraph REQUIRED)
if (OPENMP_FOUND)
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${OpenMP_C_FLAGS}")
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${OpenMP_CXX_FLAGS}")
endif()
# Adapt it accordingly
SET(CUDA_NVCC_FLAGS "-arch=sm_30" "--use_fast_math" "-O3" "-lineinfo")
#FIND_PATH(CUDA_CUT_INCLUDE_DIR
# cutil.h
# PATHS ${CUDA_SDK_SEARCH_PATH}
# PATH_SUFFIXES "common/inc"
# DOC "Location of cutil.h"
# NO_DEFAULT_PATH
#)
#message("CUDA_SDK_SEARCH_PATH = ${CUDA_SDK_SEARCH_PATH}")
link_directories( ${GTKMM_LIBRARY_DIRS})
include_directories( ${GTKMM_INCLUDE_DIRS})
INCLUDE_DIRECTORIES(
${Pangolin_INCLUDE_DIR}
${CG_INCLUDE_PATH}
${EIGEN3_INCLUDE_DIR}
${CVD_INCLUDE_DIR}
${OPENGL_INCLUDE_DIR}
${MinimalImgUtilities_INCLUDE_DIR}
${OpenCV2_INCLUDE_PATH}
${OPENCV_INCLUDE_DIRS}
${CUDA_INCLUDE_DIRS}
${SceneGraph_INCLUDE_DIRS}
/usr/lib/x86_64-linux-gnu/glibmm-2.4/include/
/usr/include/glib-2.0/
/usr/lib/x86_64-linux-gnu/glib-2.0/include/
/usr/include/glibmm-2.4
)
LINK_LIBRARIES(
${Pangolin_LIBRARY}
${Eigen3_LIBRARY}
${CVD_LIBRARY}
${OpenCV_LIBS}
${MinimalImgUtilities_LIBRARY}
${SceneGraph_LIBRARIES}
-lGLEW
-lglut
-lGLU
-lGL
-lboost_system
-lboost_filesystem
-lnoise
)
LINK_DIRECTORIES(
${OPENCV_LIBRARY_DIRS}
${SceneGraph_LIBRARY_DIRS}
/usr/local/lib
/usr/local/lib64
)
SET(TINYOBJLOADER_SOURCES
./utils/map_object_label2training_label.h
./tinyobjloader/tiny_obj_loader.h
./tinyobjloader/tiny_obj_loader.cc
./tinyobjloader/obj_writer.h
./tinyobjloader/obj_writer.cc
)
SET(VaFRIC_SOURCES
./VaFRIC/VaFRIC.h
./VaFRIC/VaFRIC.cpp)
SET(NOISE_SOURCES
./utils/noise/noise.h
./utils/noise/gaussian.h
./utils/noise/noiseutils.h
./utils/noise/noiseutils.cpp
./utils/noise/perlin.h
./utils/noise/add_kinect_noise.h
./utils/noise/add_kinect_noise.cu)
SET(MATH_SOURCES
./math/aux_math.h
./math/aux_math.cu
./math/cumath.h
./math/cumath.cu
./math/MatUtils.h)
CUDA_ADD_EXECUTABLE(add_kinect_noise
${NOISE_SOURCES}
${MATH_SOURCES}
main_add_kinect_noise.cpp)
ADD_EXECUTABLE(opengl_depth_rendering
${VaFRIC_SOURCES}
${SHADERS_SOURCES}
${TINYOBJLOADER_SOURCES}
main_depth_and_labels.cpp)
ADD_EXECUTABLE(living_room_rendering
${VaFRIC_SOURCES}
${SHADERS_SOURCES}
${TINYOBJLOADER_SOURCES}
main_living_room_dynamic.cpp)
ADD_EXECUTABLE(opengl_rgbd_rendering
main_rgbd_and_labels.cpp)
ADD_EXECUTABLE(automate_add_texture
main_automate_add_texture.cpp)