opencv 3.0 compilation (replace #1714)
authorAnatoly Baksheev <no@email>
Sun, 18 Jan 2015 19:55:26 +0000 (22:55 +0300)
committerEvan Shelhamer <shelhamer@imaginarynumber.net>
Tue, 17 Feb 2015 04:48:22 +0000 (20:48 -0800)
cmake/lint.cmake
src/caffe/layers/window_data_layer.cpp

index 04df340..585babb 100644 (file)
@@ -1,10 +1,12 @@
 
-set(CMAKE_SOURCE_DIR ../)
+set(CMAKE_SOURCE_DIR ..)
 set(LINT_COMMAND ${CMAKE_SOURCE_DIR}/scripts/cpp_lint.py)
 set(SRC_FILE_EXTENSIONS h hpp hu c cpp cu cc)
 set(EXCLUDE_FILE_EXTENSTIONS pb.h pb.cc)
 set(LINT_DIRS include src/caffe examples tools python matlab)
 
+cmake_policy(SET CMP0009 NEW)  # supress cmake warning
+
 # find all files of interest
 foreach(ext ${SRC_FILE_EXTENSIONS})
     foreach(dir ${LINT_DIRS})
index 23ec83d..3e9e976 100644 (file)
@@ -1,3 +1,4 @@
+#include <opencv2/highgui/highgui_c.h>
 #include <stdint.h>
 
 #include <algorithm>
 //   'source' field specifies the window_file
 //   'crop_size' indicates the desired warped size
 
-#if CV_VERSION_MAJOR == 3
-const int CV_LOAD_IMAGE_COLOR = cv::IMREAD_COLOR;
-#endif
-
 namespace caffe {
 
 template <typename Dtype>