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
383559c2
Commit
383559c2
authored
8 years ago
by
Alexander Alekhin
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #8062 from mshabunin:add-cv_deprecated
parents
6f848b85
c6c51916
No related merge requests found
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
28 additions
and
31 deletions
+28
-31
Doxyfile.in
doc/Doxyfile.in
+1
-1
cvdef.h
modules/core/include/opencv2/core/cvdef.h
+10
-0
flann.hpp
modules/flann/include/opencv2/flann.hpp
+14
-14
defines.h
modules/flann/include/opencv2/flann/defines.h
+0
-13
flann_base.hpp
modules/flann/include/opencv2/flann/flann_base.hpp
+2
-2
matrix.h
modules/flann/include/opencv2/flann/matrix.h
+1
-1
No files found.
doc/Doxyfile.in
View file @
383559c2
...
...
@@ -251,7 +251,7 @@ PREDEFINED = __cplusplus=1 \
CV_DEFAULT(x)=" = x" \
CV_NEON=1 \
CV_SSE2=1 \
FLANN
_DEPRECATED=
CV
_DEPRECATED=
EXPAND_AS_DEFINED =
SKIP_FUNCTION_MACROS = YES
TAGFILES =
...
...
This diff is collapsed.
Click to expand it.
modules/core/include/opencv2/core/cvdef.h
View file @
383559c2
...
...
@@ -369,6 +369,16 @@ Cv64suf;
# define CV_EXPORTS
#endif
#ifndef CV_DEPRECATED
# if defined(__GNUC__)
# define CV_DEPRECATED __attribute__ ((deprecated))
# elif defined(_MSC_VER)
# define CV_DEPRECATED __declspec(deprecated)
# else
# define CV_DEPRECATED
# endif
#endif
#ifndef CV_EXTERN_C
# ifdef __cplusplus
# define CV_EXTERN_C extern "C"
...
...
This diff is collapsed.
Click to expand it.
modules/flann/include/opencv2/flann.hpp
View file @
383559c2
...
...
@@ -59,7 +59,7 @@ can be found in @cite Muja2009 .
namespace
cvflann
{
CV_EXPORTS
flann_distance_t
flann_distance_type
();
FLANN
_DEPRECATED
CV_EXPORTS
void
set_distance_type
(
flann_distance_t
distance_type
,
int
order
);
CV
_DEPRECATED
CV_EXPORTS
void
set_distance_type
(
flann_distance_t
distance_type
,
int
order
);
}
...
...
@@ -230,7 +230,7 @@ public:
::
cvflann
::
IndexParams
getParameters
()
{
return
nnIndex
->
getParameters
();
}
FLANN
_DEPRECATED
const
::
cvflann
::
IndexParams
*
getIndexParameters
()
{
return
nnIndex
->
getIndexParameters
();
}
CV
_DEPRECATED
const
::
cvflann
::
IndexParams
*
getIndexParameters
()
{
return
nnIndex
->
getIndexParameters
();
}
private
:
::
cvflann
::
Index
<
Distance
>*
nnIndex
;
...
...
@@ -344,7 +344,7 @@ public:
typedef
typename
L2
<
T
>::
ElementType
ElementType
;
typedef
typename
L2
<
T
>::
ResultType
DistanceType
;
FLANN
_DEPRECATED
Index_
(
const
Mat
&
dataset
,
const
::
cvflann
::
IndexParams
&
params
)
CV
_DEPRECATED
Index_
(
const
Mat
&
dataset
,
const
::
cvflann
::
IndexParams
&
params
)
{
printf
(
"[WARNING] The cv::flann::Index_<T> class is deperecated, use cv::flann::GenericIndex<Distance> instead
\n
"
);
...
...
@@ -368,13 +368,13 @@ public:
if
(
nnIndex_L1
)
nnIndex_L1
->
buildIndex
();
if
(
nnIndex_L2
)
nnIndex_L2
->
buildIndex
();
}
FLANN
_DEPRECATED
~
Index_
()
CV
_DEPRECATED
~
Index_
()
{
if
(
nnIndex_L1
)
delete
nnIndex_L1
;
if
(
nnIndex_L2
)
delete
nnIndex_L2
;
}
FLANN
_DEPRECATED
void
knnSearch
(
const
std
::
vector
<
ElementType
>&
query
,
std
::
vector
<
int
>&
indices
,
std
::
vector
<
DistanceType
>&
dists
,
int
knn
,
const
::
cvflann
::
SearchParams
&
searchParams
)
CV
_DEPRECATED
void
knnSearch
(
const
std
::
vector
<
ElementType
>&
query
,
std
::
vector
<
int
>&
indices
,
std
::
vector
<
DistanceType
>&
dists
,
int
knn
,
const
::
cvflann
::
SearchParams
&
searchParams
)
{
::
cvflann
::
Matrix
<
ElementType
>
m_query
((
ElementType
*
)
&
query
[
0
],
1
,
query
.
size
());
::
cvflann
::
Matrix
<
int
>
m_indices
(
&
indices
[
0
],
1
,
indices
.
size
());
...
...
@@ -383,7 +383,7 @@ public:
if
(
nnIndex_L1
)
nnIndex_L1
->
knnSearch
(
m_query
,
m_indices
,
m_dists
,
knn
,
searchParams
);
if
(
nnIndex_L2
)
nnIndex_L2
->
knnSearch
(
m_query
,
m_indices
,
m_dists
,
knn
,
searchParams
);
}
FLANN
_DEPRECATED
void
knnSearch
(
const
Mat
&
queries
,
Mat
&
indices
,
Mat
&
dists
,
int
knn
,
const
::
cvflann
::
SearchParams
&
searchParams
)
CV
_DEPRECATED
void
knnSearch
(
const
Mat
&
queries
,
Mat
&
indices
,
Mat
&
dists
,
int
knn
,
const
::
cvflann
::
SearchParams
&
searchParams
)
{
CV_Assert
(
queries
.
type
()
==
CvType
<
ElementType
>::
type
());
CV_Assert
(
queries
.
isContinuous
());
...
...
@@ -401,7 +401,7 @@ public:
if
(
nnIndex_L2
)
nnIndex_L2
->
knnSearch
(
m_queries
,
m_indices
,
m_dists
,
knn
,
searchParams
);
}
FLANN
_DEPRECATED
int
radiusSearch
(
const
std
::
vector
<
ElementType
>&
query
,
std
::
vector
<
int
>&
indices
,
std
::
vector
<
DistanceType
>&
dists
,
DistanceType
radius
,
const
::
cvflann
::
SearchParams
&
searchParams
)
CV
_DEPRECATED
int
radiusSearch
(
const
std
::
vector
<
ElementType
>&
query
,
std
::
vector
<
int
>&
indices
,
std
::
vector
<
DistanceType
>&
dists
,
DistanceType
radius
,
const
::
cvflann
::
SearchParams
&
searchParams
)
{
::
cvflann
::
Matrix
<
ElementType
>
m_query
((
ElementType
*
)
&
query
[
0
],
1
,
query
.
size
());
::
cvflann
::
Matrix
<
int
>
m_indices
(
&
indices
[
0
],
1
,
indices
.
size
());
...
...
@@ -411,7 +411,7 @@ public:
if
(
nnIndex_L2
)
return
nnIndex_L2
->
radiusSearch
(
m_query
,
m_indices
,
m_dists
,
radius
,
searchParams
);
}
FLANN
_DEPRECATED
int
radiusSearch
(
const
Mat
&
query
,
Mat
&
indices
,
Mat
&
dists
,
DistanceType
radius
,
const
::
cvflann
::
SearchParams
&
searchParams
)
CV
_DEPRECATED
int
radiusSearch
(
const
Mat
&
query
,
Mat
&
indices
,
Mat
&
dists
,
DistanceType
radius
,
const
::
cvflann
::
SearchParams
&
searchParams
)
{
CV_Assert
(
query
.
type
()
==
CvType
<
ElementType
>::
type
());
CV_Assert
(
query
.
isContinuous
());
...
...
@@ -429,32 +429,32 @@ public:
if
(
nnIndex_L2
)
return
nnIndex_L2
->
radiusSearch
(
m_query
,
m_indices
,
m_dists
,
radius
,
searchParams
);
}
FLANN
_DEPRECATED
void
save
(
String
filename
)
CV
_DEPRECATED
void
save
(
String
filename
)
{
if
(
nnIndex_L1
)
nnIndex_L1
->
save
(
filename
);
if
(
nnIndex_L2
)
nnIndex_L2
->
save
(
filename
);
}
FLANN
_DEPRECATED
int
veclen
()
const
CV
_DEPRECATED
int
veclen
()
const
{
if
(
nnIndex_L1
)
return
nnIndex_L1
->
veclen
();
if
(
nnIndex_L2
)
return
nnIndex_L2
->
veclen
();
}
FLANN
_DEPRECATED
int
size
()
const
CV
_DEPRECATED
int
size
()
const
{
if
(
nnIndex_L1
)
return
nnIndex_L1
->
size
();
if
(
nnIndex_L2
)
return
nnIndex_L2
->
size
();
}
FLANN
_DEPRECATED
::
cvflann
::
IndexParams
getParameters
()
CV
_DEPRECATED
::
cvflann
::
IndexParams
getParameters
()
{
if
(
nnIndex_L1
)
return
nnIndex_L1
->
getParameters
();
if
(
nnIndex_L2
)
return
nnIndex_L2
->
getParameters
();
}
FLANN
_DEPRECATED
const
::
cvflann
::
IndexParams
*
getIndexParameters
()
CV
_DEPRECATED
const
::
cvflann
::
IndexParams
*
getIndexParameters
()
{
if
(
nnIndex_L1
)
return
nnIndex_L1
->
getIndexParameters
();
if
(
nnIndex_L2
)
return
nnIndex_L2
->
getIndexParameters
();
...
...
@@ -505,7 +505,7 @@ int hierarchicalClustering(const Mat& features, Mat& centers, const ::cvflann::K
/** @deprecated
*/
template
<
typename
ELEM_TYPE
,
typename
DIST_TYPE
>
FLANN
_DEPRECATED
int
hierarchicalClustering
(
const
Mat
&
features
,
Mat
&
centers
,
const
::
cvflann
::
KMeansIndexParams
&
params
)
CV
_DEPRECATED
int
hierarchicalClustering
(
const
Mat
&
features
,
Mat
&
centers
,
const
::
cvflann
::
KMeansIndexParams
&
params
)
{
printf
(
"[WARNING] cv::flann::hierarchicalClustering<ELEM_TYPE,DIST_TYPE> is deprecated, use "
"cv::flann::hierarchicalClustering<Distance> instead
\n
"
);
...
...
This diff is collapsed.
Click to expand it.
modules/flann/include/opencv2/flann/defines.h
View file @
383559c2
...
...
@@ -50,19 +50,6 @@
#endif
#ifdef FLANN_DEPRECATED
#undef FLANN_DEPRECATED
#endif
#ifdef __GNUC__
#define FLANN_DEPRECATED __attribute__ ((deprecated))
#elif defined(_MSC_VER)
#define FLANN_DEPRECATED __declspec(deprecated)
#else
#pragma message("WARNING: You need to implement FLANN_DEPRECATED for this compiler")
#define FLANN_DEPRECATED
#endif
#undef FLANN_PLATFORM_32_BIT
#undef FLANN_PLATFORM_64_BIT
#if defined __amd64__ || defined __x86_64__ || defined _WIN64 || defined _M_X64
...
...
This diff is collapsed.
Click to expand it.
modules/flann/include/opencv2/flann/flann_base.hpp
View file @
383559c2
...
...
@@ -241,7 +241,7 @@ public:
/**
* \brief Returns actual index
*/
FLANN
_DEPRECATED
NNIndex
<
Distance
>*
getIndex
()
CV
_DEPRECATED
NNIndex
<
Distance
>*
getIndex
()
{
return
nnIndex_
;
}
...
...
@@ -250,7 +250,7 @@ public:
* \brief Returns index parameters.
* \deprecated use getParameters() instead.
*/
FLANN
_DEPRECATED
const
IndexParams
*
getIndexParameters
()
CV
_DEPRECATED
const
IndexParams
*
getIndexParameters
()
{
return
&
index_params_
;
}
...
...
This diff is collapsed.
Click to expand it.
modules/flann/include/opencv2/flann/matrix.h
View file @
383559c2
...
...
@@ -66,7 +66,7 @@ public:
/**
* Convenience function for deallocating the storage data.
*/
FLANN
_DEPRECATED
void
free
()
CV
_DEPRECATED
void
free
()
{
fprintf
(
stderr
,
"The cvflann::Matrix<T>::free() method is deprecated "
"and it does not do any memory deallocation any more. You are"
...
...
This diff is collapsed.
Click to expand it.
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