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
71e43852
Commit
71e43852
authored
Mar 29, 2013
by
Andrey Kamaev
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix MSVC build issues
parent
2b1ef954
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
39 additions
and
24 deletions
+39
-24
core_c.h
modules/core/include/opencv2/core/core_c.h
+9
-0
matx.hpp
modules/core/include/opencv2/core/matx.hpp
+5
-5
types.hpp
modules/core/include/opencv2/core/types.hpp
+1
-1
types_c.h
modules/core/include/opencv2/core/types_c.h
+3
-3
haar.cpp
modules/ocl/src/haar.cpp
+4
-6
matrix_operations.cpp
modules/ocl/src/matrix_operations.cpp
+1
-1
moments.cpp
modules/ocl/src/moments.cpp
+1
-1
ts_perf.hpp
modules/ts/include/opencv2/ts/ts_perf.hpp
+9
-4
super_resolution.cpp
samples/gpu/super_resolution.cpp
+5
-2
facedetect.cpp
samples/ocl/facedetect.cpp
+1
-1
No files found.
modules/core/include/opencv2/core/core_c.h
View file @
71e43852
...
...
@@ -47,6 +47,15 @@
#include "opencv2/core/types_c.h"
#ifdef __cplusplus
#ifdef _MSC_VER
/* disable warning C4190: 'function' has C-linkage specified, but returns UDT 'typename'
which is incompatible with C
It is OK to disable it because we only extend few plain structures with
C++ construrtors for simpler interoperability with C++ API of the library
*/
# pragma warning(disable:4190)
#endif
extern
"C"
{
#endif
...
...
modules/core/include/opencv2/core/matx.hpp
View file @
71e43852
...
...
@@ -257,10 +257,10 @@ public:
/*!
Utility methods
*/
template
<
typename
_Tp
,
int
m
>
double
determinant
(
const
Matx
<
_Tp
,
m
,
m
>&
a
);
template
<
typename
_Tp
,
int
m
,
int
n
>
double
trace
(
const
Matx
<
_Tp
,
m
,
n
>&
a
);
template
<
typename
_Tp
,
int
m
,
int
n
>
double
norm
(
const
Matx
<
_Tp
,
m
,
n
>&
M
);
template
<
typename
_Tp
,
int
m
,
int
n
>
double
norm
(
const
Matx
<
_Tp
,
m
,
n
>&
M
,
int
normType
);
template
<
typename
_Tp
,
int
m
>
static
double
determinant
(
const
Matx
<
_Tp
,
m
,
m
>&
a
);
template
<
typename
_Tp
,
int
m
,
int
n
>
static
double
trace
(
const
Matx
<
_Tp
,
m
,
n
>&
a
);
template
<
typename
_Tp
,
int
m
,
int
n
>
static
double
norm
(
const
Matx
<
_Tp
,
m
,
n
>&
M
);
template
<
typename
_Tp
,
int
m
,
int
n
>
static
double
norm
(
const
Matx
<
_Tp
,
m
,
n
>&
M
,
int
normType
);
...
...
@@ -399,7 +399,7 @@ public:
/*!
Utility methods
*/
template
<
typename
_Tp
,
int
cn
>
Vec
<
_Tp
,
cn
>
normalize
(
const
Vec
<
_Tp
,
cn
>&
v
);
template
<
typename
_Tp
,
int
cn
>
static
Vec
<
_Tp
,
cn
>
normalize
(
const
Vec
<
_Tp
,
cn
>&
v
);
...
...
modules/core/include/opencv2/core/types.hpp
View file @
71e43852
...
...
@@ -517,7 +517,7 @@ public:
typedef
_Tp
channel_type
;
enum
{
generic_type
=
0
,
depth
=
DataType
<
channel_type
>::
value
,
depth
=
DataType
<
channel_type
>::
depth
,
channels
=
4
,
fmt
=
DataType
<
channel_type
>::
fmt
+
((
channels
-
1
)
<<
8
),
type
=
CV_MAKETYPE
(
depth
,
channels
)
...
...
modules/core/include/opencv2/core/types_c.h
View file @
71e43852
...
...
@@ -267,7 +267,7 @@ CV_INLINE double cvRandReal( CvRNG* rng )
#define IPL_BORDER_REFLECT 2
#define IPL_BORDER_WRAP 3
typedef
struct
_IplImage
typedef
struct
CV_EXPORTS
_IplImage
{
int
nSize
;
/* sizeof(IplImage) */
int
ID
;
/* version (=0)*/
...
...
@@ -558,7 +558,7 @@ CV_INLINE int cvIplDepth( int type )
#define CV_MAX_DIM 32
#define CV_MAX_DIM_HEAP 1024
typedef
struct
CvMatND
typedef
struct
C
V_EXPORTS
C
vMatND
{
int
type
;
int
dims
;
...
...
@@ -626,7 +626,7 @@ typedef struct CV_EXPORTS CvSparseMat
CvSparseMat
;
#ifdef __cplusplus
CvSparseMat
*
cvCreateSparseMat
(
const
cv
::
SparseMat
&
m
);
C
V_EXPORTS
C
vSparseMat
*
cvCreateSparseMat
(
const
cv
::
SparseMat
&
m
);
#endif
#define CV_IS_SPARSE_MAT_HDR(mat) \
...
...
modules/ocl/src/haar.cpp
View file @
71e43852
...
...
@@ -931,10 +931,10 @@ CvSeq *cv::ocl::OclCascadeClassifier::oclHaarDetectObjects( oclMat &gimg, CvMemS
std
::
vector
<
float
>
scalev
;
for
(
factor
=
1.
f
;;
factor
*=
scaleFactor
)
{
CvSize
winSize
=
{
cvRound
(
winSize0
.
width
*
factor
),
cvRound
(
winSize0
.
height
*
factor
)
}
;
CvSize
winSize
(
cvRound
(
winSize0
.
width
*
factor
),
cvRound
(
winSize0
.
height
*
factor
)
)
;
sz
.
width
=
cvRound
(
gimg
.
cols
/
factor
)
+
1
;
sz
.
height
=
cvRound
(
gimg
.
rows
/
factor
)
+
1
;
CvSize
sz1
=
{
sz
.
width
-
winSize0
.
width
-
1
,
sz
.
height
-
winSize0
.
height
-
1
}
;
CvSize
sz1
(
sz
.
width
-
winSize0
.
width
-
1
,
sz
.
height
-
winSize0
.
height
-
1
)
;
if
(
sz1
.
width
<=
0
||
sz1
.
height
<=
0
)
break
;
...
...
@@ -1158,9 +1158,7 @@ CvSeq *cv::ocl::OclCascadeClassifier::oclHaarDetectObjects( oclMat &gimg, CvMemS
cvRound
(
factor
*
winsize0
.
height
)
<
gimg
.
rows
-
10
;
n_factors
++
,
factor
*=
scaleFactor
)
{
CvSize
winSize
=
{
cvRound
(
winsize0
.
width
*
factor
),
cvRound
(
winsize0
.
height
*
factor
)
};
CvSize
winSize
(
cvRound
(
winsize0
.
width
*
factor
),
cvRound
(
winsize0
.
height
*
factor
)
);
if
(
winSize
.
width
<
minSize
.
width
||
winSize
.
height
<
minSize
.
height
)
{
continue
;
...
...
@@ -1320,7 +1318,7 @@ CvSeq *cv::ocl::OclCascadeClassifier::oclHaarDetectObjects( oclMat &gimg, CvMemS
if
(
findBiggestObject
&&
rectList
.
size
()
)
{
CvAvgComp
result_comp
=
{
{
0
,
0
,
0
,
0
}
,
0
};
CvAvgComp
result_comp
=
{
CvRect
()
,
0
};
for
(
size_t
i
=
0
;
i
<
rectList
.
size
();
i
++
)
{
...
...
modules/ocl/src/matrix_operations.cpp
View file @
71e43852
...
...
@@ -927,7 +927,7 @@ void cv::ocl::oclMat::createEx(int _rows, int _cols, int _type, DevMemRW rw_type
{
clCxt
=
Context
::
getContext
();
/* core logic */
_type
&=
TYPE_MASK
;
_type
&=
Mat
::
TYPE_MASK
;
//download_channels = CV_MAT_CN(_type);
//if(download_channels==3)
//{
...
...
modules/ocl/src/moments.cpp
View file @
71e43852
...
...
@@ -265,7 +265,7 @@ static void ocl_cvMoments( const void* array, CvMoments* mom, int binary )
if
(
size
.
width
<=
0
||
size
.
height
<=
0
)
return
;
cv
::
Mat
src0
(
mat
);
cv
::
Mat
src0
=
cv
::
cvarrToMat
(
mat
);
cv
::
ocl
::
oclMat
src
(
src0
);
cv
::
Size
tileSize
;
int
blockx
,
blocky
;
...
...
modules/ts/include/opencv2/ts/ts_perf.hpp
View file @
71e43852
#ifndef __OPENCV_TS_PERF_HPP__
#define __OPENCV_TS_PERF_HPP__
#ifdef HAVE_CVCONFIG_H
# include "cvconfig.h"
#endif
#ifndef GTEST_CREATE_SHARED_LIBRARY
# ifdef BUILD_SHARED_LIBS
# define GTEST_LINKED_AS_SHARED_LIBRARY 1
# endif
#endif
#include "opencv2/core.hpp"
#include "ts_gtest.h"
#ifdef HAVE_TBB
#include "tbb/task_scheduler_init.h"
#endif
#if !(defined(LOGD) || defined(LOGI) || defined(LOGW) || defined(LOGE))
# if defined(ANDROID) && defined(USE_ANDROID_LOGGING)
# include <android/log.h>
...
...
samples/gpu/super_resolution.cpp
View file @
71e43852
...
...
@@ -47,7 +47,6 @@ static Ptr<DenseOpticalFlowExt> createOptFlow(const string& name, bool useGpu)
else
{
cerr
<<
"Incorrect Optical Flow algorithm - "
<<
name
<<
endl
;
exit
(
-
1
);
}
return
Ptr
<
DenseOpticalFlowExt
>
();
...
...
@@ -90,7 +89,11 @@ int main(int argc, const char* argv[])
superRes
->
set
(
"scale"
,
scale
);
superRes
->
set
(
"iterations"
,
iterations
);
superRes
->
set
(
"temporalAreaRadius"
,
temporalAreaRadius
);
superRes
->
set
(
"opticalFlow"
,
createOptFlow
(
optFlow
,
useGpu
));
Ptr
<
DenseOpticalFlowExt
>
of
=
createOptFlow
(
optFlow
,
useGpu
);
if
(
of
.
empty
())
exit
(
-
1
);
superRes
->
set
(
"opticalFlow"
,
of
);
Ptr
<
FrameSource
>
frameSource
;
if
(
useGpu
)
...
...
samples/ocl/facedetect.cpp
View file @
71e43852
...
...
@@ -114,7 +114,7 @@ int main( int argc, const char** argv )
for
(;;)
{
IplImage
*
iplImg
=
cvQueryFrame
(
capture
);
frame
=
iplImg
;
frame
=
cv
::
cvarrToMat
(
iplImg
)
;
if
(
frame
.
empty
()
)
break
;
if
(
iplImg
->
origin
==
IPL_ORIGIN_TL
)
...
...
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