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
22d33373
Commit
22d33373
authored
Mar 01, 2013
by
Andrey Kamaev
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix build warnings on MSVC x64 and OS X clang
parent
a9103606
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
15 deletions
+15
-15
OpenCVCompilerOptions.cmake
cmake/OpenCVCompilerOptions.cmake
+1
-1
OpenCVDetectCXXCompiler.cmake
cmake/OpenCVDetectCXXCompiler.cmake
+11
-11
smiledetect.cpp
samples/c/smiledetect.cpp
+3
-3
No files found.
cmake/OpenCVCompilerOptions.cmake
View file @
22d33373
...
@@ -97,7 +97,7 @@ if(CMAKE_COMPILER_IS_GNUCXX)
...
@@ -97,7 +97,7 @@ if(CMAKE_COMPILER_IS_GNUCXX)
endif
()
endif
()
# We need pthread's
# We need pthread's
if
(
UNIX AND NOT ANDROID
)
if
(
UNIX AND NOT ANDROID
AND
NOT
(
APPLE AND CMAKE_COMPILER_IS_CLANGCXX
)
)
add_extra_compiler_option
(
-pthread
)
add_extra_compiler_option
(
-pthread
)
endif
()
endif
()
...
...
cmake/OpenCVDetectCXXCompiler.cmake
View file @
22d33373
...
@@ -5,17 +5,17 @@ if(CMAKE_CL_64)
...
@@ -5,17 +5,17 @@ if(CMAKE_CL_64)
set
(
MSVC64 1
)
set
(
MSVC64 1
)
endif
()
endif
()
if
(
NOT APPLE
)
if
(
CMAKE_CXX_COMPILER_ID STREQUAL
"Clang"
)
if
(
CMAKE_CXX_COMPILER_ID STREQUAL
"Clang"
)
set
(
CMAKE_COMPILER_IS_GNUCXX 1
)
set
(
CMAKE_COMPILER_IS_GNU
CXX 1
)
set
(
CMAKE_COMPILER_IS_CLANG
CXX 1
)
set
(
CMAKE_COMPILER_IS_CLANGCXX 1
)
endif
(
)
set
(
ENABLE_PRECOMPILED_HEADERS OFF CACHE BOOL
""
FORCE
)
if
(
CMAKE_C_COMPILER_ID STREQUAL
"Clang"
)
endif
(
)
set
(
CMAKE_COMPILER_IS_GNUCC 1
)
if
(
CMAKE_C_COMPILER_ID STREQUAL
"Clang"
)
set
(
CMAKE_COMPILER_IS_CLANGCC 1
)
set
(
CMAKE_COMPILER_IS_GNUCC 1
)
endif
(
)
set
(
CMAKE_COMPILER_IS_CLANGCC 1
)
set
(
ENABLE_PRECOMPILED_HEADERS OFF CACHE BOOL
""
FORCE
)
if
((
CMAKE_COMPILER_IS_CLANGCXX OR CMAKE_COMPILER_IS_CLANGCC
)
AND NOT CMAKE_GENERATOR MATCHES
"Xcode"
)
endif
(
)
set
(
ENABLE_PRECOMPILED_HEADERS OFF CACHE BOOL
""
FORCE
)
endif
()
endif
()
# ----------------------------------------------------------------------------
# ----------------------------------------------------------------------------
...
...
samples/c/smiledetect.cpp
View file @
22d33373
...
@@ -116,7 +116,7 @@ int main( int argc, const char** argv )
...
@@ -116,7 +116,7 @@ int main( int argc, const char** argv )
{
{
cout
<<
"In capture ..."
<<
endl
;
cout
<<
"In capture ..."
<<
endl
;
cout
<<
endl
<<
"NOTE: Smile intensity will only be valid after a first smile has been detected"
<<
endl
;
cout
<<
endl
<<
"NOTE: Smile intensity will only be valid after a first smile has been detected"
<<
endl
;
for
(;;)
for
(;;)
{
{
IplImage
*
iplImg
=
cvQueryFrame
(
capture
);
IplImage
*
iplImg
=
cvQueryFrame
(
capture
);
...
@@ -229,8 +229,8 @@ void detectAndDraw( Mat& img, CascadeClassifier& cascade,
...
@@ -229,8 +229,8 @@ void detectAndDraw( Mat& img, CascadeClassifier& cascade,
// The number of detected neighbors depends on image size (and also illumination, etc.). The
// The number of detected neighbors depends on image size (and also illumination, etc.). The
// following steps use a floating minimum and maximum of neighbors. Intensity thus estimated will be
// following steps use a floating minimum and maximum of neighbors. Intensity thus estimated will be
//accurate only after a first smile has been displayed by the user.
//accurate only after a first smile has been displayed by the user.
const
int
smile_neighbors
=
nestedObjects
.
size
();
const
int
smile_neighbors
=
(
int
)
nestedObjects
.
size
();
static
int
max_neighbors
=-
1
;
static
int
max_neighbors
=-
1
;
static
int
min_neighbors
=-
1
;
static
int
min_neighbors
=-
1
;
if
(
min_neighbors
==
-
1
)
min_neighbors
=
smile_neighbors
;
if
(
min_neighbors
==
-
1
)
min_neighbors
=
smile_neighbors
;
...
...
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