Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
D
dlib
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
钟尚武
dlib
Commits
ea20f5e2
Commit
ea20f5e2
authored
Oct 02, 2016
by
Xi Deng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
skip examples which need GUI when DLIB_NO_GUI_SUPPORT is defined
parent
2ed907aa
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
39 additions
and
26 deletions
+39
-26
CMakeLists.txt
examples/CMakeLists.txt
+39
-26
No files found.
examples/CMakeLists.txt
View file @
ea20f5e2
...
...
@@ -29,22 +29,31 @@ MACRO(add_example name)
TARGET_LINK_LIBRARIES
(
${
name
}
dlib
)
ENDMACRO
()
# if an example requires GUI, call this macro to check DLIB_NO_GUI_SUPPORT to include or exclude
MACRO
(
add_gui_example name
)
if
(
DLIB_NO_GUI_SUPPORT
)
message
(
"No GUI support, so we won't build the
${
name
}
example."
)
else
()
add_example
(
${
name
}
)
endif
()
ENDMACRO
()
# The deep learning toolkit requires a C++11 capable compiler.
if
(
COMPILER_CAN_DO_CPP_11
)
add_example
(
dnn_introduction_ex
)
add_example
(
dnn_introduction2_ex
)
add_example
(
dnn_inception_ex
)
add_example
(
dnn_imagenet_ex
)
add_
gui_
example
(
dnn_imagenet_ex
)
add_example
(
dnn_imagenet_train_ex
)
add_example
(
dnn_mmod_ex
)
add_example
(
random_cropper_ex
)
add_
gui_
example
(
dnn_mmod_ex
)
add_
gui_
example
(
random_cropper_ex
)
endif
()
#here we apply our macros
add_example
(
3d_point_cloud_ex
)
add_
gui_
example
(
3d_point_cloud_ex
)
add_example
(
bayes_net_ex
)
add_example
(
bayes_net_from_disk_ex
)
add_example
(
bayes_net_gui_ex
)
add_
gui_
example
(
bayes_net_gui_ex
)
add_example
(
bridge_ex
)
add_example
(
bsp_ex
)
add_example
(
compress_stream_ex
)
...
...
@@ -52,15 +61,15 @@ add_example(config_reader_ex)
add_example
(
custom_trainer_ex
)
add_example
(
dir_nav_ex
)
add_example
(
empirical_kernel_map_ex
)
add_example
(
face_detection_ex
)
add_example
(
face_landmark_detection_ex
)
add_example
(
fhog_ex
)
add_example
(
fhog_object_detector_ex
)
add_
gui_
example
(
face_detection_ex
)
add_
gui_
example
(
face_landmark_detection_ex
)
add_
gui_
example
(
fhog_ex
)
add_
gui_
example
(
fhog_object_detector_ex
)
add_example
(
file_to_code_ex
)
add_example
(
graph_labeling_ex
)
add_example
(
gui_api_ex
)
add_example
(
hough_transform_ex
)
add_example
(
image_ex
)
add_
gui_
example
(
gui_api_ex
)
add_
gui_
example
(
hough_transform_ex
)
add_
gui_
example
(
image_ex
)
add_example
(
integrate_function_adapt_simp_ex
)
add_example
(
iosockstream_ex
)
add_example
(
kcentroid_ex
)
...
...
@@ -81,12 +90,12 @@ add_example(max_cost_assignment_ex)
add_example
(
member_function_pointer_ex
)
add_example
(
mlp_ex
)
add_example
(
model_selection_ex
)
add_example
(
mpc_ex
)
add_
gui_
example
(
mpc_ex
)
add_example
(
multiclass_classification_ex
)
add_example
(
multithreaded_object_ex
)
add_example
(
object_detector_advanced_ex
)
add_example
(
object_detector_ex
)
add_example
(
one_class_classifiers_ex
)
add_
gui_
example
(
object_detector_advanced_ex
)
add_
gui_
example
(
object_detector_ex
)
add_
gui_
example
(
one_class_classifiers_ex
)
add_example
(
optimization_ex
)
add_example
(
parallel_for_ex
)
add_example
(
pipe_ex
)
...
...
@@ -104,7 +113,7 @@ add_example(server_iostream_ex)
add_example
(
sockets_ex
)
add_example
(
sockstreambuf_ex
)
add_example
(
std_allocator_ex
)
add_example
(
surf_ex
)
add_
gui_
example
(
surf_ex
)
add_example
(
svm_c_ex
)
add_example
(
svm_ex
)
add_example
(
svm_pegasos_ex
)
...
...
@@ -117,21 +126,25 @@ add_example(thread_pool_ex)
add_example
(
threaded_object_ex
)
add_example
(
threads_ex
)
add_example
(
timer_ex
)
add_example
(
train_object_detector
)
add_
gui_
example
(
train_object_detector
)
add_example
(
train_shape_predictor_ex
)
add_example
(
using_custom_kernels_ex
)
add_example
(
video_tracking_ex
)
add_
gui_
example
(
video_tracking_ex
)
add_example
(
xml_parser_ex
)
find_package
(
OpenCV QUIET
)
if
(
OpenCV_FOUND
)
include_directories
(
${
OpenCV_INCLUDE_DIRS
}
)
ADD_EXECUTABLE
(
webcam_face_pose_ex webcam_face_pose_ex.cpp
)
TARGET_LINK_LIBRARIES
(
webcam_face_pose_ex dlib
${
OpenCV_LIBS
}
)
if
(
DLIB_NO_GUI_SUPPORT
)
message
(
"No GUI support, so we won't build the webcam_face_pose_ex example."
)
else
()
message
(
"OpenCV not found, so we won't build the webcam_face_pose_ex example."
)
find_package
(
OpenCV QUIET
)
if
(
OpenCV_FOUND
)
include_directories
(
${
OpenCV_INCLUDE_DIRS
}
)
ADD_EXECUTABLE
(
webcam_face_pose_ex webcam_face_pose_ex.cpp
)
TARGET_LINK_LIBRARIES
(
webcam_face_pose_ex dlib
${
OpenCV_LIBS
}
)
else
()
message
(
"OpenCV not found, so we won't build the webcam_face_pose_ex example."
)
endif
()
endif
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment