Quantcast
Channel: OpenCV Q&A Forum - Latest question feed
Viewing all 19555 articles
Browse latest View live

Opencv Java MatOfFloat4 object cannot be created via constructor

$
0
0
I've a class which has the following variable: private MatOfFloat4 horizonLine = new MatOfFloat4(); which I later on pass into a function as follows: Imgproc.fitLine(tmpPoints, horizonLine, Imgproc.CV_DIST_L1, 0, 0.01, 0.01); However, I get an error saying that: Exception in thread "main" java.lang.UnsatisfiedLinkError: org.opencv.core.Mat.n_Mat()J at org.opencv.core.Mat.n_Mat(Native Method) at org.opencv.core.Mat.(Mat.java:24) at org.opencv.core.MatOfFloat4.(MatOfFloat4.java:12) at obstacleDetector.HorizonDetector.(HorizonDetector.java:327) at obstacleDetector.HorizonDetector.getInstance(HorizonDetector.java:59) at obstacleDetector.Detector.(Detector.java:28) which directs me to the initialization of the variable. Why can't OpenCV intialize this variable? What is wrong? **P.S:** If it matters, the class which I place this variable, is a Singleton class: public static HorizonDetector getInstance() { if (_instance == null) { _instance = new HorizonDetector(); } else { System.out.println("Same instance of the Horizon Detector-Singleton class already exists."); } return _instance; } Any thoughts?

How to extract 'row' of element from a 3D mat ?

$
0
0
I have an array of 48 matrices, each of size 49 x 49. I can merge them to form a 3D cube of size 48 x 49 x 49. How can I extract a 'row' of elements along the 3rd dimension to form a vector of 48 elements? I have tried using a for loop but I was wondering if there is a more elegant way of doing it. The Mat.col or Mat.row function only applies in 2D

How to use opencv dft with Neon support from Qt on Raspberry Pi 3

$
0
0
Hi All. The problem is that my cv::dft function is running extremely slow on the raspberry pi 3, comparing when ran on a regular PC. I have a raspberry Pi 3 ( jessie ), with opencv 3.1.0 and Qt Creator 3.2.1 Based on Qt 5.3.2 (GCC 4.9.2, 32 bit) I tried recompiling opencv with Neon support like instructed here: http://hopkinsdev.blogspot.co.il/2016/06/opencv-310-optimized-for-raspberry-pi.html and adding the following flags in Qt .pro file: QMAKE_CFLAGS = -mcpu=cortex-a7 -mfpu=neon-vfpv4 -ftree-vectorize -mfloat-abi=hard QMAKE_CXXFLAGS = -mcpu=cortex-a7 -mfpu=neon-vfpv4 -ftree-vectorize -mfloat-abi=hard but I seen no improvement in my app cv::dft run time. I also read the following article: https://www.raspberrypi.org/blog/accelerating-fourier-transforms-using-the-gpu/ but the described class in the article ( GPU_FFT ) is for raspberry pi 1 and the article says fast GPU enabled fft can be done with opencv Neon support on Raspberry pi 3. Any idea how to make the cv::fft go faster, using the Raspberry pi 3 GPU? Thanks!!

How to combine vector of 2D mat into a 3D mat ? Or

$
0
0
How to combine vector of 2D mat into a 3D mat ? Or how can i directly fill up a 3d mat with 2d mats ? This is my code but its not working int planSize[] = { 48, 49, 49 }; cv::Mat voxel(3, planSize, CV_64FC1); for (int i = 0; i < 48; i++) cv::filter2D(imageGray, voxel[i]), -1, texture[i]);

Problem with OpenCV calibration module

