Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv
Commits
042271f5
Commit
042271f5
authored
Nov 26, 2010
by
Vadim Pisarevsky
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
use the new-style headers in the samples to improve OpenCV build time.
parent
54ef4c08
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
55 changed files
with
171 additions
and
350 deletions
+171
-350
adaptiveskindetector.cpp
samples/c/adaptiveskindetector.cpp
+2
-2
bgfg_codebook.cpp
samples/c/bgfg_codebook.cpp
+5
-4
bgfg_segm.cpp
samples/c/bgfg_segm.cpp
+3
-2
blobtrack_sample.cpp
samples/c/blobtrack_sample.cpp
+5
-2
calibration_artificial.cpp
samples/c/calibration_artificial.cpp
+3
-2
camshiftdemo.c
samples/c/camshiftdemo.c
+2
-9
contours.c
samples/c/contours.c
+2
-11
convert_cascade.c
samples/c/convert_cascade.c
+3
-9
convexhull.c
samples/c/convexhull.c
+2
-11
delaunay.c
samples/c/delaunay.c
+2
-11
demhist.c
samples/c/demhist.c
+2
-11
dft.c
samples/c/dft.c
+2
-5
distrans.c
samples/c/distrans.c
+2
-9
drawing.c
samples/c/drawing.c
+2
-12
edge.c
samples/c/edge.c
+2
-10
facedetect.cpp
samples/c/facedetect.cpp
+3
-9
fback.cpp
samples/c/fback.cpp
+3
-4
fback_c.c
samples/c/fback_c.c
+2
-4
ffilldemo.c
samples/c/ffilldemo.c
+2
-12
find_obj.cpp
samples/c/find_obj.cpp
+5
-6
find_obj_ferns.cpp
samples/c/find_obj_ferns.cpp
+4
-3
fitellipse.cpp
samples/c/fitellipse.cpp
+2
-10
houghlines.c
samples/c/houghlines.c
+2
-7
image.cpp
samples/c/image.cpp
+0
-0
inpaint.cpp
samples/c/inpaint.cpp
+2
-8
kalman.c
samples/c/kalman.c
+2
-11
kmeans.c
samples/c/kmeans.c
+2
-11
laplace.c
samples/c/laplace.c
+2
-9
latentsvmdetect.cpp
samples/c/latentsvmdetect.cpp
+3
-4
letter_recog.cpp
samples/c/letter_recog.cpp
+2
-2
lkdemo.c
samples/c/lkdemo.c
+3
-13
minarea.c
samples/c/minarea.c
+2
-11
morphology.c
samples/c/morphology.c
+2
-6
motempl.c
samples/c/motempl.c
+3
-14
mser_sample.cpp
samples/c/mser_sample.cpp
+31
-33
mushroom.cpp
samples/c/mushroom.cpp
+2
-1
one_way_sample.cpp
samples/c/one_way_sample.cpp
+4
-3
peopledetect.cpp
samples/c/peopledetect.cpp
+4
-2
polar_transforms.c
samples/c/polar_transforms.c
+2
-10
pyramid_segmentation.c
samples/c/pyramid_segmentation.c
+2
-11
squares.c
samples/c/squares.c
+2
-8
stereo_calib.cpp
samples/c/stereo_calib.cpp
+3
-4
stereo_match.cpp
samples/c/stereo_match.cpp
+4
-2
tree_engine.cpp
samples/c/tree_engine.cpp
+1
-1
watershed.cpp
samples/c/watershed.cpp
+2
-8
3calibration.cpp
samples/cpp/3calibration.cpp
+4
-1
brief_match_test.cpp
samples/cpp/brief_match_test.cpp
+4
-1
connected_components.cpp
samples/cpp/connected_components.cpp
+4
-2
contours2.cpp
samples/cpp/contours2.cpp
+3
-2
generic_descriptor_match.cpp
samples/cpp/generic_descriptor_match.cpp
+1
-0
morphology2.cpp
samples/cpp/morphology2.cpp
+2
-2
segment_objects.cpp
samples/cpp/segment_objects.cpp
+3
-2
starter_imagelist.cpp
samples/cpp/starter_imagelist.cpp
+2
-1
starter_video.cpp
samples/cpp/starter_video.cpp
+2
-1
video_homography.cpp
samples/cpp/video_homography.cpp
+4
-1
No files found.
samples/c/adaptiveskindetector.cpp
View file @
042271f5
...
...
@@ -39,8 +39,8 @@
#include <cstdio>
#include <cstring>
#include <ctime>
#include <
cvaux.h
>
#include <
highgui.h
>
#include <
opencv2/contrib/contrib.hpp
>
#include <
opencv2/highgui/highgui.hpp
>
class
ASDFrameHolder
{
...
...
samples/c/bgfg_codebook.cpp
View file @
042271f5
...
...
@@ -21,13 +21,14 @@
ISBN-10: 0596516134 or: ISBN-13: 978-0596516130
************************************************** */
#include "cvaux.h"
#include "cxmisc.h"
#include "highgui.h"
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
#include <opencv2/video/background_segm.hpp>
#include <opencv2/imgproc/imgproc_c.h>
#include <opencv2/highgui/highgui.hpp>
//VARIABLES for CODEBOOK METHOD:
CvBGCodeBookModel
*
model
=
0
;
const
int
NCHANNELS
=
3
;
...
...
@@ -220,7 +221,7 @@ int main(int argc, char** argv)
if
(
ch
[
n
]
)
{
int
v
=
ptr
[
n
]
+
(
c
==
'i'
||
c
==
'l'
?
1
:
-
1
);
ptr
[
n
]
=
CV_CAST_8U
(
v
);
ptr
[
n
]
=
cv
::
saturate_cast
<
uchar
>
(
v
);
}
printf
(
"%d,"
,
ptr
[
n
]);
}
...
...
samples/c/bgfg_segm.cpp
View file @
042271f5
#include "cvaux.h"
#include "highgui.h"
#include <opencv2/video/background_segm.hpp>
#include <opencv2/highgui/highgui.hpp>
#include <stdio.h>
//this is a sample for foreground detection functions
...
...
samples/c/blobtrack_sample.cpp
View file @
042271f5
#include "cvaux.h"
#include "highgui.h"
#include <opencv2/video/background_segm.hpp>
#include <opencv2/legacy/blobtrack.hpp>
#include <opencv2/highgui/highgui.hpp>
#include <opencv2/imgproc/imgproc_c.h>
#include <stdio.h>
/* Select appropriate case insensitive string comparison function: */
...
...
samples/c/calibration_artificial.cpp
View file @
042271f5
...
...
@@ -3,8 +3,9 @@
#include <algorithm>
#include <iterator>
#include "cv.h"
#include "highgui.h"
#include <opencv2/calib3d/calib3d.hpp>
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/highgui/highgui.hpp>
using
namespace
cv
;
using
namespace
std
;
...
...
samples/c/camshiftdemo.c
View file @
042271f5
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#include <opencv2/video/tracking.hpp>
#include <opencv2/highgui/highgui.hpp>
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#include <stdio.h>
#include <ctype.h>
#endif
IplImage
*
image
=
0
,
*
hsv
=
0
,
*
hue
=
0
,
*
mask
=
0
,
*
backproject
=
0
,
*
histimg
=
0
;
CvHistogram
*
hist
=
0
;
...
...
samples/c/contours.c
View file @
042271f5
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#include <math.h>
#endif
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/highgui/highgui.hpp>
#define w 500
int
levels
=
3
;
...
...
samples/c/convert_cascade.c
View file @
042271f5
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#include <opencv2/objdetect/objdetect.hpp>
#include <opencv2/highgui/highgui.hpp>
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#include <ctype.h>
#include <stdio.h>
#endif
int
main
(
int
argc
,
char
**
argv
)
{
...
...
samples/c/convexhull.c
View file @
042271f5
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#include <stdlib.h>
#endif
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/highgui/highgui.hpp>
#define ARRAY 1
...
...
samples/c/delaunay.c
View file @
042271f5
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#include <stdio.h>
#endif
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/highgui/highgui.hpp>
/* the script demostrates iterative construction of
delaunay triangulation and voronoi tesselation */
...
...
samples/c/demhist.c
View file @
042271f5
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#include <stdio.h>
#endif
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/highgui/highgui.hpp>
char
file_name
[]
=
"baboon.jpg"
;
...
...
samples/c/dft.c
View file @
042271f5
#define CV_NO_BACKWARD_COMPATIBILITY
#include <cxcore.h>
#include <cv.h>
#include <highgui.h>
#include <opencv2/core/core.hpp>
#include <opencv2/highgui/highgui.hpp>
// Rearrange the quadrants of Fourier image so that the origin is at
// the image center
...
...
samples/c/distrans.c
View file @
042271f5
#define CV_NO_BACKWARD_COMPATIBILITY
#ifdef _CH_
#pragma package <opencv>
#endif
#include "cv.h"
#include "highgui.h"
#include <stdio.h>
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/highgui/highgui.hpp>
char
wndname
[]
=
"Distance transform"
;
char
tbarname
[]
=
"Threshold"
;
...
...
samples/c/drawing.c
View file @
042271f5
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#include <stdlib.h>
#include <stdio.h>
#endif
#include <opencv2/core/core.hpp>
#include <opencv2/highgui/highgui.hpp>
#define NUMBER 100
#define DELAY 5
...
...
samples/c/edge.c
View file @
042271f5
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#endif
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/highgui/highgui.hpp>
char
wndname
[]
=
"Edge"
;
char
tbarname
[]
=
"Threshold"
;
...
...
samples/c/facedetect.cpp
View file @
042271f5
#define CV_NO_BACKWARD_COMPATIBILITY
#include "cv.h"
#include "highgui.h"
#include <opencv2/objdetect/objdetect.hpp>
#include <opencv2/highgui/highgui.hpp>
#include <opencv2/imgproc/imgproc.hpp>
#include <iostream>
#include <cstdio>
#ifdef _EiC
#define WIN32
#endif
using
namespace
std
;
using
namespace
cv
;
...
...
samples/c/fback.cpp
View file @
042271f5
#undef _GLIBCXX_DEBUG
#include "cv.h"
#include "highgui.h"
#include <opencv2/video/tracking.hpp>
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/highgui/highgui.hpp>
using
namespace
cv
;
...
...
samples/c/fback_c.c
View file @
042271f5
#undef _GLIBCXX_DEBUG
#include "cv.h"
#include "highgui.h"
#include <opencv2/video/tracking.hpp>
#include <opencv2/highgui/highgui.hpp>
void
drawOptFlowMap
(
const
CvMat
*
flow
,
CvMat
*
cflowmap
,
int
step
,
double
scale
,
CvScalar
color
)
...
...
samples/c/ffilldemo.c
View file @
042271f5
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#include <stdio.h>
#include <stdlib.h>
#endif
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/highgui/highgui.hpp>
IplImage
*
color_img0
;
IplImage
*
mask
;
...
...
samples/c/find_obj.cpp
View file @
042271f5
...
...
@@ -4,12 +4,11 @@
* Author: Liu Liu
* liuliu.1987+opencv@gmail.com
*/
#include <cv.h>
#include <highgui.h>
#include <ctype.h>
#include <stdio.h>
#include <stdlib.h>
#include <opencv2/objdetect/objdetect.hpp>
#include <opencv2/features2d/features2d.hpp>
#include <opencv2/highgui/highgui.hpp>
#include <opencv2/calib3d/calib3d.hpp>
#include <opencv2/imgproc/imgproc_c.h>
#include <iostream>
#include <vector>
...
...
samples/c/find_obj_ferns.cpp
View file @
042271f5
#include <cv.h>
#include <cvaux.h>
#include <highgui.h>
#include "opencv2/highgui/highgui.hpp"
#include "opencv2/core/core.hpp"
#include "opencv2/imgproc/imgproc.hpp"
#include "opencv2/features2d/features2d.hpp"
#include <algorithm>
#include <iostream>
...
...
samples/c/fitellipse.cpp
View file @
042271f5
...
...
@@ -14,16 +14,8 @@
*
*
********************************************************************************/
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#endif
#include "opencv2/imgproc/imgproc_c.h"
#include "opencv2/highgui/highgui.hpp"
int
slider_pos
=
70
;
...
...
samples/c/houghlines.c
View file @
042271f5
#define CV_NO_BACKWARD_COMPATIBILITY
/* This is a standalone program. Pass an image name as a first parameter of the program.
Switch between standard and probabilistic Hough transform by changing "#if 1" to "#if 0" and back */
#include <cv.h>
#include <highgui.h>
#include <math.h>
#include "opencv2/highgui/highgui.hpp"
#include "opencv2/imgproc/imgproc.hpp"
int
main
(
int
argc
,
char
**
argv
)
{
...
...
samples/c/image.cpp
View file @
042271f5
This diff is collapsed.
Click to expand it.
samples/c/inpaint.cpp
View file @
042271f5
#ifdef _CH_
#pragma package <opencv>
#endif
#include "cv.h"
#include "highgui.h"
#include <stdio.h>
#include <stdlib.h>
#include "opencv2/highgui/highgui.hpp"
#include "opencv2/imgproc/imgproc_c.h"
IplImage
*
inpaint_mask
=
0
;
IplImage
*
img0
=
0
,
*
img
=
0
,
*
inpainted
=
0
;
...
...
samples/c/kalman.c
View file @
042271f5
...
...
@@ -11,17 +11,8 @@
Pressing ESC will stop the program.
*/
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#include <math.h>
#endif
#include "opencv2/video/tracking.hpp"
#include "opencv2/highgui/highgui.hpp"
int
main
(
int
argc
,
char
**
argv
)
{
...
...
samples/c/kmeans.c
View file @
042271f5
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#include <stdio.h>
#endif
#include "opencv2/highgui/highgui.hpp"
#include "opencv2/core/core.hpp"
int
main
(
int
argc
,
char
**
argv
)
{
...
...
samples/c/laplace.c
View file @
042271f5
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#include "opencv2/highgui/highgui.hpp"
#include "opencv2/imgproc/imgproc.hpp"
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#include <ctype.h>
#include <stdio.h>
#endif
int
sigma
=
3
;
int
smoothType
=
CV_GAUSSIAN
;
...
...
samples/c/latentsvmdetect.cpp
View file @
042271f5
#include "opencv2/objdetect/objdetect.hpp"
#include "opencv2/core/core_c.h"
#include "opencv2/highgui/highgui_c.h"
#include "opencv2/highgui/highgui.hpp"
#include <stdio.h>
using
namespace
cv
;
...
...
@@ -43,14 +42,14 @@ int main(int argc, char* argv[])
IplImage
*
image
=
cvLoadImage
(
image_filename
);
if
(
!
image
)
{
printf
(
"Unable to load the image
\n
"
printf
(
"Unable to load the image
\n
"
"Pass it as the first parameter: latentsvmdetect <path to cat.jpg> <path to cat.xml>
\n
"
);
return
-
1
;
}
CvLatentSvmDetector
*
detector
=
cvLoadLatentSvmDetector
(
model_filename
);
if
(
!
detector
)
{
printf
(
"Unable to load the model
\n
"
printf
(
"Unable to load the model
\n
"
"Pass it as the second parameter: latentsvmdetect <path to cat.jpg> <path to cat.xml>
\n
"
);
cvReleaseImage
(
&
image
);
return
-
1
;
...
...
samples/c/letter_recog.cpp
View file @
042271f5
#include "
ml
.h"
#include
<stdio.h>
#include "
opencv2/core/core_c
.h"
#include
"opencv2/ml/ml.hpp"
/*
The sample demonstrates how to train Random Trees classifier
...
...
samples/c/lkdemo.c
View file @
042271f5
/* Demo of modified Lucas-Kanade optical flow algorithm.
See the printf below */
#include "opencv2/video/tracking.hpp"
#include "opencv2/highgui/highgui.hpp"
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#include <stdio.h>
#include <ctype.h>
#
endif
#
include <stdio.h>
IplImage
*
image
=
0
,
*
grey
=
0
,
*
prev_grey
=
0
,
*
pyramid
=
0
,
*
prev_pyramid
=
0
,
*
swap_temp
;
...
...
samples/c/minarea.c
View file @
042271f5
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#include <stdlib.h>
#endif
#include "opencv2/highgui/highgui.hpp"
#include "opencv2/imgproc/imgproc_c.h"
#define ARRAY 1
...
...
samples/c/morphology.c
View file @
042271f5
#define CV_NO_BACKWARD_COMPATIBILITY
#include <cv.h>
#include <highgui.h>
#include <stdlib.h>
#include <stdio.h>
#include "opencv2/highgui/highgui.hpp"
#include "opencv2/imgproc/imgproc.hpp"
IplImage
*
src
=
0
;
IplImage
*
dst
=
0
;
...
...
samples/c/motempl.c
View file @
042271f5
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#ifndef _EiC
// motion templates sample code
#include "cv.h"
#include "highgui.h"
#include "opencv2/video/tracking.hpp"
#include "opencv2/imgproc/imgproc.hpp"
#include "opencv2/highgui/highgui.hpp"
#include <time.h>
#include <math.h>
#include <ctype.h>
#include <stdio.h>
#endif
// various tracking parameters (in seconds)
const
double
MHI_DURATION
=
1
;
...
...
samples/c/mser_sample.cpp
View file @
042271f5
/* This sample code was originally provided by Liu Liu
* Copyright 2009, Liu Liu All rights reserved.
* Copyright
�
2009, Liu Liu All rights reserved.
*/
#include <iostream>
#include <cstdio>
#include <stdio.h>
#include "cv.h"
#include "highgui.h"
#include "opencv2/highgui/highgui.hpp"
#include "opencv2/features2d/features2d.hpp"
#include "opencv2/imgproc/imgproc_c.h"
static
CvScalar
colors
[]
=
{
{{
0
,
0
,
255
}},
{{
0
,
128
,
255
}},
{{
0
,
255
,
255
}},
{{
0
,
255
,
0
}},
{{
255
,
128
,
0
}},
{{
255
,
255
,
0
}},
{{
255
,
0
,
0
}},
{{
255
,
0
,
255
}},
{{
255
,
255
,
255
}},
{{
196
,
255
,
255
}},
{{
255
,
255
,
196
}}
};
static
uchar
bcolors
[][
3
]
=
{
{
0
,
0
,
255
},
{
0
,
128
,
255
},
{
0
,
255
,
255
},
{
0
,
255
,
0
},
{
255
,
128
,
0
},
{
255
,
255
,
0
},
{
255
,
0
,
0
},
{
255
,
0
,
255
},
{
255
,
255
,
255
}
};
static
CvScalar
colors
[]
=
{
{{
0
,
0
,
255
}},
{{
0
,
128
,
255
}},
{{
0
,
255
,
255
}},
{{
0
,
255
,
0
}},
{{
255
,
128
,
0
}},
{{
255
,
255
,
0
}},
{{
255
,
0
,
0
}},
{{
255
,
0
,
255
}},
{{
255
,
255
,
255
}},
{{
196
,
255
,
255
}},
{{
255
,
255
,
196
}}
};
static
uchar
bcolors
[][
3
]
=
{
{
0
,
0
,
255
},
{
0
,
128
,
255
},
{
0
,
255
,
255
},
{
0
,
255
,
0
},
{
255
,
128
,
0
},
{
255
,
255
,
0
},
{
255
,
0
,
0
},
{
255
,
0
,
255
},
{
255
,
255
,
255
}
};
int
main
(
int
argc
,
char
**
argv
)
{
...
...
samples/c/mushroom.cpp
View file @
042271f5
#include "ml.h"
#include "opencv2/core/core_c.h"
#include "opencv2/ml/ml.hpp"
#include <stdio.h>
/*
...
...
samples/c/one_way_sample.cpp
View file @
042271f5
...
...
@@ -7,9 +7,10 @@
*
*/
#include <cv.h>
#include <cvaux.h>
#include <highgui.h>
#include "opencv2/imgproc/imgproc.hpp"
#include "opencv2/features2d/features2d.hpp"
#include "opencv2/highgui/highgui.hpp"
#include "opencv2/imgproc/imgproc_c.h"
#include <string>
...
...
samples/c/peopledetect.cpp
View file @
042271f5
#include "cvaux.h"
#include "highgui.h"
#include "opencv2/imgproc/imgproc.hpp"
#include "opencv2/objdetect/objdetect.hpp"
#include "opencv2/highgui/highgui.hpp"
#include <stdio.h>
#include <string.h>
#include <ctype.h>
...
...
samples/c/polar_transforms.c
View file @
042271f5
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#include "opencv2/imgproc/imgproc.hpp"
#include "opencv2/highgui/highgui.hpp"
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#include <ctype.h>
#include <stdio.h>
#endif
int
main
(
int
argc
,
char
**
argv
)
{
...
...
samples/c/pyramid_segmentation.c
View file @
042271f5
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#include <math.h>
#endif
#include "opencv2/imgproc/imgproc.hpp"
#include "opencv2/highgui/highgui.hpp"
IplImage
*
image
[
2
]
=
{
0
,
0
},
*
image0
=
0
,
*
image1
=
0
;
CvSize
size
;
...
...
samples/c/squares.c
View file @
042271f5
...
...
@@ -3,14 +3,8 @@
// It loads several images subsequentally and tries to find squares in
// each image
//
#ifdef _CH_
#pragma package <opencv>
#endif
#define CV_NO_BACKWARD_COMPATIBILITY
#include "cv.h"
#include "highgui.h"
#include "opencv2/imgproc/imgproc.hpp"
#include "opencv2/highgui/highgui.hpp"
#include <stdio.h>
#include <math.h>
#include <string.h>
...
...
samples/c/stereo_calib.cpp
View file @
042271f5
...
...
@@ -25,11 +25,10 @@
http://pr.willowgarage.com/wiki/OpenCV
************************************************** */
#undef _GLIBCXX_DEBUG
#include "opencv2/calib3d/calib3d.hpp"
#include "opencv2/highgui/highgui.hpp"
#include "opencv2/imgproc/imgproc_c.h"
#include "cv.h"
#include "cxmisc.h"
#include "highgui.h"
#include <vector>
#include <string>
#include <algorithm>
...
...
samples/c/stereo_match.cpp
View file @
042271f5
...
...
@@ -7,8 +7,10 @@
*
*/
#include <cv.h>
#include <highgui.h>
#include "opencv2/calib3d/calib3d.hpp"
#include "opencv2/imgproc/imgproc.hpp"
#include "opencv2/highgui/highgui.hpp"
#include <stdio.h>
using
namespace
cv
;
...
...
samples/c/tree_engine.cpp
View file @
042271f5
#include "
ml.h
"
#include "
opencv2/ml/ml.hpp
"
#include <stdio.h>
/*
The sample demonstrates how to use different decision trees.
...
...
samples/c/watershed.cpp
View file @
042271f5
#ifdef _CH_
#pragma package <opencv>
#endif
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
#include "opencv2/imgproc/imgproc_c.h"
#include "opencv2/highgui/highgui.hpp"
#include <stdio.h>
#include <stdlib.h>
#endif
IplImage
*
marker_mask
=
0
;
IplImage
*
markers
=
0
;
...
...
samples/cpp/3calibration.cpp
View file @
042271f5
...
...
@@ -2,7 +2,10 @@
* 3calibration.cpp -- Calibrate 3 cameras in a horizontal line together.
*/
#include "opencv2/opencv.hpp"
#include "opencv2/calib3d/calib3d.hpp"
#include "opencv2/imgproc/imgproc.hpp"
#include "opencv2/highgui/highgui.hpp"
#include <stdio.h>
#include <string.h>
#include <time.h>
...
...
samples/cpp/brief_match_test.cpp
View file @
042271f5
...
...
@@ -4,7 +4,10 @@
* Created on: Oct 17, 2010
* Author: ethan
*/
#include <opencv2/opencv.hpp>
#include <opencv2/calib3d/calib3d.hpp>
#include <opencv2/features2d/features2d.hpp>
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/highgui/highgui.hpp>
#include <vector>
#include <iostream>
...
...
samples/cpp/connected_components.cpp
View file @
042271f5
#include
"cv.h"
#include
"highgui.h"
#include
<opencv2/imgproc/imgproc.hpp>
#include
<opencv2/highgui/highgui.hpp>
#include <iostream>
using
namespace
cv
;
using
namespace
std
;
Mat
img
;
int
threshval
=
100
;
...
...
samples/cpp/contours2.cpp
View file @
042271f5
#include
"cv.h"
#include
"highgui.h"
#include
<opencv2/imgproc/imgproc.hpp>
#include
<opencv2/highgui/highgui.hpp>
#include <math.h>
#include <iostream>
using
namespace
cv
;
using
namespace
std
;
void
help
()
{
...
...
samples/cpp/generic_descriptor_match.cpp
View file @
042271f5
#include "opencv2/calib3d/calib3d.hpp"
#include "opencv2/features2d/features2d.hpp"
#include "opencv2/highgui/highgui.hpp"
#include "opencv2/imgproc/imgproc_c.h"
#include <cstdio>
...
...
samples/cpp/morphology2.cpp
View file @
042271f5
#define CV_NO_BACKWARD_COMPATIBILITY
#include <
cv.h
>
#include <
highgui.h
>
#include <
opencv2/imgproc/imgproc.hpp
>
#include <
opencv2/highgui/highgui.hpp
>
#include <stdlib.h>
#include <stdio.h>
...
...
samples/cpp/segment_objects.cpp
View file @
042271f5
#include "cvaux.h"
#include "highgui.h"
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/highgui/highgui.hpp>
#include <opencv2/video/background_segm.hpp>
#include <stdio.h>
#include <string>
...
...
samples/cpp/starter_imagelist.cpp
View file @
042271f5
...
...
@@ -8,7 +8,8 @@
* that was generated with imagelist_creator.cpp
* easy as CV_PI right?
*/
#include <opencv2/opencv.hpp>
#include <opencv2/highgui/highgui.hpp>
#include <iostream>
#include <vector>
using
namespace
cv
;
...
...
samples/cpp/starter_video.cpp
View file @
042271f5
...
...
@@ -7,7 +7,8 @@
* A starter sample for using opencv, get a video stream and display the images
* easy as CV_PI right?
*/
#include <opencv2/opencv.hpp>
#include <opencv2/highgui/highgui.hpp>
#include <iostream>
#include <vector>
using
namespace
cv
;
...
...
samples/cpp/video_homography.cpp
View file @
042271f5
...
...
@@ -5,7 +5,10 @@
* Author: erublee
*/
#include <opencv2/opencv.hpp>
#include <opencv2/calib3d/calib3d.hpp>
#include <opencv2/highgui/highgui.hpp>
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/features2d/features2d.hpp>
#include <iostream>
#include <list>
#include <vector>
...
...
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