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
988c405f
Commit
988c405f
authored
Jun 20, 2012
by
Andrey Kamaev
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed build with MSVC
parent
d48d7b2b
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
6 deletions
+10
-6
contours.c
samples/c/contours.c
+4
-2
fback_c.c
samples/c/fback_c.c
+2
-2
morphology.c
samples/c/morphology.c
+4
-2
No files found.
samples/c/contours.c
View file @
988c405f
...
...
@@ -19,10 +19,11 @@ CvSeq* contours = 0;
static
void
on_trackbar
(
int
pos
)
{
(
void
)
pos
;
IplImage
*
cnt_img
=
cvCreateImage
(
cvSize
(
w
,
w
),
8
,
3
);
CvSeq
*
_contours
=
contours
;
int
_levels
=
levels
-
3
;
(
void
)
pos
;
if
(
_levels
<=
0
)
// get to the nearest face to make it look more funny
_contours
=
_contours
->
h_next
->
h_next
->
h_next
;
cvZero
(
cnt_img
);
...
...
@@ -53,13 +54,14 @@ static void findCComp( IplImage* img )
int
main
(
int
argc
,
char
*
argv
[])
{
(
void
)
argc
;
(
void
)
argv
;
int
i
,
j
;
CvMemStorage
*
storage
=
cvCreateMemStorage
(
0
);
IplImage
*
img
=
cvCreateImage
(
cvSize
(
w
,
w
),
8
,
1
);
IplImage
*
img32f
=
cvCreateImage
(
cvSize
(
w
,
w
),
IPL_DEPTH_32F
,
1
);
IplImage
*
img32s
=
cvCreateImage
(
cvSize
(
w
,
w
),
IPL_DEPTH_32S
,
1
);
IplImage
*
img3
=
cvCreateImage
(
cvSize
(
w
,
w
),
8
,
3
);
(
void
)
argc
;
(
void
)
argv
;
help
();
cvZero
(
img
);
...
...
samples/c/fback_c.c
View file @
988c405f
...
...
@@ -16,8 +16,8 @@ static void help(void)
static
void
drawOptFlowMap
(
const
CvMat
*
flow
,
CvMat
*
cflowmap
,
int
step
,
double
scale
,
CvScalar
color
)
{
(
void
)
scale
;
int
x
,
y
;
(
void
)
scale
;
for
(
y
=
0
;
y
<
cflowmap
->
rows
;
y
+=
step
)
for
(
x
=
0
;
x
<
cflowmap
->
cols
;
x
+=
step
)
{
...
...
@@ -30,9 +30,9 @@ static void drawOptFlowMap(const CvMat* flow, CvMat* cflowmap, int step,
int
main
(
int
argc
,
char
**
argv
)
{
(
void
)
argc
;
(
void
)
argv
;
CvCapture
*
capture
=
cvCreateCameraCapture
(
0
);
CvMat
*
prevgray
=
0
,
*
gray
=
0
,
*
flow
=
0
,
*
cflow
=
0
;
(
void
)
argc
;
(
void
)
argv
;
help
();
...
...
samples/c/morphology.c
View file @
988c405f
...
...
@@ -17,9 +17,10 @@ int erode_dilate_pos = 0;
// callback function for open/close trackbar
static
void
OpenClose
(
int
pos
)
{
(
void
)
pos
;
int
n
=
open_close_pos
-
max_iters
;
int
an
=
n
>
0
?
n
:
-
n
;
(
void
)
pos
;
element
=
cvCreateStructuringElementEx
(
an
*
2
+
1
,
an
*
2
+
1
,
an
,
an
,
element_shape
,
0
);
if
(
n
<
0
)
{
...
...
@@ -38,9 +39,10 @@ static void OpenClose(int pos)
// callback function for erode/dilate trackbar
static
void
ErodeDilate
(
int
pos
)
{
(
void
)
pos
;
int
n
=
erode_dilate_pos
-
max_iters
;
int
an
=
n
>
0
?
n
:
-
n
;
(
void
)
pos
;
element
=
cvCreateStructuringElementEx
(
an
*
2
+
1
,
an
*
2
+
1
,
an
,
an
,
element_shape
,
0
);
if
(
n
<
0
)
{
...
...
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