$
0
0
I have been spending some time to get my camera calibration working using OpenCV module as documented [here](http://docs.opencv.org/2.4.3/doc/tutorials/calib3d/camera_calibration/camera_calibration.html#cameracalibrationopencv). In particular, I have 3 questions regarding this issue: 1. When using camera input by setting certain value in XML configuration file, I got it working but after the calibration, I got a worse(than the original input) output remapped image. Are there any configuration that I am not aware of? Is the following configuration important, if so, should I measure in mm scale: 50 2. When using image list or recorded video stream, I didn't get any working? Is there any trick, perhaps? It didn't even detect the corners in my chessboard calibration target. When using image list, it runs the image sequences, however, without detecting corners and eventually I received the following error: OpenCV Error: Bad argument (Unknown array type) in cvarrToMat, file /tmp/buildd/ros-fuerte-opencv2-2.4.2-1precise-20130312-1306/modules/core/src/matrix.cpp, line 697 terminate called after throwing an instance of 'cv::Exception' what(): /tmp/buildd/ros-fuerte-opencv2-2.4.2-1precise-20130312-1306/modules/core/src/matrix.cpp:697: error: (-5) Unknown array type in function cvarrToMat 3. When using recorded video stream, I always get the following error: OpenCV Error: Parsing error (output.avi(0): Too long string or a last string w/o newline) in icvXMLSkipSpaces Thanks in advance.

OpenCV Error: Bad argument (Unknown array type) in cvarrToMat

$
0
0
Hi Everyone I am trying to run this calibration program : http://fossies.org/linux/opencv/samples/cpp/tutorial_code/calib3d/camera_calibration/camera_calibration.cpp I already compiled it successfully using CMake , however , when I try to run it with a number of checkerboard snapshots (around 13 photos) to calibrate my IPhone camera : The program goes very well but gets crashed at the line # 362 Here is the output of I got in my terminal : This is a camera calibration sample. Usage: calibration configurationFile Near the sample file you'll find the configuration file, which has detailed help of how to edit it. It may be any OpenCV supported file format XML/YAML. OpenCV Error: Bad argument (Unknown array type) in cvarrToMat, file /tmp/opencv-EKIKs8/opencv-2.4.9/modules/core/src/matrix.cpp, line 698 libc++abi.dylib: terminating with uncaught exception of type cv::Exception: /tmp/opencv-EKIKs8/opencv-2.4.9/modules/core/src/matrix.cpp:698: error: (-5) Unknown array type in function cvarrToMat Abort trap: 6 I really appreciate any help

error LNK2019 in visual studio

$
0
0
HI, I'm new in VS2015 and in Opencv_contrib. I'm trying to make a face recognition program using the cv::face::FaceRecognizer. In fase of compilation it gives me the following error: 1>FaceRecognition.obj : error LNK2019: unresolved external symbol "public: int __cdecl cv::face::FaceRecognizer::predict(class cv::_InputArray const &)const " (?predict@FaceRecognizer@face@cv@@QEBAHAEBV_InputArray@3@@Z) unresolved in function main 1>FaceRecognition.obj : error LNK2019: unresolved external symbol "struct cv::Ptr __cdecl cv::face::createEigenFaceRecognizer(int,double)" (?createEigenFaceRecognizer@face@cv@@YA?AU?$Ptr@VBasicFaceRecognizer@face@cv@@@2@HN@Z) unresolved in funciont main I know there is a problem this the linker and probably I fortgot to include some file.lib but I do not know which. Please, someone can help me?

RTSP communication problem

$
0
0
Hi, It is my first question in this forum, after looking for a long time any solution. I'm using python 2.7 with OPENCV '2.4.13' (I already tried with 3.1) and I can't open streams. I already solved the ffmpeg problem (dll) and tried to run the local camera and after a local video with success. could anyone help me? follow below code: PS: Windows 10, x86 rtsp link working (tried in the vlc player) ffmpeg working (tried to run a video in the code locally) import cv2, platform #import numpy as np cam = "http://192.168.11.146:81/videostream.cgi?rate=0&user=admin&pwd=888888" #cam = 0 # Use local webcam. cap = cv2.VideoCapture(cam) if not cap.isOpened(): print("not opened") while(True): # Capture frame-by-frame ret, current_frame = cap.read() if type(current_frame) == type(None): print("!!! Couldn't read frame!") break # Display the resulting frame cv2.imshow('frame',current_frame) if cv2.waitKey(1) & 0xFF == ord('q'): break # release the capture cap.release() cv2.destroyAllWindows() When I try to run I get back C:\Python27\python.exe C:/Users/brleme/PycharmProjects/opencv/main.py not opened !!! Couldn't read frame! warning: Error opening file (../../modules/highgui/src/cap_ffmpeg_impl.hpp:545) Process finished with exit code 0 image of the camera working in the browser ![image description](/upfiles/14792265962664474.png) kind regards, Bruno

Backporting calibrateCamera

$
0
0
I see that in the latest dev branch, there is some work on a new version of calibrateCamera() that reports estimation errors from the calibration process. I cannot use the dev branch because there seem to be some breaking changes. I'd very much like to backport just the calibrateCamera2Internal() function as the publicly visibly calibrateCamera(). Any guidance on how I can do this? I building on Windows 7 with Visual Studio 2015. Thank you!

hi, i want to use Zootracer of microsoft, and i need files data are in V2.4.8, but i cant it fron your web site

$
0
0
files pencv_core248.dll opencv_highgui248.dll opencv_ffmpeg248_64.dll

Hiring OpenCV Developers [Robotics AI Startup]

$
0
0
**What is Tend.ai?** We’re a cloud robotics software company, backed by True Ventures. We allow robots to understand machines like a human. Watch our video at Tend.ai **Recent Press** - [TechCrunch](https://techcrunch.com/2016/11/07/tend-ai-raises-2m-for-robot-arms-that-operate-multiple-3d-printers-and-workshop-machines/) **What we offer** - Live anywhere between GMT -04:00 and GMT -12:00 or join us in Bend, Oregon - Bay area level salary - Stock options - Medical & dental - Yearly retreat **Requirements** - BS in Computer Science or Robotics - 3+ years of software engineering experience - Expert in OpenCV, Python - Experience with Linux, Git, RGD-B Cameras & Lidar, REST API development - Bonus Points: Javascript, React/Redux, MySQL, Websockets, Unit Testing, Amazon Web Services (AWS), Robot Operating System (ROS), Cobots, Manufacturing / QA, Multi-lingual, Startup experience - Traveling multiple times per year is required **To Apply** Please follow the instructions at [http://tend.ai/careers](http://tend.ai/careers)

opencv/C++: Place a saved image over a webcam stream with facial recognition

$
0
0
I am trying to figure out how to place a saved image over a webcam stream in C++. The trick is that I want to place the image over a face and whenever the face moves, the image will move. I was able to draw a circle over a face with my code here: Point center = Point(faces[i].x + faces[i].width*0.5, faces[i].y + faces[i].height*0.45); circle(captureFrame, center, faces[i].width / 1.65, cvScalar(0, 0, 255, 0), 50, 8, 0); imshow("outputCapture", captureFrame); However, I would like to display an image (test_image.jpg) over my captured webcam frame (captureFrame) on the person's face using the Point function to always find the center of the face. Thank you very much for any help!

OPENCV and JAVA erode

$
0
0
i have a problem with this code help me plz import org.opencv.core.Core; import org.opencv.core.CvType; import org.opencv.core.Mat; import org.opencv.core.Size; import org.opencv.imgcodecs.Imgcodecs; import org.opencv.imgproc.Imgproc; public class main { public static void main( String[] args ) { try{ System.loadLibrary( Core.NATIVE_LIBRARY_NAME ); System.out.println(System.getProperty("java.library.path")); Mat source = Imgcodecs.imread("moi.jpg", Imgcodecs.CV_LOAD_IMAGE_COLOR); Mat destination = new Mat(source.rows(),source.cols(),source.type()); destination = source; int erosion_size = 5; int dilation_size = 5; Mat element = Imgproc.getStructuringElement(Imgproc.MORPH_RECT, new Size(2*erosion_size + 1, 2*erosion_size+1)); Imgproc.erode(source, destination, element); Imgcodecs.imwrite("erosion.jpg", destination); source =Imgcodecs.imread("moi.jpg", Imgcodecs.CV_LOAD_IMAGE_COLOR); destination = source; Mat element1 = Imgproc.getStructuringElement(Imgproc.MORPH_RECT, new Size(2*dilation_size + 1, 2*dilation_size+1)); Imgproc.dilate(source, destination, element1); Imgcodecs.imwrite("dilation.jpg", destination); }catch (Exception e) { System.out.println("error: " + e.getMessage()); } } } OpenCV Error: Assertion failed (m.dims >= 2) in cv::Mat::Mat, file C:\builds\master_PackSlaveAddon-win32-vc12-static\opencv\modules\core\src\matrix.cpp, line 454 error: cv::Exception: C:\builds\master_PackSlaveAddon-win32-vc12-static\opencv\modules\core\src\matrix.cpp:454: error: (-215) m.dims >= 2 in function cv::Mat::Mat

OpenCV does not detect faces on Eclipse/Win7

$
0
0
Hi all, I'm pulling my hair around this one. I have followed tutorials, unzipped opencv, added my library in eclipse, copy/pasted the simple face detection program, and now it runs fine but... it doesn't detect any face, even with faces that are easy to detect and with images that people have successfully used with the same sample code. The catch is that the program runs fine (no error) but does not detect any face, whatever the image I give it (I've tried on larger banks of frontal face images, no luck: 0 face detected). I've even tried the cat face detection with some very obvious images, and still nothing is detected. Eye detection returns 0 eye detected as well. To make sure it is really using the x64 DLL, I've also tried changing the DLL directory to x86 and I do get an error saying that it cannot open a 32 bit DLL on a 64 bit system, which confirms it is indeed loading the DLL. I've tried this with the latest 2.4.13 version of opencv as well as the previous version 2.4.12, with no luck. Anyone ever faced this kind of issue? Any clue what could be causing this? I am on Windows 7 SP 1, x64 obviously. Eclipse is a little old: Mars.1 release (Build id: 20150924-1200). Thanks! JY.

Error while building OpenCV with Contrib-Modules

$
0
0
'm trying to build OpenCV with Cotrib-modules in elementry os after success installation of OpenCV i try to build it with the contrib module but always i get an error while the generation of the .jar file I'm getting the following error: [ 84%] Built target tutorial_Sobel_Demo [javac] /home/rabie/Downloads/opencv-master/build/src/org/opencv/bgsegm/BackgroundSubtractorGMG.java:11: error: cannot find symbol [javac] public class BackgroundSubtractorGMG extends BackgroundSubtractor { [javac] ^ [javac] symbol: class BackgroundSubtractor [javac] /home/rabie/Downloads/opencv-master/build/src/org/opencv/bgsegm/BackgroundSubtractorMOG.java:11: error: cannot find symbol [javac] public class BackgroundSubtractorMOG extends BackgroundSubtractor { [javac] ^ [javac] symbol: class BackgroundSubtractor [javac] /home/rabie/Downloads/opencv-master/build/src/org/opencv/dnn/ConvolutionLayer.java:11: error: cannot find symbol [javac] public class ConvolutionLayer extends Base { [javac] ^ [javac] symbol: class Base [javac] /home/rabie/Downloads/opencv-master/build/src/org/opencv/optflow/DISOpticalFlow.java:11: error: cannot find symbol [javac] public class DISOpticalFlow extends DenseOpticalFlow { [javac] ^ [javac] symbol: class DenseOpticalFlow [javac] /home/rabie/Downloads/opencv-master/build/src/org/opencv/optflow/GPCDetails.java:6: error: package org.opencv.Mat does not exist [javac] import org.opencv.Mat.nativeObj; [javac] ^ [javac] /home/rabie/Downloads/opencv-master/build/src/org/opencv/optflow/VariationalRefinement.java:8: error: package org.opencv.Mat does not exist [javac] import org.opencv.Mat.nativeObj; [javac] ^ [javac] /home/rabie/Downloads/opencv-master/build/src/org/opencv/optflow/VariationalRefinement.java:11: error: cannot find symbol [javac] public class VariationalRefinement extends DenseOpticalFlow { [javac] ^ [javac] symbol: class DenseOpticalFlow [javac] /home/rabie/Downloads/opencv-master/build/src/org/opencv/optflow/OpticalFlowPCAFlow.java:6: error: package org.opencv.Mat does not exist [javac] import org.opencv.Mat.nativeObj; [javac] ^ [javac] /home/rabie/Downloads/opencv-master/build/src/org/opencv/optflow/OpticalFlowPCAFlow.java:11: error: cannot find symbol [javac] public class OpticalFlowPCAFlow extends DenseOpticalFlow { [javac] ^ [javac] symbol: class DenseOpticalFlow [javac] /home/rabie/Downloads/opencv-master/build/src/org/opencv/saliency/Saliency.java:8: error: cannot find symbol [javac] import org.opencv.core.Mat.nativeObj; [javac] ^ [javac] symbol: class nativeObj [javac] location: class Mat [javac] /home/rabie/Downloads/opencv-master/build/src/org/opencv/saliency/Saliency.java:31: error: cannot find symbol [javac] public boolean computeSaliency(Mat image, Mat saliencyMap) [javac] ^ [javac] symbol: class Mat [javac] location: class Saliency [javac] /home/rabie/Downloads/opencv-master/build/src/org/opencv/saliency/Saliency.java:31: error: cannot find symbol [javac] public boolean computeSaliency(Mat image, Mat saliencyMap) [javac] ^ . . . [javac] location: class DISOpticalFlow [javac] /home/rabie/Downloads/opencv-master/build/src/org/opencv/optflow/DISOpticalFlow.java:302: error: method does not override or implement a method from a supertype [javac] @Override [javac] ^ [javac] /home/rabie/Downloads/opencv-master/build/src/org/opencv/optflow/VariationalRefinement.java:192: error: cannot find symbol [javac] setSorIterations_0(nativeObj, val); [javac] ^ [javac] symbol: variable nativeObj [javac] location: class VariationalRefinement [javac] 100 errors Target 'jar' failed with message 'Compile failed; see the compiler error output for details.'. BUILD FAILED /home/rabie/Downloads/opencv-master/build/build.xml:9: Compile failed; see the compiler error output for details. Total time: 6 seconds make[2]: *** [bin/opencv-310.jar] Error 1 make[1]: *** [modules/java/CMakeFiles/opencv_java.dir/all] Error 2 make: *** [all] Error 2 Can anyone please guide me as to how to fix this error? Thanks in advance!!

Displaying an image (in a specified location) over a video stream

$
0
0
Hi I am having trouble figuring out what function to use to display an image (test_image.jpg) over my webcam stream, sort of like a filter over the users face. I have already figured out how to implement facial detection and I am able to display a circle over the face and as the face moves the image moves as well, but I want to know how to put an image over the face instead of the circle. This is what I have to display a circle over the face: Point center = Point(faces[i].x + faces[i].width*0.5, faces[i].y + faces[i].height*0.45); circle(captureFrame, center, faces[i].width / 1.65, cvScalar(255, 0, 0, 0), 50, 8, 0); imshow("outputFrame", captureFrame); Thank you so much for the help!!

I am trying to use the legacy.hpp as header in centos 7, kdevelop 4 editor. Building the code results in following errors. I am looking forward to get my problem solved. Thanks in advance.

$
0
0
/home/vlab/WorkSpaces/ImgReg/build> make -j2 -- A library with BLAS API found. -- A library with LAPACK API found. -- GSL using gsl-config /usr/local/bin/gsl-config -- Using GSL from /usr/local You have called ADD_LIBRARY for library cimg_tut without any source files. This typically indicates a problem with your CMakeLists.txt file -- Configuring done -- Generating done -- Build files have been written to: /home/vlab/WorkSpaces/ImgReg/build Scanning dependencies of target core Scanning dependencies of target core.out [ 3%] Building CXX object CMakeFiles/core.dir/components/core/cvplot.cpp.o [ 6%] Building CXX object CMakeFiles/core.out.dir/components/core/cvplot.cpp.o [ 9%] Building CXX object CMakeFiles/core.dir/components/core/TMCDicomImage.cpp.o [ 12%] Building CXX object CMakeFiles/core.out.dir/components/core/TMCDicomImage.cpp.o [ 16%] Building CXX object CMakeFiles/core.dir/components/core/TMCDicomManager.cpp.o [ 19%] Building CXX object CMakeFiles/core.out.dir/components/core/TMCDicomManager.cpp.o [ 22%] Building CXX object CMakeFiles/core.dir/components/core/TMCDicomVolume.cpp.o [ 25%] Building CXX object CMakeFiles/core.out.dir/components/core/TMCDicomVolume.cpp.o [ 29%] Building CXX object CMakeFiles/core.dir/components/core/TMCFileStorageManager.cpp.o [ 32%] Building CXX object CMakeFiles/core.out.dir/components/core/TMCFileStorageManager.cpp.o [ 35%] Building CXX object CMakeFiles/core.dir/components/core/TMCGNUPlot.cpp.o [ 38%] Building CXX object CMakeFiles/core.out.dir/components/core/TMCGNUPlot.cpp.o [ 41%] Building CXX object CMakeFiles/core.dir/components/core/TMCLogger.cpp.o [ 45%] Building CXX object CMakeFiles/core.out.dir/components/core/TMCLogger.cpp.o [ 48%] Building CXX object CMakeFiles/core.dir/components/core/IOUtils.cpp.o [ 51%] Building CXX object CMakeFiles/core.out.dir/components/core/IOUtils.cpp.o [ 54%] Building CXX object CMakeFiles/core.dir/components/core/CImgOpenCVBridge.cpp.o [ 58%] Building CXX object CMakeFiles/core.out.dir/components/core/CImgOpenCVBridge.cpp.o [ 61%] Building CXX object CMakeFiles/core.dir/components/core/CImgVolume.cpp.o [ 64%] Building CXX object CMakeFiles/core.out.dir/components/core/CImgVolume.cpp.o In file included from /home/vlab/WorkSpaces/ImgReg/components/core/CImgVolume.hpp:9:0, from /home/vlab/WorkSpaces/ImgReg/components/core/CImgVolume.cpp:1: /home/vlab/WorkSpaces/ImgReg/components/core/CImgOpenCVBridge.hpp:15:0: warning: "cimg_verbosity" redefined [enabled by default] #define cimg_verbosity 0 ^ In file included from /home/vlab/WorkSpaces/ImgReg/components/core/CImgVolume.hpp:4:0, from /home/vlab/WorkSpaces/ImgReg/components/core/CImgVolume.cpp:1: /usr/local/include/cimg/CImg.h:246:0: note: this is the location of the previous definition #define cimg_verbosity 1 ^ In file included from /home/vlab/WorkSpaces/ImgReg/components/core/CImgVolume.hpp:9:0, from /home/vlab/WorkSpaces/ImgReg/components/core/CImgVolume.cpp:1: /home/vlab/WorkSpaces/ImgReg/components/core/CImgOpenCVBridge.hpp:15:0: warning: "cimg_verbosity" redefined [enabled by default] #define cimg_verbosity 0 ^ In file included from /home/vlab/WorkSpaces/ImgReg/components/core/CImgVolume.hpp:4:0, from /home/vlab/WorkSpaces/ImgReg/components/core/CImgVolume.cpp:1: /usr/local/include/cimg/CImg.h:246:0: note: this is the location of the previous definition #define cimg_verbosity 1 ^ [ 67%] Building CXX object CMakeFiles/core.dir/components/core/CImgPatientVolume.cpp.o [ 70%] Building CXX object CMakeFiles/core.out.dir/components/core/CImgPatientVolume.cpp.o In file included from /home/vlab/WorkSpaces/ImgReg/components/core/CImgPatientVolume.hpp:9:0, from /home/vlab/WorkSpaces/ImgReg/components/core/CImgPatientVolume.cpp:1: /home/vlab/WorkSpaces/ImgReg/components/core/CImgOpenCVBridge.hpp:15:0: warning: "cimg_verbosity" redefined [enabled by default] #define cimg_verbosity 0 ^ In file included from /home/vlab/WorkSpaces/ImgReg/components/core/CImgPatientVolume.hpp:4:0, from /home/vlab/WorkSpaces/ImgReg/components/core/CImgPatientVolume.cpp:1: /usr/local/include/cimg/CImg.h:246:0: note: this is the location of the previous definition #define cimg_verbosity 1 ^ In file included from /home/vlab/WorkSpaces/ImgReg/components/core/CImgPatientVolume.hpp:9:0, from /home/vlab/WorkSpaces/ImgReg/components/core/CImgPatientVolume.cpp:1: /home/vlab/WorkSpaces/ImgReg/components/core/CImgOpenCVBridge.hpp:15:0: warning: "cimg_verbosity" redefined [enabled by default] #define cimg_verbosity 0 ^ In file included from /home/vlab/WorkSpaces/ImgReg/components/core/CImgPatientVolume.hpp:4:0, from /home/vlab/WorkSpaces/ImgReg/components/core/CImgPatientVolume.cpp:1: /usr/local/include/cimg/CImg.h:246:0: note: this is the location of the previous definition #define cimg_verbosity 1 ^ [ 74%] Building CXX object CMakeFiles/core.dir/components/core/TPFileParser.cpp.o [ 77%] Building CXX object CMakeFiles/core.out.dir/components/core/TPFileParser.cpp.o Linking CXX static library libcore.a [ 80%] Building CXX object CMakeFiles/core.out.dir/components/core/main.cpp.o [ 80%] Built target core Scanning dependencies of target cimg_tut [ 80%] Built target cimg_tut Scanning dependencies of target cimg_tut.out [ 83%] Building CXX object CMakeFiles/cimg_tut.out.dir/components/cimg_tut/main.cpp.o In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:12:0: /home/vlab/WorkSpaces/ImgReg/components/core/CImgOpenCVBridge.hpp:15:0: warning: "cimg_verbosity" redefined [enabled by default] #define cimg_verbosity 0 ^ In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:6:0: /usr/local/include/cimg/CImg.h:246:0: note: this is the location of the previous definition #define cimg_verbosity 1 ^ /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:29:0: warning: "cimg_verbosity" redefined [enabled by default] #define cimg_verbosity 1 ^ In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:12:0: /home/vlab/WorkSpaces/ImgReg/components/core/CImgOpenCVBridge.hpp:15:0: note: this is the location of the previous definition #define cimg_verbosity 0 ^ In file included from /usr/include/tiffio.h:33:0, from /usr/local/include/cimg/CImg.h:360, from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:6: /usr/local/include/opencv2/legacy/legacy.hpp:1972:9: error: expected identifier before numeric constant COMPRESSION_NONE = 0, ^ /usr/local/include/opencv2/legacy/legacy.hpp:1972:9: error: expected ‘}’ before numeric constant /usr/local/include/opencv2/legacy/legacy.hpp:1972:9: error: expected unqualified-id before numeric constant In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7:0: /usr/local/include/opencv2/legacy/legacy.hpp:1978:1: error: expected unqualified-id before ‘protected’ protected: ^ /usr/local/include/opencv2/legacy/legacy.hpp:1982:35: error: ‘virtual’ outside class declaration virtual void finalize(RNG& rng); ^ /usr/local/include/opencv2/legacy/legacy.hpp:1983:53: error: ‘virtual’ outside class declaration virtual int getLeaf(int fidx, const Mat& patch) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:1983:53: error: non-member function ‘int cv::getLeaf(int, const cv::Mat&)’ cannot have cv-qualifier /usr/local/include/opencv2/legacy/legacy.hpp:1993:12: error: ‘Feature’ was not declared in this scope vector features; ^ /usr/local/include/opencv2/legacy/legacy.hpp:1993:19: error: template argument 1 is invalid vector features; ^ /usr/local/include/opencv2/legacy/legacy.hpp:1993:19: error: template argument 2 is invalid /usr/local/include/opencv2/legacy/legacy.hpp:1993:29: error: invalid type in declaration before ‘;’ token vector features; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2035:16: error: ‘vector’ has not been declared void train(vector const& base_set, RNG &rng, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2035:22: error: expected ‘,’ or ‘...’ before ‘<’ token void train(vector const& base_set, RNG &rng, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2037:16: error: ‘vector’ has not been declared void train(vector const& base_set, RNG &rng, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2037:22: error: expected ‘,’ or ‘...’ before ‘<’ token void train(vector const& base_set, RNG &rng, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2037:10: error: ‘void RandomizedTree::train(int)’ cannot be overloaded void train(vector const& base_set, RNG &rng, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2035:10: error: with ‘void RandomizedTree::train(int)’ void train(vector const& base_set, RNG &rng, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2072:5: error: ‘vector’ does not name a type vector nodes_; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2075:5: error: ‘vector’ does not name a type vector leaf_counts_; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2077:37: error: ‘RNG’ has not been declared void createNodes(int num_nodes, RNG &rng); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2080:39: error: ‘RNG’ has not been declared void init(int classes, int depth, RNG &rng); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2145:16: error: ‘vector’ has not been declared void train(vector const& base_set, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2145:22: error: expected ‘,’ or ‘...’ before ‘<’ token void train(vector const& base_set, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2152:16: error: ‘vector’ has not been declared void train(vector const& base_set, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2152:22: error: expected ‘,’ or ‘...’ before ‘<’ token void train(vector const& base_set, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2152:10: error: ‘void RTreeClassifier::train(int)’ cannot be overloaded void train(vector const& base_set, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2145:10: error: with ‘void RTreeClassifier::train(int)’ void train(vector const& base_set, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2189:5: error: ‘vector’ does not name a type vector trees_; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2328:26: error: ‘FileNode’ does not name a type int ReadByName(const FileNode &parent, const char* name); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2359:5: error: ‘string’ does not name a type string m_feature_name; // the name of the feature associated with the descriptor ^ /usr/local/include/opencv2/legacy/legacy.hpp:2385:67: error: ‘string’ does not name a type OneWayDescriptorBase(CvSize patch_size, int pose_count, const string &pca_filename, const string &train_path = string(), const string &images_list = string(), ^ /usr/local/include/opencv2/legacy/legacy.hpp:2385:95: error: ‘string’ does not name a type OneWayDescriptorBase(CvSize patch_size, int pose_count, const string &pca_filename, const string &train_path = string(), const string &images_list = string(), ^ /usr/local/include/opencv2/legacy/legacy.hpp:2385:132: error: ‘string’ does not name a type OneWayDescriptorBase(CvSize patch_size, int pose_count, const string &pca_filename, const string &train_path = string(), const string &images_list = string(), ^ /usr/local/include/opencv2/legacy/legacy.hpp:2415:58: error: ‘vector’ does not name a type void CreateDescriptorsFromImage(IplImage* src, const vector& features); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2415:64: error: expected ‘,’ or ‘...’ before ‘<’ token void CreateDescriptorsFromImage(IplImage* src, const vector& features); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2439:49: error: ‘vector’ has not been declared void FindDescriptor(IplImage* patch, int n, vector& desc_idxs, vector& pose_idxs, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2439:55: error: expected ‘,’ or ‘...’ before ‘<’ token void FindDescriptor(IplImage* patch, int n, vector& desc_idxs, vector& pose_idxs, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2465:74: error: ‘KeyPoint’ does not name a type void InitializeDescriptor(int desc_idx, IplImage* train_image, const KeyPoint& keypoint, const char* feature_label); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2468:61: error: ‘vector’ does not name a type void InitializeDescriptors(IplImage* train_image, const vector& features, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2468:67: error: expected ‘,’ or ‘...’ before ‘<’ token void InitializeDescriptors(IplImage* train_image, const vector& features, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2473:17: error: ‘FileStorage’ has not been declared void Write (FileStorage &fs) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2477:22: error: ‘FileNode’ does not name a type void Read (const FileNode &fn); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2485:34: error: ‘FileNode’ does not name a type int LoadPCADescriptors(const FileNode &fn); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2519:12: error: ‘string’ does not name a type static string GetPCAFilename () { return "pca.yml"; } ^ /usr/local/include/opencv2/legacy/legacy.hpp:2550:22: error: ‘FileStorage’ has not been declared void SavePCAall (FileStorage &fs) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2554:28: error: ‘FileNode’ does not name a type void LoadPCAall (const FileNode &fn); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2385:123: error: ‘string’ was not declared in this scope OneWayDescriptorBase(CvSize patch_size, int pose_count, const string &pca_filename, const string &train_path = string(), const string &images_list = string(), ^ /usr/local/include/opencv2/legacy/legacy.hpp:2385:123: note: suggested alternatives: In file included from /usr/include/c++/4.8.2/string:39:0, from /usr/include/ImageMagick/Magick++/Image.h:12, from /usr/include/ImageMagick/Magick++.h:10, from /usr/local/include/cimg/CImg.h:411, from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:6: /usr/include/c++/4.8.2/bits/stringfwd.h:62:33: note: ‘std::string’ typedef basic_string string; ^ /usr/include/c++/4.8.2/bits/stringfwd.h:62:33: note: ‘std::string’ In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7:0: /usr/local/include/opencv2/legacy/legacy.hpp:2385:161: error: ‘string’ was not declared in this scope OneWayDescriptorBase(CvSize patch_size, int pose_count, const string &pca_filename, const string &train_path = string(), const string &images_list = string(), ^ /usr/local/include/opencv2/legacy/legacy.hpp:2385:161: note: suggested alternatives: In file included from /usr/include/c++/4.8.2/string:39:0, from /usr/include/ImageMagick/Magick++/Image.h:12, from /usr/include/ImageMagick/Magick++.h:10, from /usr/local/include/cimg/CImg.h:411, from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:6: /usr/include/c++/4.8.2/bits/stringfwd.h:62:33: note: ‘std::string’ typedef basic_string string; ^ /usr/include/c++/4.8.2/bits/stringfwd.h:62:33: note: ‘std::string’ In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7:0: /usr/local/include/opencv2/legacy/legacy.hpp:2571:69: error: ‘string’ does not name a type OneWayDescriptorObject(CvSize patch_size, int pose_count, const string &pca_filename, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2572:34: error: ‘string’ does not name a type const string &train_path = string (), const string &images_list = string (), ^ /usr/local/include/opencv2/legacy/legacy.hpp:2572:72: error: ‘string’ does not name a type const string &train_path = string (), const string &images_list = string (), ^ /usr/local/include/opencv2/legacy/legacy.hpp:2584:35: error: ‘vector’ does not name a type void SetLabeledFeatures(const vector& features) {m_train_features = features;}; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2584:41: error: expected ‘,’ or ‘...’ before ‘<’ token void SetLabeledFeatures(const vector& features) {m_train_features = features;}; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2585:5: error: ‘vector’ does not name a type vector& GetLabeledFeatures() {return m_train_features;}; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2586:11: error: ‘vector’ does not name a type const vector& GetLabeledFeatures() const {return m_train_features;}; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2587:5: error: ‘vector’ does not name a type vector _GetLabeledFeatures() const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2600:67: error: ‘vector’ does not name a type void InitializeObjectDescriptors(IplImage* train_image, const vector& features, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2600:73: error: expected ‘,’ or ‘...’ before ‘<’ token void InitializeObjectDescriptors(IplImage* train_image, const vector& features, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2609:5: error: ‘vector’ does not name a type vector m_train_features; // train features ^ /usr/local/include/opencv2/legacy/legacy.hpp:2572:63: error: ‘string’ was not declared in this scope const string &train_path = string (), const string &images_list = string (), ^ /usr/local/include/opencv2/legacy/legacy.hpp:2572:63: note: suggested alternatives: In file included from /usr/include/c++/4.8.2/string:39:0, from /usr/include/ImageMagick/Magick++/Image.h:12, from /usr/include/ImageMagick/Magick++.h:10, from /usr/local/include/cimg/CImg.h:411, from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:6: /usr/include/c++/4.8.2/bits/stringfwd.h:62:33: note: ‘std::string’ typedef basic_string string; ^ /usr/include/c++/4.8.2/bits/stringfwd.h:62:33: note: ‘std::string’ In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7:0: /usr/local/include/opencv2/legacy/legacy.hpp:2572:102: error: ‘string’ was not declared in this scope const string &train_path = string (), const string &images_list = string (), ^ /usr/local/include/opencv2/legacy/legacy.hpp:2572:102: note: suggested alternatives: In file included from /usr/include/c++/4.8.2/string:39:0, from /usr/include/ImageMagick/Magick++/Image.h:12, from /usr/include/ImageMagick/Magick++.h:10, from /usr/local/include/cimg/CImg.h:411, from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:6: /usr/include/c++/4.8.2/bits/stringfwd.h:62:33: note: ‘std::string’ typedef basic_string string; ^ /usr/include/c++/4.8.2/bits/stringfwd.h:62:33: note: ‘std::string’ In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7:0: /usr/local/include/opencv2/legacy/legacy.hpp: In member function ‘void OneWayDescriptorObject::SetLabeledFeatures(int)’: /usr/local/include/opencv2/legacy/legacy.hpp:2584:64: error: ‘m_train_features’ was not declared in this scope void SetLabeledFeatures(const vector& features) {m_train_features = features;}; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2584:83: error: ‘features’ was not declared in this scope void SetLabeledFeatures(const vector& features) {m_train_features = features;}; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2584:83: note: suggested alternative: /usr/local/include/opencv2/legacy/legacy.hpp:1993:21: note: ‘cv::features’ vector features; ^ /usr/local/include/opencv2/legacy/legacy.hpp: At global scope: /usr/local/include/opencv2/legacy/legacy.hpp:2622:1: error: expected class-name before ‘{’ token { ^ /usr/local/include/opencv2/legacy/legacy.hpp:2635:16: error: ‘Size’ has not been declared Size patchSize = Size(PATCH_WIDTH, PATCH_HEIGHT), ^ /usr/local/include/opencv2/legacy/legacy.hpp:2636:16: error: ‘string’ has not been declared string pcaFilename = string(), ^ /usr/local/include/opencv2/legacy/legacy.hpp:2637:16: error: ‘string’ has not been declared string trainPath = string(), string trainImagesList = string(), ^ /usr/local/include/opencv2/legacy/legacy.hpp:2637:45: error: ‘string’ has not been declared string trainPath = string(), string trainImagesList = string(), ^ /usr/local/include/opencv2/legacy/legacy.hpp:2642:9: error: ‘Size’ does not name a type Size patchSize; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2643:9: error: ‘string’ does not name a type string pcaFilename; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2644:9: error: ‘string’ does not name a type string trainPath; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2645:9: error: ‘string’ does not name a type string trainImagesList; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2653:50: error: ‘Ptr’ does not name a type void initialize( const Params& params, const Ptr& base=Ptr() ); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2653:53: error: expected ‘,’ or ‘...’ before ‘<’ token void initialize( const Params& params, const Ptr& base=Ptr() ); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2662:30: error: ‘FileNode’ does not name a type virtual void read( const FileNode &fn ); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2663:25: error: ‘FileStorage’ has not been declared virtual void write( FileStorage& fs ) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2667:13: error: ‘Ptr’ does not name a type virtual Ptr clone( bool emptyTrainData=false ) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2676:38: error: ‘Mat’ does not name a type virtual void knnMatchImpl( const Mat& queryImage, vector& queryKeypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2676:55: error: ‘vector’ has not been declared virtual void knnMatchImpl( const Mat& queryImage, vector& queryKeypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2676:61: error: expected ‘,’ or ‘...’ before ‘<’ token virtual void knnMatchImpl( const Mat& queryImage, vector& queryKeypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2679:41: error: ‘Mat’ does not name a type virtual void radiusMatchImpl( const Mat& queryImage, vector& queryKeypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2679:58: error: ‘vector’ has not been declared virtual void radiusMatchImpl( const Mat& queryImage, vector& queryKeypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2679:64: error: expected ‘,’ or ‘...’ before ‘<’ token virtual void radiusMatchImpl( const Mat& queryImage, vector& queryKeypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2683:5: error: ‘Ptr’ does not name a type Ptr base; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2635:63: error: ‘Size’ was not declared in this scope Size patchSize = Size(PATCH_WIDTH, PATCH_HEIGHT), ^ /usr/local/include/opencv2/legacy/legacy.hpp:2635:63: note: suggested alternative: In file included from /usr/local/include/opencv2/imgproc/imgproc.hpp:50:0, from /usr/local/include/opencv2/legacy/legacy.hpp:45, from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7: /usr/local/include/opencv2/core/core.hpp:889:16: note: ‘cv::Size’ typedef Size2i Size; ^ In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7:0: /usr/local/include/opencv2/legacy/legacy.hpp:2636:44: error: ‘string’ was not declared in this scope string pcaFilename = string(), ^ /usr/local/include/opencv2/legacy/legacy.hpp:2636:44: note: suggested alternatives: In file included from /usr/include/c++/4.8.2/string:39:0, from /usr/include/ImageMagick/Magick++/Image.h:12, from /usr/include/ImageMagick/Magick++.h:10, from /usr/local/include/cimg/CImg.h:411, from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:6: /usr/include/c++/4.8.2/bits/stringfwd.h:62:33: note: ‘std::string’ typedef basic_string string; ^ /usr/include/c++/4.8.2/bits/stringfwd.h:62:33: note: ‘std::string’ In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7:0: /usr/local/include/opencv2/legacy/legacy.hpp:2637:42: error: ‘string’ was not declared in this scope string trainPath = string(), string trainImagesList = string(), ^ /usr/local/include/opencv2/legacy/legacy.hpp:2637:42: note: suggested alternatives: In file included from /usr/include/c++/4.8.2/string:39:0, from /usr/include/ImageMagick/Magick++/Image.h:12, from /usr/include/ImageMagick/Magick++.h:10, from /usr/local/include/cimg/CImg.h:411, from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:6: /usr/include/c++/4.8.2/bits/stringfwd.h:62:33: note: ‘std::string’ typedef basic_string string; ^ /usr/include/c++/4.8.2/bits/stringfwd.h:62:33: note: ‘std::string’ In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7:0: /usr/local/include/opencv2/legacy/legacy.hpp:2637:77: error: ‘string’ was not declared in this scope string trainPath = string(), string trainImagesList = string(), ^ /usr/local/include/opencv2/legacy/legacy.hpp:2637:77: note: suggested alternatives: In file included from /usr/include/c++/4.8.2/string:39:0, from /usr/include/ImageMagick/Magick++/Image.h:12, from /usr/include/ImageMagick/Magick++.h:10, from /usr/local/include/cimg/CImg.h:411, from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:6: /usr/include/c++/4.8.2/bits/stringfwd.h:62:33: note: ‘std::string’ typedef basic_string string; ^ /usr/include/c++/4.8.2/bits/stringfwd.h:62:33: note: ‘std::string’ In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7:0: /usr/local/include/opencv2/legacy/legacy.hpp:2650:58: error: call to ‘OneWayDescriptorMatcher::Params::Params(int, int, int, int, int, float, float, float)’ uses the default argument for parameter 2, which is not yet defined OneWayDescriptorMatcher( const Params& params=Params() ); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2650:58: error: call to ‘OneWayDescriptorMatcher::Params::Params(int, int, int, int, int, float, float, float)’ uses the default argument for parameter 3, which is not yet defined /usr/local/include/opencv2/legacy/legacy.hpp:2650:58: error: call to ‘OneWayDescriptorMatcher::Params::Params(int, int, int, int, int, float, float, float)’ uses the default argument for parameter 4, which is not yet defined /usr/local/include/opencv2/legacy/legacy.hpp:2650:58: error: call to ‘OneWayDescriptorMatcher::Params::Params(int, int, int, int, int, float, float, float)’ uses the default argument for parameter 5, which is not yet defined /usr/local/include/opencv2/legacy/legacy.hpp:2695:1: error: expected class-name before ‘{’ token { ^ /usr/local/include/opencv2/legacy/legacy.hpp:2707:22: error: ‘PatchGenerator’ does not name a type const PatchGenerator& patchGenerator=PatchGenerator() ); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2709:23: error: ‘string’ does not name a type Params( const string& filename ); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2718:9: error: ‘PatchGenerator’ does not name a type PatchGenerator patchGenerator; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2720:9: error: ‘string’ does not name a type string filename; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2732:30: error: ‘FileNode’ does not name a type virtual void read( const FileNode &fn ); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2733:25: error: ‘FileStorage’ has not been declared virtual void write( FileStorage& fs ) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2736:13: error: ‘Ptr’ does not name a type virtual Ptr clone( bool emptyTrainData=false ) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2739:38: error: ‘Mat’ does not name a type virtual void knnMatchImpl( const Mat& queryImage, vector& queryKeypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2739:55: error: ‘vector’ has not been declared virtual void knnMatchImpl( const Mat& queryImage, vector& queryKeypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2739:61: error: expected ‘,’ or ‘...’ before ‘<’ token virtual void knnMatchImpl( const Mat& queryImage, vector& queryKeypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2742:41: error: ‘Mat’ does not name a type virtual void radiusMatchImpl( const Mat& queryImage, vector& queryKeypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2742:58: error: ‘vector’ has not been declared virtual void radiusMatchImpl( const Mat& queryImage, vector& queryKeypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2742:64: error: expected ‘,’ or ‘...’ before ‘<’ token virtual void radiusMatchImpl( const Mat& queryImage, vector& queryKeypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2747:41: error: ‘Mat’ does not name a type void calcBestProbAndMatchIdx( const Mat& image, const Point2f& pt, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2747:59: error: ‘Point2f’ does not name a type void calcBestProbAndMatchIdx( const Mat& image, const Point2f& pt, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2748:70: error: ‘vector’ has not been declared float& bestProb, int& bestMatchIdx, vector& signature ); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2748:76: error: expected ‘,’ or ‘...’ before ‘<’ token float& bestProb, int& bestMatchIdx, vector& signature ); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2749:5: error: ‘Ptr’ does not name a type Ptr classifier; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2701:30: error: ‘FernClassifier’ has not been declared int patchSize=FernClassifier::PATCH_SIZE, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2702:34: error: ‘FernClassifier’ has not been declared int signatureSize=FernClassifier::DEFAULT_SIGNATURE_SIZE, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2703:29: error: ‘FernClassifier’ has not been declared int nstructs=FernClassifier::DEFAULT_STRUCTS, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2704:31: error: ‘FernClassifier’ has not been declared int structSize=FernClassifier::DEFAULT_STRUCT_SIZE, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2705:27: error: ‘FernClassifier’ has not been declared int nviews=FernClassifier::DEFAULT_VIEWS, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2706:38: error: ‘FernClassifier’ has not been declared int compressionMethod=FernClassifier::COMPRESSION_NONE, ^ In file included from /usr/include/tiffio.h:33:0, from /usr/local/include/cimg/CImg.h:360, from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:6: /usr/local/include/opencv2/legacy/legacy.hpp:2706:54: error: expected unqualified-id before numeric constant int compressionMethod=FernClassifier::COMPRESSION_NONE, ^ In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7:0: /usr/local/include/opencv2/legacy/legacy.hpp:2707:68: error: ‘PatchGenerator’ was not declared in this scope const PatchGenerator& patchGenerator=PatchGenerator() ); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2707:68: note: suggested alternative: /usr/local/include/opencv2/legacy/legacy.hpp:1845:18: note: ‘cv::PatchGenerator’ class CV_EXPORTS PatchGenerator ^ /usr/local/include/opencv2/legacy/legacy.hpp:2723:56: error: call to ‘FernDescriptorMatcher::Params::Params(int, int, int, int, int, int, int, const int&)’ uses the default argument for parameter 2, which is not yet defined FernDescriptorMatcher( const Params& params=Params() ); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2723:56: error: call to ‘FernDescriptorMatcher::Params::Params(int, int, int, int, int, int, int, const int&)’ uses the default argument for parameter 3, which is not yet defined /usr/local/include/opencv2/legacy/legacy.hpp:2723:56: error: call to ‘FernDescriptorMatcher::Params::Params(int, int, int, int, int, int, int, const int&)’ uses the default argument for parameter 4, which is not yet defined /usr/local/include/opencv2/legacy/legacy.hpp:2723:56: error: call to ‘FernDescriptorMatcher::Params::Params(int, int, int, int, int, int, int, const int&)’ uses the default argument for parameter 5, which is not yet defined /usr/local/include/opencv2/legacy/legacy.hpp:2723:56: error: call to ‘FernDescriptorMatcher::Params::Params(int, int, int, int, int, int, int, const int&)’ uses the default argument for parameter 6, which is not yet defined /usr/local/include/opencv2/legacy/legacy.hpp:2723:56: error: call to ‘FernDescriptorMatcher::Params::Params(int, int, int, int, int, int, int, const int&)’ uses the default argument for parameter 7, which is not yet defined /usr/local/include/opencv2/legacy/legacy.hpp:2723:56: error: call to ‘FernDescriptorMatcher::Params::Params(int, int, int, int, int, int, int, const int&)’ uses the default argument for parameter 8, which is not yet defined /usr/local/include/opencv2/legacy/legacy.hpp:2760:1: error: expected class-name before ‘{’ token { ^ /usr/local/include/opencv2/legacy/legacy.hpp:2762:40: error: ‘string’ does not name a type CalonderDescriptorExtractor( const string& classifierFile ); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2764:30: error: ‘FileNode’ does not name a type virtual void read( const FileNode &fn ); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2765:25: error: ‘FileStorage’ has not been declared virtual void write( FileStorage &fs ) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2773:37: error: ‘Mat’ does not name a type virtual void computeImpl( const Mat& image, vector& keypoints, Mat& descriptors ) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2773:49: error: ‘vector’ has not been declared virtual void computeImpl( const Mat& image, vector& keypoints, Mat& descriptors ) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2773:55: error: expected ‘,’ or ‘...’ before ‘<’ token virtual void computeImpl( const Mat& image, vector& keypoints, Mat& descriptors ) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp: In member function ‘virtual int CalonderDescriptorExtractor::descriptorType() const’: /usr/local/include/opencv2/legacy/legacy.hpp:2768:49: error: ‘DataType’ was not declared in this scope virtual int descriptorType() const { return DataType::type; } ^ /usr/local/include/opencv2/legacy/legacy.hpp:2768:49: note: suggested alternative: In file included from /usr/local/include/opencv2/imgproc/imgproc.hpp:50:0, from /usr/local/include/opencv2/legacy/legacy.hpp:45, from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7: /usr/local/include/opencv2/core/core.hpp:999:30: note: ‘cv::DataType’ template class DataType ^ In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7:0: /usr/local/include/opencv2/legacy/legacy.hpp:2768:59: error: expected primary-expression before ‘>’ token virtual int descriptorType() const { return DataType::type; } ^ /usr/local/include/opencv2/legacy/legacy.hpp:2768:60: error: ‘::type’ has not been declared virtual int descriptorType() const { return DataType::type; } ^ /usr/local/include/opencv2/legacy/legacy.hpp:2768:60: note: suggested alternative: In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:6:0: /usr/local/include/cimg/CImg.h:2455:33: note: ‘cimg_library::cimg::type’ template struct type { ^ In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7:0: /usr/local/include/opencv2/legacy/legacy.hpp: At global scope: /usr/local/include/opencv2/legacy/legacy.hpp:2780:1: error: prototype for ‘CalonderDescriptorExtractor::CalonderDescriptorExtractor(const string&)’ does not match any in class ‘CalonderDescriptorExtractor’ CalonderDescriptorExtractor::CalonderDescriptorExtractor(const std::string& classifier_file) ^ /usr/local/include/opencv2/legacy/legacy.hpp:2762:5: error: candidate is: CalonderDescriptorExtractor::CalonderDescriptorExtractor(const int&) CalonderDescriptorExtractor( const string& classifierFile ); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2786:57: error: ‘Mat’ does not name a type void CalonderDescriptorExtractor::computeImpl( const Mat& image, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2787:50: error: ‘vector’ has not been declared vector& keypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2787:56: error: expected ‘,’ or ‘...’ before ‘<’ token vector& keypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp: In member function ‘virtual void CalonderDescriptorExtractor::computeImpl(const int&, int) const’: /usr/local/include/opencv2/legacy/legacy.hpp:2791:5: error: ‘KeyPointsFilter’ has not been declared KeyPointsFilter::runByImageBorder(keypoints, image.size(), BORDER_SIZE); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2791:39: error: ‘keypoints’ was not declared in this scope KeyPointsFilter::runByImageBorder(keypoints, image.size(), BORDER_SIZE); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2791:56: error: request for member ‘size’ in ‘image’, which is of non-class type ‘const int’ KeyPointsFilter::runByImageBorder(keypoints, image.size(), BORDER_SIZE); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2794:5: error: ‘descriptors’ was not declared in this scope descriptors.create((int)keypoints.size(), classifier_.classes(), cv::DataType::type); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2801:100: error: there are no arguments to ‘Rect’ that depend on a template parameter, so a declaration of ‘Rect’ must be available [-fpermissive] IplImage ipl = image( Rect((int)(pt.x - offset), (int)(pt.y - offset), patchSize, patchSize) ); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2801:100: note: (if you use ‘-fpermissive’, G++ will accept your code, but allowing the use of an undeclared name is deprecated) /usr/local/include/opencv2/legacy/legacy.hpp:2802:58: error: expected primary-expression before ‘>’ token classifier_.getSignature( &ipl, descriptors.ptr((int)i)); ^ /usr/local/include/opencv2/legacy/legacy.hpp: At global scope: /usr/local/include/opencv2/legacy/legacy.hpp:2807:50: error: ‘FileNode’ does not name a type void CalonderDescriptorExtractor::read( const FileNode& ) ^ /usr/local/include/opencv2/legacy/legacy.hpp:2811:45: error: variable or field ‘write’ declared void void CalonderDescriptorExtractor::write( FileStorage& ) const ^ /usr/local/include/opencv2/legacy/legacy.hpp:2811:45: error: ‘FileStorage’ was not declared in this scope /usr/local/include/opencv2/legacy/legacy.hpp:2811:45: note: suggested alternative: In file included from /usr/local/include/opencv2/imgproc/imgproc.hpp:50:0, from /usr/local/include/opencv2/legacy/legacy.hpp:45, from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7: /usr/local/include/opencv2/core/core.hpp:4068:20: note: ‘cv::FileStorage’ class CV_EXPORTS_W FileStorage ^ In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7:0: /usr/local/include/opencv2/legacy/legacy.hpp:2811:58: error: expected primary-expression before ‘)’ token void CalonderDescriptorExtractor::write( FileStorage& ) const ^ /usr/local/include/opencv2/legacy/legacy.hpp: In member function ‘virtual bool CalonderDescriptorExtractor::empty() const’: /usr/local/include/opencv2/legacy/legacy.hpp:2817:24: error: ‘const class RTreeClassifier’ has no member named ‘trees_’ return classifier_.trees_.empty(); ^ /usr/local/include/opencv2/legacy/legacy.hpp: At global scope: /usr/local/include/opencv2/legacy/legacy.hpp:2825:1: error: expected class-name before ‘{’ token { ^ /usr/local/include/opencv2/legacy/legacy.hpp: In constructor ‘BruteForceMatcher::BruteForceMatcher(Distance)’: /usr/local/include/opencv2/legacy/legacy.hpp:2827:52: error: class ‘BruteForceMatcher’ does not have any field named ‘BFMatcher’ BruteForceMatcher( Distance d = Distance() ) : BFMatcher(Distance::normType, false) {(void)d;} ^ /usr/local/include/opencv2/legacy/legacy.hpp: At global scope: /usr/local/include/opencv2/legacy/legacy.hpp:2840:32: error: ‘FileNode’ does not name a type PlanarObjectDetector(const FileNode& node); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2841:32: error: ‘vector’ does not name a type PlanarObjectDetector(const vector& pyr, int _npoints=300, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2841:38: error: expected ‘,’ or ‘...’ before ‘<’ token PlanarObjectDetector(const vector& pyr, int _npoints=300, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2849:30: error: ‘vector’ does not name a type virtual void train(const vector& pyr, int _npoints=300, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2849:36: error: expected ‘,’ or ‘...’ before ‘<’ token virtual void train(const vector& pyr, int _npoints=300, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2856:30: error: ‘vector’ does not name a type virtual void train(const vector& pyr, const vector& keypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2856:36: error: expected ‘,’ or ‘...’ before ‘<’ token virtual void train(const vector& pyr, const vector& keypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2856:18: error: ‘virtual void PlanarObjectDetector::train(int)’ cannot be overloaded virtual void train(const vector& pyr, const vector& keypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2849:18: error: with ‘virtual void PlanarObjectDetector::train(int)’ virtual void train(const vector& pyr, int _npoints=300, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2863:5: error: ‘Rect’ does not name a type Rect getModelROI() const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2864:5: error: ‘vector’ does not name a type vector getModelPoints() const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2865:11: error: ‘LDetector’ does not name a type const LDetector& getDetector() const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2866:11: error: ‘FernClassifier’ does not name a type const FernClassifier& getClassifier() const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2869:21: error: ‘FileNode’ does not name a type void read(const FileNode& node); ^ /usr/local/include/opencv2/legacy/legacy.hpp:2870:16: error: ‘FileStorage’ has not been declared void write(FileStorage& fs, const String& name=String()) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2870:39: error: ‘String’ does not name a type void write(FileStorage& fs, const String& name=String()) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2871:27: error: ‘Mat’ does not name a type bool operator()(const Mat& image, CV_OUT Mat& H, CV_OUT vector& corners) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2871:46: error: ‘Mat’ has not been declared bool operator()(const Mat& image, CV_OUT Mat& H, CV_OUT vector& corners) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2871:61: error: ‘vector’ has not been declared bool operator()(const Mat& image, CV_OUT Mat& H, CV_OUT vector& corners) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2871:67: error: expected ‘,’ or ‘...’ before ‘<’ token bool operator()(const Mat& image, CV_OUT Mat& H, CV_OUT vector& corners) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2872:27: error: ‘vector’ does not name a type bool operator()(const vector& pyr, const vector& keypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2872:33: error: expected ‘,’ or ‘...’ before ‘<’ token bool operator()(const vector& pyr, const vector& keypoints, ^ /usr/local/include/opencv2/legacy/legacy.hpp:2878:5: error: ‘Rect’ does not name a type Rect modelROI; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2879:5: error: ‘vector’ does not name a type vector modelPoints; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2880:5: error: ‘LDetector’ does not name a type LDetector ldetector; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2881:5: error: ‘FernClassifier’ does not name a type FernClassifier fernClassifier; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2870:59: error: ‘String’ was not declared in this scope void write(FileStorage& fs, const String& name=String()) const; ^ /usr/local/include/opencv2/legacy/legacy.hpp:2870:59: note: suggested alternative: In file included from /usr/local/include/opencv2/imgproc/imgproc.hpp:50:0, from /usr/local/include/opencv2/legacy/legacy.hpp:45, from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7: /usr/local/include/opencv2/core/core.hpp:87:21: note: ‘cv::String’ typedef std::string String; ^ In file included from /home/vlab/WorkSpaces/ImgReg/components/cimg_tut/main.cpp:7:0: /usr/local/include/opencv2/legacy/legacy.hpp:2884:1: error: expected declaration before ‘}’ token } ^ make[2]: *** [CMakeFiles/cimg_tut.out.dir/components/cimg_tut/main.cpp.o] Error 1 make[1]: *** [CMakeFiles/cimg_tut.out.dir/all] Error 2 make[1]: *** Waiting for unfinished jobs.... Linking CXX executable core.out [ 83%] Built target core.out make: *** [all] Error 2 *** Failure: Exit code 2 ***

Build failed opencv3.1 cuda8 vs2015

$
0
0
Dear all, is there anyone successfully build with this configuration. I had try many times but still giving me lots of errors and warnings. Example of warnings I received ![image description](/upfiles/14789603117328503.jpg) ![image description](/upfiles/14789603283594968.jpg) After the build failed, this window pop out. ![image description](/upfiles/14789603407979184.jpg) Anyone know how to solved this problem? Before this I successfully built by disabling with_cuda. But right now I need to use cuda. But failed to build it and I did enabled with_cuda in cmake.

how to align depth image and rgb image from kinect using opencv(python wrapper)?

$
0
0
I performed the calibration as described in tutorial (http://wiki.ros.org/openni_launch/Tutorials/IntrinsicCalibration), I am using libfreenect , ## ---------- ## - Heading ## ## i obtained the following as correction yaml files how use the depth or disparity image from kinect in function reprojectImageTo3D() ( it requires disparity image and Q matrix) to obtain 3D map. 2 )how can i compute Q matrix ? DEPTH CALIBRATION DATA image_width: 640 image_height: 488 camera_name: depth_0000000000000000 camera_matrix: rows: 3 cols: 3 data: [562.2209020269851, 0, 295.4125802978841, 0, 565.8847255058765, 262.3259607398875, 0, 0, 1] distortion_model: plumb_bob distortion_coefficients: rows: 1 cols: 5 data: [-0.1259995811013459, 0.1811366154284992, 0.01130003143823414, -0.009229840629574821, 0] rectification_matrix: rows: 3 cols: 3 data: [1, 0, 0, 0, 1, 0, 0, 0, 1] projection_matrix: rows: 3 cols: 4 data: [555.9630126953125, 0, 290.5473281458035, 0, 0, 559.1112060546875, 267.2632963446558, 0, 0, 0, 1, 0] RGB CALIBRATION DATA image_width: 640 image_height: 480 camera_name: rgb_0000000000000000 camera_matrix: rows: 3 cols: 3 data: [495.9302302198659, 0, 306.9398440268479, 0, 499.8108755587267, 249.034495543172, 0, 0, 1] distortion_model: plumb_bob distortion_coefficients: rows: 1 cols: 5 data: [-0.03382499267587227, -0.009317764701757332, 0.01484486854679595, -0.005902203980048986, 0] rectification_matrix: rows: 3 cols: 3 data: [1, 0, 0, 0, 1, 0, 0, 0, 1] projection_matrix: rows: 3 cols: 4 data: [489.8033447265625, 0, 302.1437562610008, 0, 0, 495.2186279296875, 254.955970881063, 0, 0, 0, 1, 0]

Building "Tracking" module in OpenCV extra modules with Cmake does not generate relevant headers of that module

$
0
0
I am not able to get a working custom build for implementation of some OpenCV sample motion tracking examples which requires the module "tracking" part of **opencv_contrib**. I tried to custom build on on VC12.0 x64 on windows. But it does not generate headers like **tracking.hpp** and **tracker.hpp** specific to tracking inside its own folder (C:\OpenCV\build\install\include\opencv2\tracking) like in the case of all other extra modules. I followed the building procedure as [here][1] My ultimate aim is to run the sample: tutorial_introduction_to_tracker.cpp found [here][2]. Any assistance would be appreciated. [1]: https://putuyuwono.wordpress.com/2015/04/23/building-and-installing-opencv-3-0-on-windows-7-64-bit/ [2]: http://docs.opencv.org/3.1.0/d2/d0a/tutorial_introduction_to_tracker.html
Viewing all 19555 articles
Browse latest View live