1
1
cmake_minimum_required (VERSION 3.1 )
2
2
3
- set (PROJECT_NAME zed_driver )
3
+ set (PROJECT_NAME zed_open_capture )
4
4
5
5
project (${PROJECT_NAME} CXX )
6
6
@@ -68,10 +68,6 @@ include_directories(
68
68
69
69
list (INSERT CMAKE_MODULE_PATH 0 "${CMAKE_SOURCE_DIR} /cmake" )
70
70
71
-
72
-
73
-
74
-
75
71
############################################################################
76
72
# Generate libraries
77
73
if (BUILD_SENSORS )
@@ -126,11 +122,12 @@ if(BUILD_EXAMPLES)
126
122
if (BUILD_VIDEO )
127
123
message ("* Video example available" )
128
124
129
- ##### Video Example
125
+ ##### OpenCV is required
130
126
find_package (OpenCV REQUIRED )
131
127
include_directories (${OpenCV_INCLUDE_DIRS} )
132
128
133
- add_executable (${PROJECT_NAME} _video_example "examples/zed_drv_video_example.cpp" )
129
+ ##### Video Example
130
+ add_executable (${PROJECT_NAME} _video_example "${CMAKE_HOME_DIRECTORY} /examples/zed_oc_video_example.cpp" )
134
131
set_target_properties (${PROJECT_NAME} _video_example PROPERTIES PREFIX "" )
135
132
target_link_libraries (${PROJECT_NAME} _video_example
136
133
${PROJECT_NAME}
@@ -139,13 +136,25 @@ if(BUILD_EXAMPLES)
139
136
install (TARGETS ${PROJECT_NAME} _video_example
140
137
RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX} /bin
141
138
)
139
+
140
+ ##### Rectify Example
141
+ include_directories ( ${CMAKE_HOME_DIRECTORY} /examples/include )
142
+ add_executable (${PROJECT_NAME} _rectify_example "${CMAKE_HOME_DIRECTORY} /examples/zed_oc_rectify_example.cpp" )
143
+ set_target_properties (${PROJECT_NAME} _rectify_example PROPERTIES PREFIX "" )
144
+ target_link_libraries (${PROJECT_NAME} _rectify_example
145
+ ${PROJECT_NAME}
146
+ ${OpenCV_LIBS}
147
+ )
148
+ install (TARGETS ${PROJECT_NAME} _rectify_example
149
+ RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX} /bin
150
+ )
142
151
endif ()
143
152
144
153
if (BUILD_SENSORS )
145
154
message ("* Sensors example available" )
146
155
147
156
##### Sensors Example
148
- add_executable (${PROJECT_NAME} _sensors_example "examples/zed_drv_sensors_example .cpp" )
157
+ add_executable (${PROJECT_NAME} _sensors_example "${CMAKE_HOME_DIRECTORY} / examples/zed_oc_sensors_example .cpp" )
149
158
set_target_properties (${PROJECT_NAME} _sensors_example PROPERTIES PREFIX "" )
150
159
target_link_libraries (${PROJECT_NAME} _sensors_example
151
160
${PROJECT_NAME}
@@ -159,7 +168,7 @@ if(BUILD_EXAMPLES)
159
168
message ("* Video/Sensors sync example available" )
160
169
161
170
##### Synchronization Example
162
- add_executable (${PROJECT_NAME} _sync_example "examples/zed_drv_sync_example .cpp" )
171
+ add_executable (${PROJECT_NAME} _sync_example "${CMAKE_HOME_DIRECTORY} / examples/zed_oc_sync_example .cpp" )
163
172
set_target_properties (${PROJECT_NAME} _sync_example PROPERTIES PREFIX "" )
164
173
target_link_libraries (${PROJECT_NAME} _sync_example
165
174
${PROJECT_NAME}
0 commit comments