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
439b1057
Commit
439b1057
authored
Dec 01, 2010
by
Gary Bradski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
added to and moved comments to top
parent
0ebd45e1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
10 deletions
+16
-10
adaptiveskindetector.cpp
samples/c/adaptiveskindetector.cpp
+16
-10
No files found.
samples/c/adaptiveskindetector.cpp
View file @
439b1057
...
...
@@ -42,6 +42,20 @@
#include <opencv2/contrib/contrib.hpp>
#include <opencv2/highgui/highgui.hpp>
void
help
(
char
**
argv
)
{
std
::
cout
<<
"
\n
This program demonstrates the contributed flesh detector CvAdaptiveSkinDetector which can be found in contrib.cpp
\n
"
<<
"Usage: "
<<
std
::
endl
<<
argv
[
0
]
<<
" fileMask firstFrame lastFrame"
<<
std
::
endl
<<
std
::
endl
<<
"Example: "
<<
std
::
endl
<<
argv
[
0
]
<<
" C:
\\
VideoSequences
\\
sample1
\\
right_view
\\
temp_%05d.jpg 0 1000"
<<
std
::
endl
<<
" iterates through temp_00000.jpg to temp_01000.jpg"
<<
std
::
endl
<<
std
::
endl
<<
"If no parameter specified, this application will try to capture from the default Webcam."
<<
std
::
endl
<<
"Please note: Background should not contain large surfaces with skin tone."
<<
"
\n\n
ESC will stop
\n
"
<<
std
::
endl
;
}
class
ASDFrameHolder
{
private
:
...
...
@@ -332,15 +346,7 @@ int main(int argc, char** argv )
if
(
argc
<
4
)
{
std
::
cout
<<
"Usage: "
<<
std
::
endl
<<
argv
[
0
]
<<
" fileMask firstFrame lastFrame"
<<
std
::
endl
<<
std
::
endl
<<
"Example: "
<<
std
::
endl
<<
argv
[
0
]
<<
" C:
\\
VideoSequences
\\
sample1
\\
right_view
\\
temp_%05d.jpg 0 1000"
<<
std
::
endl
<<
" iterates through temp_00000.jpg to temp_01000.jpg"
<<
std
::
endl
<<
std
::
endl
<<
"If no parameter specified, this application will try to capture from the default Webcam."
<<
std
::
endl
<<
"Please note: Background should not contain large surfaces with skin tone."
<<
std
::
endl
;
help
(
argv
);
sequencer
=
new
ASDFrameSequencerWebCam
();
(
dynamic_cast
<
ASDFrameSequencerWebCam
*>
(
sequencer
))
->
open
(
-
1
);
...
...
@@ -373,7 +379,7 @@ int main(int argc, char** argv )
filterMask
=
cvCreateImage
(
cvSize
(
img
->
width
,
img
->
height
),
IPL_DEPTH_8U
,
1
);
}
clock
=
std
::
clock
();
filter
.
process
(
img
,
filterMask
);
//
process the frame
filter
.
process
(
img
,
filterMask
);
//
DETECT SKIN
clockTotal
+=
(
std
::
clock
()
-
clock
);
displayBuffer
(
img
,
filterMask
,
0
,
255
,
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